Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0023096Openbravo ERPA. Platformpublic2013-02-18 11:092013-03-21 10:20
jecharri 
dmiguelez 
urgentmajoralways
closedfixed 
5
pi 
3.0MP22 
Sandrahuguet
Google Chrome
Core
No
0023096: Product selector Is not filtering by role org access
Product selector Is not filtering by role org access

-define a role with access to organization "España Región Sur"

-Login in the ERP with this role.

-Go to window "Sales order" and after create a header go to lines

-push in product selector magnifying glass and clean all the filters.

Verify that you are able to see all the prices and all the warehouses of the client.
diff --git a/src-db/database/sourcedata/OBUISEL_SELECTOR.xml b/src-db/database/sourcedata/OBUISEL_SELECTOR.xml
--- a/src-db/database/sourcedata/OBUISEL_SELECTOR.xml
+++ b/src-db/database/sourcedata/OBUISEL_SELECTOR.xml
@@ -74,7 +74,7 @@
 <!--2E64F551C7C4470C80C29DBA24B34A5F--> <NAME><![CDATA[Product]]></NAME>
 <!--2E64F551C7C4470C80C29DBA24B34A5F--> <AD_REFERENCE_ID><![CDATA[800060]]></AD_REFERENCE_ID>
 <!--2E64F551C7C4470C80C29DBA24B34A5F--> <AD_TABLE_ID><![CDATA[FF8080812DFFA1CF012DFFB889F40016]]></AD_TABLE_ID>
-<!--2E64F551C7C4470C80C29DBA24B34A5F--> <WHERECLAUSE><![CDATA[e.active='Y']]></WHERECLAUSE>
+<!--2E64F551C7C4470C80C29DBA24B34A5F--> <WHERECLAUSE><![CDATA[e.active='Y' and (AD_ISORGINCLUDED(e.warehouse.organization.id, @AD_Org_Id@, @AD_Client_Id@)<>-1 or (AD_ISORGINCLUDED( @AD_Org_Id@, e.warehouse.organization.id, @AD_Client_Id@)<>-1))]]></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--> <OBCLKER_TEMPLATE_ID><![CDATA[9314DE8599AD44E7BFC4CC50699042AB]]></OBCLKER_TEMPLATE_ID>
 <!--2E64F551C7C4470C80C29DBA24B34A5F--> <ISACTIVE><![CDATA[Y]]></ISACTIVE>
No tags attached.
depends on defect 00233343.0MP22 closed AugustoMauch In Product Selector, when using the @ad_org_id@ in the HQL Where Clause is not working as expected. 
Issue History
2013-02-18 11:09jecharriNew Issue
2013-02-18 11:09jecharriAssigned To => dmiguelez
2013-02-18 11:09jecharriWeb browser => Google Chrome
2013-02-18 11:09jecharriModules => Core
2013-02-18 11:09jecharriResolution time => 1363820400
2013-02-18 11:09jecharriTriggers an Emergency Pack => No
2013-02-20 08:46dmiguelezAssigned Todmiguelez => jonalegriaesarte
2013-02-20 14:56jonalegriaesarteAssigned Tojonalegriaesarte => jecharri
2013-03-04 10:55jonalegriaesarteWeb browserGoogle Chrome => Google Chrome
2013-03-04 10:55jonalegriaesarteNote Added: 0056972
2013-03-04 10:55jonalegriaesarteTarget Version3.0MP21 => 3.0MP22
2013-03-07 10:19jecharriWeb browserGoogle Chrome => Google Chrome
2013-03-07 10:19jecharriAssigned Tojecharri => AugustoMauch
2013-03-07 10:19jecharriCategory07. Sales management => A. Platform
2013-03-11 14:00AugustoMauchAssigned ToAugustoMauch => dmiguelez
2013-03-18 20:01dmiguelezRelationship addeddepends on 0023334
2013-03-18 20:01dmiguelezWeb browserGoogle Chrome => Google Chrome
2013-03-18 20:01dmiguelezProposed Solution updated
2013-03-21 10:18hgbotCheckin
2013-03-21 10:18hgbotNote Added: 0057347
2013-03-21 10:18hgbotStatusnew => resolved
2013-03-21 10:18hgbotResolutionopen => fixed
2013-03-21 10:18hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/811136480e47bb540ecb968021d16fbc5162c92d [^]
2013-03-21 10:20SandrahuguetReview Assigned To => Sandrahuguet
2013-03-21 10:20SandrahuguetNote Added: 0057349
2013-03-21 10:20SandrahuguetStatusresolved => closed

Notes
(0056972)
jonalegriaesarte   
2013-03-04 10:55   
Moved to MP22 due to other priorities
(0057347)
hgbot   
2013-03-21 10:18   
Repository: erp/devel/pi
Changeset: 811136480e47bb540ecb968021d16fbc5162c92d
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Tue Mar 19 18:40:04 2013 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/811136480e47bb540ecb968021d16fbc5162c92d [^]

Fixes Issue 23096. Filters Organizations of the Product Selector
using the Organization of the Document if available.

---
M src-db/database/sourcedata/OBUISEL_SELECTOR.xml
---
(0057349)
Sandrahuguet   
2013-03-21 10:20   
Code review + testing OK