Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0015496Openbravo ERPA. Platformpublic2010-12-21 09:592011-05-24 10:57
mtaal 
mtaal 
normalmajorhave not tried
closedfixed 
5
 
 
Core
No
0015496: Referenced properties are not accessible in derived read mode
The derived readable concept allows access to id, identifier, audit info, active and client/organization. There is however another property which should be accessible in derived readable mode: the properties which are referenced by other properties. For example the language entity is not referenced on the primary key but on another property (language) when generating json the reference to the language table results in an error because the language property is not accessible in derived read mode.

The stack trace:

a3196480 866626 [http-8080-4] ERROR org.openbravo.base.exception.OBSecurityException - Entity ADLanguage is not directly readable, only id and identifier properties are readable, property ADLanguage.language is neither of these.
org.openbravo.base.exception.OBSecurityException: Entity ADLanguage is not directly readable, only id and identifier properties are readable, property ADLanguage.language is neither of these.
    at org.openbravo.base.structure.BaseOBObject.checkDerivedReadable(BaseOBObject.java:172)
    at org.openbravo.base.structure.BaseOBObject.get(BaseOBObject.java:140)
    at org.openbravo.service.json.DataToJsonConverter.addBaseOBObject(DataToJsonConverter.java:209)
    at org.openbravo.service.json.DataToJsonConverter.toJsonObject(DataToJsonConverter.java:148)
    at org.openbravo.service.json.DataToJsonConverter.toJsonObjects(DataToJsonConverter.java:102)
    at org.openbravo.service.json.DefaultJsonDataService.fetch(DefaultJsonDataService.java:202)
    at org.openbravo.service.datasource.DefaultDataSourceService.fetch(DefaultDataSourceService.java:69)
    at org.openbravo.service.datasource.DataSourceServlet.doFetch(DataSourceServlet.java:163)
    at org.openbravo.service.datasource.DataSourceServlet.doPost(DataSourceServlet.java:202)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
    at org.openbravo.base.HttpBaseServlet.serviceInitialized(HttpBaseServlet.java:225)
closingMay2011
Issue History
2010-12-21 09:59mtaalNew Issue
2010-12-21 09:59mtaalAssigned To => mtaal
2010-12-21 09:59mtaalModules => Core
2010-12-21 10:03hgbotCheckin
2010-12-21 10:03hgbotNote Added: 0033336
2010-12-21 10:03hgbotStatusnew => resolved
2010-12-21 10:03hgbotResolutionopen => fixed
2010-12-21 10:03hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/fc9792f53ddc4eecf81b2de8a5ce400372a29efb [^]
2010-12-30 13:15hudsonbotCheckin
2010-12-30 13:15hudsonbotNote Added: 0033464
2011-05-24 10:02dalsasuaTag Attached: closingMay2011
2011-05-24 10:57dalsasuaStatusresolved => closed

Notes
(0033336)
hgbot   
2010-12-21 10:03   
Repository: erp/devel/pi
Changeset: fc9792f53ddc4eecf81b2de8a5ce400372a29efb
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Tue Dec 21 10:02:27 2010 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/fc9792f53ddc4eecf81b2de8a5ce400372a29efb [^]

Fixes issue 15496: Referenced properties are not accessible in derived read mode

---
M src/org/openbravo/base/model/Property.java
---
(0033464)
hudsonbot   
2010-12-30 13:15   
A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/fc9792f53ddc [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/7d7e5eebcc62 [^]
Tests: http://builds.openbravo.com/view/int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.19448.obx [^]