Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0017203Openbravo ERPA. Platformpublic2011-05-17 16:072011-06-07 16:20
alostale 
mtaal 
normalmajoralways
closedfixed 
5
 
3.0MP0 
Core
No
0017203: Read only logic not dynamically applied in grid view
When there is a column with read only logic, editing in form view the fields that affect that column triggers makes the field with read only editable or not regarding the other fields' values.

In grid mode instead, it seems the read only status is computed when entering in edit mode, but it is not changed on the fly regarding the other fields values.
http://screencast.com/t/RNf744Ft [^]
No tags attached.
Issue History
2011-05-17 16:07alostaleNew Issue
2011-05-17 16:07alostaleAssigned To => alostale
2011-05-17 16:07alostaleModules => Core
2011-05-23 08:07alostaleStatusnew => scheduled
2011-05-23 08:07alostaleAssigned Toalostale => mtaal
2011-05-23 08:07alostalefix_in_branch => pi
2011-05-26 15:16mtaalNote Added: 0037607
2011-05-26 19:51dmitry_mezentsevfix_in_branchpi =>
2011-06-01 13:00mtaalNote Added: 0037881
2011-06-01 13:02hgbotCheckin
2011-06-01 13:02hgbotNote Added: 0037882
2011-06-01 13:02hgbotStatusscheduled => resolved
2011-06-01 13:02hgbotResolutionopen => fixed
2011-06-01 13:02hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/598c6daec11a57b48118ebf4922e851d915af474 [^]
2011-06-03 13:27hudsonbotCheckin
2011-06-03 13:27hudsonbotNote Added: 0037983
2011-06-07 10:33marvintmNote Added: 0038093
2011-06-07 10:33marvintmStatusresolved => new
2011-06-07 10:33marvintmResolutionfixed => open
2011-06-07 15:38hgbotCheckin
2011-06-07 15:38hgbotNote Added: 0038129
2011-06-07 15:38hgbotStatusnew => resolved
2011-06-07 15:38hgbotResolutionopen => fixed
2011-06-07 15:38hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/devel/pi/rev/598c6daec11a57b48118ebf4922e851d915af474 [^] => http://code.openbravo.com/erp/devel/pi/rev/9ef624bb38537196e231012e1089e7dc3509f3c3 [^]
2011-06-07 16:20marvintmStatusresolved => closed

Notes
(0037607)
mtaal   
2011-05-26 15:16   
To find examples of current readonlylogic:



select w.name win, t.name tab, f.name field, readonlylogic
 from ad_column c, ad_field f, ad_tab t, ad_window w
where readonlylogic is not null and readonlylogic not ilike '%Processed%' and readonlylogic not ilike '%Posted%'
and c.ad_column_id = f.ad_field_id
and f.ad_tab_id = t.ad_tab_id
and t.ad_window_id = w.ad_window_id
and c.isactive='Y'
and f.isactive='Y'
and t.isactive='Y'
and w.isactive='Y'
and f.isdisplayed='Y'
order by 1, t.seqno, f.seqno
(0037881)
mtaal   
2011-06-01 13:00   
I could not really reproduce this but solved a related thing which interferes with this.

I tested this by setting the requisition line uom readonlylogic to:
@DocStatus@='CO'|@DocStatus@='CL'|@inpqty@>10

when changing the quantity in the line or in form view, the read only logic was correctly applied.
(0037882)
hgbot   
2011-06-01 13:02   
Repository: erp/devel/pi
Changeset: 598c6daec11a57b48118ebf4922e851d915af474
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Wed Jun 01 13:01:03 2011 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/598c6daec11a57b48118ebf4922e851d915af474 [^]

Fixes issue 17203: Read only logic not dynamically applied in grid view

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/ob-view-form.js
---
(0037983)
hudsonbot   
2011-06-03 13:27   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/2a05e66b60ca [^]

Maturity status: Test
(0038093)
marvintm   
2011-06-07 10:33   
The issue can be reproduced if these steps are followed:

- Add a readonly logic which depends on a value of a checkbox field (this is important, it happens with checkboxes).
- Then go to the grid in edit view and verify that the readonly logic is only applied when the focus is changed; that is, when the user explicitly gets out of the field.

The fix is that the readonly logic needs to be applied, for checkboxes, every time the user changes its value, instead of only when the focus goes out of the field. This probably is also true for other actions which depend on the value of a checkbox (such as CHANGE mode calls to the FIC to fire callouts).
(0038129)
hgbot   
2011-06-07 15:38   
Repository: erp/devel/pi
Changeset: 9ef624bb38537196e231012e1089e7dc3509f3c3
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Tue Jun 07 15:37:54 2011 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/9ef624bb38537196e231012e1089e7dc3509f3c3 [^]

Fixes issue 17203: Read only logic not dynamically applied in grid view

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/window/OBViewGridComponent.java
---