Fixes issue 26823 Cost Date of M_TRANSACTION_COST removed when filtering Stock Valuation Report
authorRafa Roda Palacios <rafa.roda@ubiquads.com>
Tue, 10 Jun 2014 21:31:49 +0200
changeset 23475 e861ed85d496
parent 23474 153d5f9b6e1b
child 23477 51ed39cd1af8
Fixes issue 26823 Cost Date of M_TRANSACTION_COST removed when filtering Stock Valuation Report
src/org/openbravo/erpCommon/ad_reports/ReportValuationStock_data.xsql
--- a/src/org/openbravo/erpCommon/ad_reports/ReportValuationStock_data.xsql	Thu Jun 12 14:38:24 2014 +0530
+++ b/src/org/openbravo/erpCommon/ad_reports/ReportValuationStock_data.xsql	Tue Jun 10 21:31:49 2014 +0200
@@ -12,7 +12,7 @@
  * under the License. 
  * The Original Code is Openbravo ERP. 
  * The Initial Developer of the Original Code is Openbravo SLU 
- * All portions are Copyright (C) 2001-2012 Openbravo SLU 
+ * All portions are Copyright (C) 2001-2014 Openbravo SLU 
  * All Rights Reserved. 
  * Contributor(s):  ______________________________________.
  ************************************************************************
@@ -48,7 +48,6 @@
                       LEFT JOIN M_INOUT io ON iol.M_INOUT_ID = io.M_INOUT_ID 
                       LEFT JOIN (SELECT sum(cost) AS trxcost, m_transaction_id, c_currency_id
                                  FROM M_TRANSACTION_COST
-                                 WHERE costdate < to_date(?)
                                  GROUP BY m_transaction_id, c_currency_id) tc ON trx.m_transaction_id = tc.m_transaction_id
                     WHERE trx.MOVEMENTDATE < to_date(?)
               AND l.M_WAREHOUSE_ID = ?
@@ -69,7 +68,6 @@
       <Parameter name="cCurrencyConv"/>
       <Parameter name="legalEntity"/>
       <Parameter name="datePlus"/>
-      <Parameter name="datePlus"/>
       <Parameter name="warehouse"/>
       <Parameter name="categoryProduct" optional="true" after="AND   1 = 1"><![CDATA[ AND M_PRODUCT.M_PRODUCT_CATEGORY_ID= ? ]]></Parameter>
   </SqlMethod>