Openbravo Issue Tracking System - Retail Modules
View Issue Details
0053653Retail ModulesQuotationspublic2023-10-12 18:152023-11-16 14:25
Leosbanis 
Rajesh_18 
highmajoralways
closedfixed 
5
 
 
No
0053653: The ExtraProperties entity is not correctly updated in the response call after a quotation has been transformed into a order
Some months ago, it was requested to include the entity “extraProperties” in the request call (in case it has been previously replied in a response call) so that the middleware receives this information, and they can manage the discounts added properly in any future call for the same order, that has already a external discount added to the ticket.

Therefore, if in a “response” call, the extraProperties is filled, this entity will be included in any future request call inside the object “ManualPromotions”.

If we create a quotation and we add an automatic discount (which has a extraProperties received in the call), if we transform the quotation into a order and we try to confirm the order or add a discount, in the API Calculate discount request call sent to the middleware, the "extraProperties" entity received previously is not included in the call.
1- Create a Quotation including a product that can be added to a discount returned by the external system discount.
2- Click on the payment button to launch the External System Calculate discount API and confirm the quotation.
3- Click on the menu button to transform the quotation into an order "Create Sales Order"
4- Click on the "Discount" button to add a discount - launch "API Calculate discount"
When a Quotation is transformed into an Order the ID of the order and lines are changed but the information contained into the "order.cdiscExternalresponse" remains with the old values and this information is used to compose the request to the External System Discount API, so the proposal consist in create a hook implementation for "OBPOS_PreCreateOrderFromQuotation" that update this information with the new values of ID.
No tags attached.
related to defect 0053965 scheduled Rajesh_18 [External Discounts] Discount amount reset when converting a quotation into a ticket 
pdf file.pdf (733,322) 2023-10-12 18:15
https://issues.openbravo.com/file_download.php?file_id=19035&type=bug
Issue History
2023-10-12 18:15LeosbanisNew Issue
2023-10-12 18:15LeosbanisAssigned To => Retail
2023-10-12 18:15LeosbanisFile Added: file.pdf
2023-10-12 18:15LeosbanisTriggers an Emergency Pack => No
2023-10-17 12:44Rajesh_18Assigned ToRetail => Rajesh_18
2023-10-17 13:05Rajesh_18Statusnew => scheduled
2023-10-25 10:06hgbotNote Added: 0156268
2023-10-25 10:10hgbotNote Added: 0156269
2023-10-25 10:13hgbotNote Added: 0156270
2023-11-16 14:24hgbotNote Added: 0157221
2023-11-16 14:24hgbotNote Added: 0157222
2023-11-16 14:24hgbotNote Added: 0157223
2023-11-16 14:24hgbotNote Added: 0157224
2023-11-16 14:25hgbotResolutionopen => fixed
2023-11-16 14:25hgbotStatusscheduled => closed
2023-11-16 14:25hgbotNote Added: 0157225
2023-11-16 14:25hgbotNote Added: 0157226
2023-11-16 14:35aaroncaleroRelationship addedrelated to 0053965

Notes
(0156268)
hgbot   
2023-10-25 10:06   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.events.discounts/-/merge_requests/6 [^]
(0156269)
hgbot   
2023-10-25 10:10   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/1389 [^]
(0156270)
hgbot   
2023-10-25 10:13   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/merge_requests/121 [^]
(0157221)
hgbot   
2023-11-16 14:24   
Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts [^]
Changeset: 48628a91eba9ddd65eb2d2fdf6c1f5631d755ea3
Author: Rajesh Senthilkumar <rajesh@qualiantech.com>
Date: 15-11-2023 09:28:15
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/commit/48628a91eba9ddd65eb2d2fdf6c1f5631d755ea3 [^]

Related ISSUE-53653: ExtraProperties is updated after quotation converted to order

---
M web/org.openbravo.retail.discounts/app/model/business-logic/discounts-engine/interface/discount-posinterface.js
---
(0157222)
hgbot   
2023-11-16 14:24   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/merge_requests/121 [^]
(0157223)
hgbot   
2023-11-16 14:24   
Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal [^]
Changeset: 4540e20de63cb1e86aa9349ed5bb2b7ff721bd52
Author: Rajesh Senthilkumar <rajesh@qualiantech.com>
Date: 16-11-2023 09:12:00
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/commit/4540e20de63cb1e86aa9349ed5bb2b7ff721bd52 [^]

Related ISSUE-53653: ExtraProperties is updated after quotation converted to order

---
M web/org.openbravo.retail.posterminal/app/model/business-object/ticket/actions/CreateTicketFromQuotation.js
---
(0157224)
hgbot   
2023-11-16 14:24   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/1389 [^]
(0157225)
hgbot   
2023-11-16 14:25   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.events.discounts [^]
Changeset: c440de3e6bb397dad715b407208b60916355445a
Author: Rajesh Senthilkumar <rajesh@qualiantech.com>
Date: 15-11-2023 09:29:03
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.events.discounts/-/commit/c440de3e6bb397dad715b407208b60916355445a [^]

Fixes ISSUE-53653: ExtraProperties is updated after quotation converted to order

---
M web/org.openbravo.events.discounts/app/model/business-object/ticket/actions/CreateTicketFromQuotation.js
---
(0157226)
hgbot   
2023-11-16 14:25   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.events.discounts/-/merge_requests/6 [^]