Openbravo Issue Tracking System - POS2
View Issue Details
0053233POS2POSpublic2023-08-17 16:512023-10-03 08:01
alfonso_alcalde 
Rajesh_18 
urgentcriticalalways
closedno change required 
30Openbravo Appliance 14.04
 
 
marvintm
OBPS
No
0053233: Error Import Business Partner API
Reproduced in live builds.

When executing the business partner import method, it always tries to update.

When only 1 BP exists, it updates the information of the BP indicated from the json, even if the searchkey is different, adding the location and updating everything except the searchkey.

In case there is more than 1, it gives an error in EDL, with the message that it is not unique, and the number of BP existing in the client where you are triying to insert.

** 1 existing BP
- Select customer with a unique BP, to try to add another BP from API.
- Execute org.openbravo.api.ImportService/BusinessPartner service, for the selected customer, with new data (Searchkey, etc).
- Check that the existing BP has been updated.

**More than 1 existing BP
- Select customer with more than 1 BP, to try to add one more BP from API.
- Execute org.openbravo.api.ImportService/BusinessPartner service, for the selected customer, with new data (Searchkey, etc).
- Error registered in EDL Request, "Error while importing an item: query did not return a unique result: X". X = number of existing BP
No tags attached.
? Screencast from 17-08-23 16:47:46.webm (4,611,696) 2023-08-17 16:51
https://issues.openbravo.com/file_download.php?file_id=18879&type=bug
Issue History
2023-08-17 16:51alfonso_alcaldeNew Issue
2023-08-17 16:51alfonso_alcaldeAssigned To => Retail
2023-08-17 16:51alfonso_alcaldeFile Added: Screencast from 17-08-23 16:47:46.webm
2023-08-17 16:51alfonso_alcaldeOBNetwork customer => OBPS
2023-08-17 16:51alfonso_alcaldeTriggers an Emergency Pack => No
2023-08-22 12:19Rajesh_18Assigned ToRetail => Rajesh_18
2023-08-22 12:20Rajesh_18Statusnew => scheduled
2023-08-23 14:01marvintmReview Assigned To => marvintm
2023-08-23 14:01marvintmNote Added: 0153852
2023-08-23 14:01marvintmStatusscheduled => closed
2023-08-23 14:01marvintmResolutionopen => no change required
2023-10-03 07:59alfonso_alcaldeSeveritycritical => major
2023-10-03 08:01alfonso_alcaldeSeveritymajor => critical

Notes
(0153852)
marvintm   
2023-08-23 14:01   
There is actually no issue, and the problem comes from a wrong usage of the API. The searchKey property is incorrectly specified as "searchkey" in the video, and this is what is causing the problem to happen.