Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0049187Openbravo ERPA. Platformpublic2022-05-03 11:242022-05-03 12:02
caristu 
Triage Platform Base 
highminorhave not tried
newopen 
5
 
 
Core
No
0049187: Is not possible to have a display logic for a button based in a property field
Is not possible to have a display logic for a button based in a property field
Found this trouble in the EDL module that has a window that makes this issue reproducible.

1- As system admin go to the [Windows, Tabs and Fields] window
2- Create a property field using the property "eDLProcess.reprocessPolicy" as shown in the attached image.
3- Note that the window has an auxiliary input to get the reprocess policy, and the "Process" button has a display logic based on it. But now, the display logic will be calculated based on the newly added property field.
4- Try to access to the EDL process window. An error is shown and the following stacktrace appears in the log:

Caused by: org.openbravo.base.util.CheckException: Property with Reprocess_Policy does not exist for entity OBEDL_Request
    at org.openbravo.base.model.Entity.getPropertyByColumnName(Entity.java:591) ~[classes/:?]
    at org.openbravo.client.application.window.OBViewFieldHandler.getFields(OBViewFieldHandler.java:163) ~[classes/:?]
    at jdk.internal.reflect.GeneratedMethodAccessor498.invoke(Unknown Source) ~[?:?]
This is the code[1] that throws the exception. It seems that it does not take into account the case of the field being a property field.

[1] https://gitlab.com/openbravo/product/openbravo/-/blob/master/modules/org.openbravo.client.application/src/org/openbravo/client/application/window/OBViewFieldHandler.java#L161 [^]
No tags attached.
has duplicate defect 0050045 closed Triage Platform Base Openbravo ERP Cannot use Property Fields in display logic of a button. 
blocks defect 0049191 acknowledged Triage Platform Base Modules Add a property field in the EDL request window to show the reprocess policy of the request process 
Issue History
2022-05-03 11:24caristuNew Issue
2022-05-03 11:24caristuAssigned To => Triage Platform Base
2022-05-03 11:24caristuModules => Core
2022-05-03 11:24caristuTriggers an Emergency Pack => No
2022-05-03 11:55caristuRelationship addedrelated to 0044945
2022-05-03 12:02caristuProposed Solution updated
2022-05-03 12:02caristuProposed Solution updated
2022-05-03 12:06caristuRelationship addedblocks 0049191
2022-05-03 12:06caristuRelationship deletedrelated to 0044945
2022-08-24 10:53caristuRelationship addedhas duplicate 0050045

There are no notes attached to this issue.