Openbravo Issue Tracking System - Retail Modules
View Issue Details
0040847Retail ModulesWeb POSpublic2019-05-12 01:422019-06-25 19:39
asiermartirena 
asiermartirena 
highmajoralways
closedfixed 
5
 
RR19Q3 
marvintm
No
0040847: The stock queries must be centralized to avoid multiple connections
There are some processes that can check the available stock for a product due to different causes. When adding a product or when trying to go to the payment tab, the stock can be checked because the adding product is discontinued or because of a delivery mode. Instead of doing a different query for each situation, a unique query is done to check the different cases.
Configure and install modules to have different stock checks to in the same flow. Execute the flow and check that now is only a connection is done to compare the stock.
No tags attached.
Issue History
2019-05-12 01:42asiermartirenaNew Issue
2019-05-12 01:42asiermartirenaAssigned To => asiermartirena
2019-05-12 01:42asiermartirenaTriggers an Emergency Pack => No
2019-05-12 22:28hgbotCheckin
2019-05-12 22:28hgbotNote Added: 0111634
2019-05-12 22:28hgbotStatusnew => resolved
2019-05-12 22:28hgbotResolutionopen => fixed
2019-05-12 22:28hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/bfe5bc98405ba12ffc67c53dcca98bda96dd7295 [^]
2019-05-12 23:01hgbotCheckin
2019-05-12 23:01hgbotNote Added: 0111635
2019-05-13 13:36hgbotCheckin
2019-05-13 13:36hgbotNote Added: 0111642
2019-05-15 18:33marvintmNote Added: 0111693
2019-05-15 18:33marvintmStatusresolved => new
2019-05-15 18:33marvintmResolutionfixed => open
2019-05-17 08:50hgbotCheckin
2019-05-17 08:50hgbotNote Added: 0111759
2019-05-17 08:51asiermartirenaStatusnew => scheduled
2019-05-17 08:51asiermartirenaStatusscheduled => resolved
2019-05-17 08:51asiermartirenaResolutionopen => fixed
2019-05-24 10:02asiermartirenaStatusresolved => new
2019-05-24 10:02asiermartirenaResolutionfixed => open
2019-06-09 17:36hgbotCheckin
2019-06-09 17:36hgbotNote Added: 0112518
2019-06-09 17:36hgbotCheckin
2019-06-09 17:36hgbotNote Added: 0112520
2019-06-09 17:36hgbotCheckin
2019-06-09 17:36hgbotNote Added: 0112521
2019-06-09 17:36hgbotCheckin
2019-06-09 17:36hgbotNote Added: 0112523
2019-06-09 17:38asiermartirenaStatusnew => scheduled
2019-06-09 17:38asiermartirenaStatusscheduled => resolved
2019-06-09 17:38asiermartirenaResolutionopen => fixed
2019-06-17 15:31hgbotCheckin
2019-06-17 15:31hgbotNote Added: 0112829
2019-06-25 19:39marvintmReview Assigned To => marvintm
2019-06-25 19:39marvintmStatusresolved => closed
2019-06-25 19:39marvintmFixed in Version => RR19Q3

Notes
(0111634)
hgbot   
2019-05-12 22:28   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: bfe5bc98405ba12ffc67c53dcca98bda96dd7295
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Sun May 12 15:30:56 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/bfe5bc98405ba12ffc67c53dcca98bda96dd7295 [^]

Fixed issue 40847: The stock is managed with the same API for the different flows

Now, when adding lines or when going to the payment tab, the stock is checked with a single connection instead of asking the stock for each single case.
New hooks added to allow to implement the stock calls control from external modules.

---
M src-db/database/sourcedata/AD_REF_LIST.xml
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/pointofsale.js
M web/org.openbravo.retail.posterminal/js/utils/productStatusUtils.js
M web/org.openbravo.retail.posterminal/js/utils/stockUtils.js
---
(0111635)
hgbot   
2019-05-12 23:01   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 9e9ef1810ad675643d8342a03de251a5d55a70b1
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Sun May 12 23:01:41 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/9e9ef1810ad675643d8342a03de251a5d55a70b1 [^]

Related to issue 40847: Remove the execPostAddProductToOrderHook wrong call

---
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0111642)
hgbot   
2019-05-13 13:36   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 860e6af17df7ea0d839c4271cbb59dbeb3bd2ad9
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Mon May 13 13:36:10 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/860e6af17df7ea0d839c4271cbb59dbeb3bd2ad9 [^]

Related to issue 40847: Removed the not necessary 'product' parameter for the next hooks

OBPOS_CheckStockDeleteLine
OBPOS_CheckStockReturnLine
OBPOS_CheckStockPrePayment

---
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/pointofsale.js
M web/org.openbravo.retail.posterminal/js/utils/stockUtils.js
---
(0111693)
marvintm   
2019-05-15 18:33   
These changes are causing some tests in the quarantine to fail
(0111759)
hgbot   
2019-05-17 08:50   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 6d43a6d6cb63dfaf15583f61068caaa166f0c8ef
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Fri May 17 08:50:33 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/6d43a6d6cb63dfaf15583f61068caaa166f0c8ef [^]

Related to issue 40847: Fixed js null pointer error

---
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0112518)
hgbot   
2019-06-09 17:36   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: fe345470e106bfc8da96521214159b2ca9679b60
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Mon May 27 10:39:35 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/fe345470e106bfc8da96521214159b2ca9679b60 [^]

Related to issue 40847: Callback for duplicated lines
When a ticket has multiple lines with the same product and warehouse, the stock queries are done only for one line, but with the sum of the total lines. Now, even if the query is done only for one line, the callback function is executed for each one.

---
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/utils/stockUtils.js
---
(0112520)
hgbot   
2019-06-09 17:36   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: d7edd1bb5b08f9fcdfcc5ed4ac9341fde47290dd
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Tue Jun 04 10:15:14 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/d7edd1bb5b08f9fcdfcc5ed4ac9341fde47290dd [^]

Related to issue 40847: Fixed errors and new hook

Fixed errors in the order of the parameters in the OB.UTIL.StockUtils.checkStockSuccessCallback function.
Added new hook after adding a product to an order of a line that has stock (the stock has been checked).

---
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/utils/stockUtils.js
---
(0112521)
hgbot   
2019-06-09 17:36   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 6dd55c8f40b6467cde5b93e251b55e78b3222c2f
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Tue Jun 04 18:16:09 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/6dd55c8f40b6467cde5b93e251b55e78b3222c2f [^]

Related to issue 40847: Added the attrs parameter to the OBPOS_PreAddProductWithoutStock hook

Also moved logic that was in a hook to the primary code, taking into account that the delivery modes module is now in posterminal. That code is updated to execute only for discontinued products.

---
M web/org.openbravo.retail.posterminal/js/utils/stockUtils.js
R web/org.openbravo.retail.posterminal/js/hookPreAddProductWithoutStock.js
---
(0112523)
hgbot   
2019-06-09 17:36   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: bc1441767706a042803ec376da9544796873f21e
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Thu Jun 06 11:14:17 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/bc1441767706a042803ec376da9544796873f21e [^]

Related to issue 40847: Removed the deleted file from the component provider

---
M src/org/openbravo/retail/posterminal/OBPOSComponentProvider.java
---
(0112829)
hgbot   
2019-06-17 15:31   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 4c29dc7a6e59b480c8db01b90651a407378967e6
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Mon Jun 17 10:33:35 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/4c29dc7a6e59b480c8db01b90651a407378967e6 [^]

Related to issue 40847: New check to know offline status without calling the server

Also modified the stock callback function names.

---
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/utils/stockUtils.js
---