details: /erp/devel/main/rev/e8550a2429e4 changeset: 8167:e8550a2429e4 user: Adrián Romero <adrianromero <at> openbravo.com> date: Fri Aug 13 09:46:55 2010 +0200 summary: Fixes issue 0013698: While creating sales invoice using Copy lines option system wrongly calculates Discount amount for the newly generated invoice. It has been modified the SQL sentence that copies the invoice lines to not include lines that are discounts that are applied when completing invoices
details: /erp/devel/main/rev/975fec3bc5e7 changeset: 8168:975fec3bc5e7 user: RM packaging bot <staff.rm <at> openbravo.com> date: Fri Aug 13 14:20:01 2010 +0200 summary: CI: promote changesets from pi to main details: /erp/devel/main/rev/e10b0c3d07eb changeset: 8169:e10b0c3d07eb user: RM packaging bot <staff.rm <at> openbravo.com> date: Fri Aug 13 14:20:02 2010 +0200 summary: CI: update AD_MODULE - Core version and label diffstat: src-db/database/sourcedata/AD_MODULE.xml | 4 +- src/org/openbravo/erpCommon/ad_actionButton/CopyFromInvoice_data.xsql | 27 ++++++--- 2 files changed, 20 insertions(+), 11 deletions(-) diffs (65 lines): diff -r e5071383ecc3 -r e10b0c3d07eb src-db/database/sourcedata/AD_MODULE.xml --- a/src-db/database/sourcedata/AD_MODULE.xml Thu Aug 12 15:08:24 2010 +0200 +++ b/src-db/database/sourcedata/AD_MODULE.xml Fri Aug 13 14:20:02 2010 +0200 @@ -6,7 +6,7 @@ <!--0--> <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID> <!--0--> <ISACTIVE><![CDATA[Y]]></ISACTIVE> <!--0--> <NAME><![CDATA[core]]></NAME> -<!--0--> <VERSION><![CDATA[2.50.17989]]></VERSION> +<!--0--> <VERSION><![CDATA[2.50.18168]]></VERSION> <!--0--> <DESCRIPTION><![CDATA[Core module is the base one]]></DESCRIPTION> <!--0--> <HELP><![CDATA[Core module is the base one, all developments in core are included as part of the standard Openbravo ERP.]]></HELP> <!--0--> <URL><![CDATA[www.openbravo.com]]></URL> @@ -22,7 +22,7 @@ <!--0--> <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE> <!--0--> <HASREFERENCEDATA><![CDATA[Y]]></HASREFERENCEDATA> <!--0--> <REFERENCEDATAINFO><![CDATA[Standard document types for orders, invoices, etc. and settings]]></REFERENCEDATAINFO> -<!--0--> <VERSION_LABEL><![CDATA[dev]]></VERSION_LABEL> +<!--0--> <VERSION_LABEL><![CDATA[CI]]></VERSION_LABEL> <!--0--> <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL> <!--0--> <COMMERCIAL_TIER><![CDATA[NA]]></COMMERCIAL_TIER> <!--0--></AD_MODULE> diff -r e5071383ecc3 -r e10b0c3d07eb src/org/openbravo/erpCommon/ad_actionButton/CopyFromInvoice_data.xsql --- a/src/org/openbravo/erpCommon/ad_actionButton/CopyFromInvoice_data.xsql Thu Aug 12 15:08:24 2010 +0200 +++ b/src/org/openbravo/erpCommon/ad_actionButton/CopyFromInvoice_data.xsql Fri Aug 13 14:20:02 2010 +0200 @@ -27,22 +27,31 @@ <SqlMethodComment></SqlMethodComment> <Sql> <![CDATA[ - SELECT C_UOM_ID, QTYINVOICED, C_InvoiceLine_ID,PRICELIST, PRICELIMIT, PRICEACTUAL, LINENETAMT, '' AS AD_ORG_ID, '' AS AD_CLIENT_ID, '' AS C_BPartner_Location_ID, - '' AS DateInvoiced, '' AS C_Project_ID, M_PRODUCT_ID AS PRODUCT_ID, + SELECT + C_INVOICELINE.C_UOM_ID, C_INVOICELINE.QTYINVOICED, C_INVOICELINE.C_InvoiceLine_ID,C_INVOICELINE.PRICELIST, + C_INVOICELINE.PRICELIMIT, C_INVOICELINE.PRICEACTUAL, C_INVOICELINE.LINENETAMT, + '' AS AD_ORG_ID, '' AS AD_CLIENT_ID, + '' AS C_BPartner_Location_ID, + '' AS DateInvoiced, '' AS C_Project_ID, + C_INVOICELINE.M_PRODUCT_ID AS PRODUCT_ID, '' AS C_BPARTNER_ID, '' AS C_CURRENCY_ID, '' AS M_PRICELIST_ID, '' AS LINE, '' AS ISSOTRX, '' AS TAXDATE, '' AS PRICESTD, '' AS VALIDFROM, - '' AS StdPrecision, '' AS PricePrecision, '' AS EnforcePriceLimit FROM C_InvoiceLine - WHERE C_Invoice_ID = ? - AND AD_CLIENT_ID IN ('1') - AND AD_ORG_ID IN ('1') - AND ISACTIVE = 'Y' + '' AS StdPrecision, '' AS PricePrecision, '' AS EnforcePriceLimit + FROM C_INVOICELINE + LEFT OUTER JOIN C_INVOICE_DISCOUNT ON C_INVOICELINE.C_INVOICE_DISCOUNT_ID = C_INVOICE_DISCOUNT.C_INVOICE_DISCOUNT_ID + LEFT OUTER JOIN C_BPARTNER_DISCOUNT ON C_INVOICE_DISCOUNT.C_DISCOUNT_ID = C_BPARTNER_DISCOUNT.C_DISCOUNT_ID + WHERE C_INVOICELINE.C_Invoice_ID = ? + AND C_INVOICELINE.AD_CLIENT_ID IN ('1') + AND C_INVOICELINE.AD_ORG_ID IN ('1') + AND C_INVOICELINE.ISACTIVE = 'Y' + AND (APPLYINORDER IS NULL OR APPLYINORDER <> 'N') ]]> </Sql> <Parameter name="cInvoiceId"/> - <Parameter name="userclient" optional="true" type="replace" after="AND AD_CLIENT_ID IN (" text="'1'"/> - <Parameter name="userorg" optional="true" type="replace" after="AND AD_ORG_ID IN (" text="'1'"/> + <Parameter name="userclient" optional="true" type="replace" after="AND C_INVOICELINE.AD_CLIENT_ID IN (" text="'1'"/> + <Parameter name="userorg" optional="true" type="replace" after="AND C_INVOICELINE.AD_ORG_ID IN (" text="'1'"/> </SqlMethod> <SqlMethod name="insert" type="preparedStatement" connection="true" return="rowCount"> <SqlMethodComment></SqlMethodComment> ------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev _______________________________________________ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits