Fixes bug 28426: A product without sales price can be added to a commision
authorUnai Martirena <unai.martirena@openbravo.com>
Wed, 28 Jan 2015 09:31:53 +0100
changeset 24125 38100ff86b5a
parent 24124 a9b62c65a205
child 24126 80ea36768a2b
Fixes bug 28426: A product without sales price can be added to a commision

Filter expression of Product Selector has been changed for Commission window, to not to filter by Sales flag, displaying in this way Purchase and Sales Products.
src-db/database/sourcedata/OBUISEL_SELECTOR.xml
--- a/src-db/database/sourcedata/OBUISEL_SELECTOR.xml	Fri Jan 23 12:21:36 2015 +0100
+++ b/src-db/database/sourcedata/OBUISEL_SELECTOR.xml	Wed Jan 28 09:31:53 2015 +0100
@@ -140,7 +140,7 @@
 <!--2E64F551C7C4470C80C29DBA24B34A5F-->  <AD_REFERENCE_ID><![CDATA[800060]]></AD_REFERENCE_ID>
 <!--2E64F551C7C4470C80C29DBA24B34A5F-->  <AD_TABLE_ID><![CDATA[FF8080812DFFA1CF012DFFB889F40016]]></AD_TABLE_ID>
 <!--2E64F551C7C4470C80C29DBA24B34A5F-->  <WHERECLAUSE><![CDATA[e.active='Y' and (AD_ISORGINCLUDED(e.orgwarehouse, @AD_Org_Id@, @AD_Client_Id@)<>-1 or (AD_ISORGINCLUDED( @AD_Org_Id@, e.orgwarehouse, @AD_Client_Id@)<>-1)) AND e.productPrice.priceListVersion.active='Y']]></WHERECLAUSE>
-<!--2E64F551C7C4470C80C29DBA24B34A5F-->  <FILTER_EXPRESSION><![CDATA[if (OB.getParameters().get('inpcCurrencyId')){ " e.productPrice.priceListVersion.priceList.salesPriceList = " + OB.isSalesTransaction()  + " AND e.productPrice.priceListVersion.priceList.currency.id = '" + OB.getParameters().get('inpcCurrencyId') + "'" }]]></FILTER_EXPRESSION>
+<!--2E64F551C7C4470C80C29DBA24B34A5F-->  <FILTER_EXPRESSION><![CDATA[if (OB.getParameters().get('inpcCurrencyId') && OB.getWindowId() == '207') { " e.productPrice.priceListVersion.priceList.currency.id = '" + OB.getParameters().get('inpcCurrencyId') + "'" } else if (OB.getParameters().get('inpcCurrencyId')) { " e.productPrice.priceListVersion.priceList.salesPriceList = " + OB.isSalesTransaction()  + " AND e.productPrice.priceListVersion.priceList.currency.id = '" + OB.getParameters().get('inpcCurrencyId') + "'" }]]></FILTER_EXPRESSION>
 <!--2E64F551C7C4470C80C29DBA24B34A5F-->  <OBCLKER_TEMPLATE_ID><![CDATA[9314DE8599AD44E7BFC4CC50699042AB]]></OBCLKER_TEMPLATE_ID>
 <!--2E64F551C7C4470C80C29DBA24B34A5F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--2E64F551C7C4470C80C29DBA24B34A5F-->  <VALUEFIELD_ID><![CDATA[2CB91FE062B541ACB00D82AC69858446]]></VALUEFIELD_ID>