Openbravo Issue Tracking System - POS2
View Issue Details
0053535POS2POSpublic2023-09-25 09:562023-10-04 08:17
ebecerra 
caristu 
normalmajorhave not tried
closedfixed 
5
 
 
No
0053535: Fails to update records that have a reference to an external system
Fails to update records that have a reference to an external system if it is left empty (this is possible if the external system is not mandatory)
0- Apply the attached path which adds a field that references to an external system from the [CRM Connector Configuration] window.
1- Go to the [External System] window and create at least one external system
2- Go to the [CRM Connector Configuration] window and fill the new "External System" field. Save the record.
3- Leave the "External System" field empty and try to save. The saving operation fails due to a NullPointerException:

java.lang.NullPointerException: null
    at org.openbravo.service.externalsystem.ExternalSystemDataEventHandler.clearCachedExternalSystemInstance(ExternalSystemDataEventHandler.java:94) ~[classes/:?]
    at org.openbravo.service.externalsystem.ExternalSystemDataEventHandler.onUpdate(ExternalSystemDataEventHandler.java:80) ~[classes/:?]
No tags attached.
related to feature request 0048579 closed caristu Openbravo ERP Push API 
diff field.diff (10,730) 2023-09-25 16:29
https://issues.openbravo.com/file_download.php?file_id=18991&type=bug
Issue History
2023-09-25 09:56ebecerraNew Issue
2023-09-25 09:56ebecerraAssigned To => Retail
2023-09-25 09:56ebecerraTriggers an Emergency Pack => No
2023-09-25 09:57ebecerraAssigned ToRetail => caristu
2023-09-25 16:29caristuSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=26887#r26887
2023-09-25 16:29caristuFile Added: field.diff
2023-09-25 16:43hgbotNote Added: 0155215
2023-10-04 08:13hgbotResolutionopen => fixed
2023-10-04 08:13hgbotStatusnew => closed
2023-10-04 08:13hgbotFixed in Version => PR24Q1
2023-10-04 08:13hgbotNote Added: 0155457
2023-10-04 08:13hgbotNote Added: 0155458
2023-10-04 08:17caristuRelationship addedrelated to 0048579

Notes
(0155215)
hgbot   
2023-09-25 16:43   
Merge Request created: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1006 [^]
(0155457)
hgbot   
2023-10-04 08:13   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: 2f1ac48598f0b58d1d99fe411e982125d3c6bc81
Author: Carlos Aristu <carlos.aristu@openbravo.com>
Date: 04-10-2023 06:13:32
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/2f1ac48598f0b58d1d99fe411e982125d3c6bc81 [^]

fixes BUG-53535: error updating records referencing external system

The ExternalSystemDataEventHandler was intended to invalidate cached
configurations that may have changed. For example, for HTTP based
external systems, these are changes done in the HTTP subtab.

But this event handler should not be fired when changing records of
other entities that has a reference to an external system. For this
reason we have added the isParent check because the configuration
entities are represented as children of the ExternalSystemData entity
and the rest of entities should not.

This changeset also renames the constant as EXTERNAL_SYSTEM_PROPERTY
to follow the standard convention.

---
M src/org/openbravo/service/externalsystem/ExternalSystemDataEventHandler.java
---
(0155458)
hgbot   
2023-10-04 08:13   
Merge request merged: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/1006 [^]