Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0054882Openbravo ERP00. Application dictionarypublic2024-03-07 16:262024-04-15 09:19
vmromanos 
AugustoMauch 
normalmajoralways
closedfixed 
5
 
PR24Q3 
Core
No
0054882: Fields related to sqllogic columns are force to be read only
When a column is defined with a SQL Logic, the associated field is always force to be read only.

However, for P&E windows, it might be needed to allow editing this field, as it might be sent as input parameter to the handler in the server.
To be able to reproduce the issue, apply the attached 54882_reproducer.diff or:

    As System Admin:

    Create a dummy column "M_Warehouse_ID" (Tabledir) in M_Storage_Detail table with sql logic = select max(l.m_warehouse_id) from m_locator l

    Go to Window, Tabs and fields and find the "Box Handling Unit P&E".
    Go to tab, then fields
    Add a new field for the new column. Make sure it's shown in grid and is not set as read only.

Then:

Run ant smartbuild

Go to Handling unit window, create a new record and press the Box button.

In the grid see the field is displayed, but it can't be edited. This is wrong, the user should be able to change the value if the field is not readonly
Attached a patch that works for me. Please check other scenarios.
No tags attached.
blocks feature request 0054667 scheduled vmromanos Support nested handling units 
diff 54882-proposed-solution.diff (1,248) 2024-03-07 16:30
https://issues.openbravo.com/file_download.php?file_id=19530&type=bug
diff 54882_reproducer.diff (8,217) 2024-04-08 12:02
https://issues.openbravo.com/file_download.php?file_id=19625&type=bug
Issue History
2024-03-07 16:26vmromanosNew Issue
2024-03-07 16:26vmromanosAssigned To => Triage Platform Base
2024-03-07 16:26vmromanosModules => Core
2024-03-07 16:26vmromanosTriggers an Emergency Pack => No
2024-03-07 16:30vmromanosFile Added: 54882-proposed-solution.diff
2024-03-12 17:38vmromanosRelationship addedblocks 0054667
2024-03-21 23:19AugustoMauchStatusnew => acknowledged
2024-04-08 08:44AugustoMauchAssigned ToTriage Platform Base => AugustoMauch
2024-04-08 12:02AugustoMauchSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=27776#r27776
2024-04-08 12:02AugustoMauchFile Added: 54882_reproducer.diff
2024-04-08 12:04AugustoMauchSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=27777#r27777
2024-04-08 12:07hgbotNote Added: 0162917
2024-04-08 12:09AugustoMauchStatusacknowledged => scheduled
2024-04-08 12:10AugustoMauchStatusscheduled => resolved
2024-04-08 12:10AugustoMauchFixed in SCM revision => https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1184/diffs?commit_id=9407d8a3ec4ea7990125573a44980816e1a487ed [^]
2024-04-08 12:10AugustoMauchResolutionopen => fixed
2024-04-15 09:19hgbotStatusresolved => closed
2024-04-15 09:19hgbotFixed in Version => PR24Q3
2024-04-15 09:19hgbotNote Added: 0163174
2024-04-15 09:19hgbotNote Added: 0163175

Notes
(0162917)
hgbot   
2024-04-08 12:07   
Merge Request created: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1184 [^]
(0163174)
hgbot   
2024-04-15 09:19   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: 30837829452d7fee1fdc6615238a89f116308323
Author: Augusto Mauch <augusto.mauch@openbravo.com>
Date: 12-04-2024 15:07:22
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/30837829452d7fee1fdc6615238a89f116308323 [^]

Fixes ISSUE-54882: Computed columns are not necessarily read only in P&E grids

Computed columns should be read only in standard grids, because it does not make sense to change their value in the source table, as the value is autocalculated. In
Pick and Execute window it could make sense to edit them, and use the computed column sql logic as a sort of default value

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/window/OBViewFieldHandler.java
---
(0163175)
hgbot   
2024-04-15 09:19   
Merge request merged: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1184 [^]