Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0032390Openbravo ERP07. Sales managementpublic2016-03-02 18:372016-03-23 01:59
ngarcia 
markmm82 
urgentmajoralways
closedfixed 
5
 
3.0PR16Q2 
aferraz
Core
No
0032390: Cannot close an order with an allocated reservation if the released quantity is smaller than half the total reserved quantity
Cannot close an order with an allocated reservation if the released quantity is smaller than half the total reserved quantity
As group admin role:
   Create the Enable Stock reservations preference
   Log out and log in
   Create three sales orders of 10 units each.
   Reserve the 10 units of the three orders and set the reservations as allocated
   Create a goods shipment with 2, 5 and 8 units of each sales order respectively
   Check the sales orders with 5 and 8 units released can be closed
   Try to close the one with 2 units released and check the following error message is shown:
      "There is more allocated quantity than ordered quantity"
No tags attached.
related to defect 0033752 closed markmm82 Cannot close an order if the stock was reserved and the associated goods shipment is voided 
related to defect 0035270 closed collazoandy4 Wrong reservation when closing a sales order with a voided partial shipment 
Issue History
2016-03-02 18:37ngarciaNew Issue
2016-03-02 18:37ngarciaAssigned To => Triage Finance
2016-03-02 18:37ngarciaModules => Core
2016-03-02 18:37ngarciaResolution time => 1459893600
2016-03-02 18:37ngarciaTriggers an Emergency Pack => No
2016-03-02 18:37ngarciaIssue Monitored: networkb
2016-03-03 10:22heccamIssue Monitored: heccam
2016-03-03 19:01aferrazAssigned ToTriage Finance => aferraz
2016-03-03 19:01aferrazStatusnew => scheduled
2016-03-08 10:41aferrazNote Added: 0084811
2016-03-08 10:42aferrazAssigned Toaferraz => Triage Finance
2016-03-08 10:42aferrazStatusscheduled => acknowledged
2016-03-08 10:42aferrazStatusacknowledged => scheduled
2016-03-08 10:42aferrazStatusscheduled => feedback
2016-03-08 10:42aferrazStatusfeedback => new
2016-03-14 16:01markmm82Statusnew => scheduled
2016-03-14 16:01markmm82Assigned ToTriage Finance => markmm82
2016-03-16 13:52markmm82Note Added: 0085008
2016-03-17 12:57aferrazNote Edited: 0084811bug_revision_view_page.php?bugnote_id=0084811#r11483
2016-03-17 13:37psanjuanSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=11485#r11485
2016-03-17 14:41psanjuanNote Added: 0085203
2016-03-17 14:54psanjuanNote Edited: 0085008bug_revision_view_page.php?bugnote_id=0085008#r11487
2016-03-17 14:57psanjuanNote Added: 0085209
2016-03-17 14:59psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11489
2016-03-17 14:59psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11490
2016-03-17 15:00psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11491
2016-03-17 15:03psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11492
2016-03-17 15:07psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11493
2016-03-17 15:10psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11494
2016-03-17 15:20psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11495
2016-03-17 15:24psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11496
2016-03-17 15:25psanjuanNote Added: 0085210
2016-03-21 11:48psanjuanNote Edited: 0085209bug_revision_view_page.php?bugnote_id=0085209#r11502
2016-03-21 11:49psanjuanNote Added: 0085238
2016-03-22 20:11hgbotCheckin
2016-03-22 20:11hgbotNote Added: 0085267
2016-03-22 20:11hgbotStatusscheduled => resolved
2016-03-22 20:11hgbotResolutionopen => fixed
2016-03-22 20:11hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/c348f263a0a40d6739dee137f55bd3904fabc13c [^]
2016-03-22 20:12aferrazReview Assigned To => aferraz
2016-03-22 20:12aferrazNote Added: 0085268
2016-03-22 20:12aferrazStatusresolved => closed
2016-03-22 20:12aferrazFixed in Version => 3.0PR16Q2
2016-03-23 01:59hudsonbotCheckin
2016-03-23 01:59hudsonbotNote Added: 0085276
2016-08-20 21:52aferrazRelationship addedrelated to 0033752
2017-03-23 09:33aferrazRelationship addedrelated to 0035270

Notes
(0084811)
aferraz   
2016-03-08 10:41   
(edited on: 2016-03-17 12:57)
When closing the sales order, if related reservation exists with pending allocated reserved quantity, an error should be shown to force user undo allocated reservation.

(0085008)
markmm82   
2016-03-16 13:52   
(edited on: 2016-03-17 14:54)
Test plan 1:
As group admin role:
   Create the Enable Stock reservations preference
   Log out and log in
   Create three sales orders of 10 units
   Reserve the 10 units of the three orders and set the reservations as allocated
   Create a goods shipment with 2, 5 and 8 units of each sales order respectively
   Try to close any of previous sales orders (with 2,5,8 units released) and check the following error message is shown:
      "There is more allocated quantity than ordered quantity"

Test plan 2:
   Create a sales order of 10 units
   Reserve the 10 units and set the reservations as allocated
   Create a goods shipment with 10 units of this sales order
   Check the sales orders created with 10 units released can be closed.

(0085203)
psanjuan   
2016-03-17 14:41   
Issue verified.
(0085209)
psanjuan   
2016-03-17 14:57   
(edited on: 2016-03-21 11:48)
Test plan 1:

As group admin role:
   Create the Enable Stock reservations preference
   Log out and log in
   Create a product named "Issue 32390" in F&B EspaƱa.
   Relate it to a purchase price list (Tarifa Bebidas Alegres) and a sales price list (Tarifa de Ventas).
   Create a goods receipt of 40 units.
   Create a sales orders of 10 units
   Reserve the 10 units as allocated
   Create a goods shipment for 2 units by using "Create Lines From" process
   After that try to close the sales order.
   Check the following error message is shown, which is correct:
"There is more allocated quantity than ordered quantity"

   Either:
   - Set allocated quantity to 2, same as released quantity by using "Manage Reservation" button
   - or remove allocated check by using "Manage Reservation" button
   Press Done.
   Close the order
   
Repeat same steps as above but creating each a sales order for 10 units but shipping 5, 8 and 10 units, each time.
In the case of shipping 10 units, there is not need to execute any further action but to close the order, as the full order is shipped.

(0085210)
psanjuan   
2016-03-17 15:25   
Test plan above verified.

Please improve error message as:

"There is more allocated quantity than delivered quantity"

Issue can be code reviewed and closed.
(0085238)
psanjuan   
2016-03-21 11:49   
Test Plan above verified. Error message improved.
(0085267)
hgbot   
2016-03-22 20:11   
Repository: erp/devel/pi
Changeset: c348f263a0a40d6739dee137f55bd3904fabc13c
Author: Mark <m.molina <at> nectus.com>
Date: Fri Mar 18 12:40:41 2016 -0400
URL: http://code.openbravo.com/erp/devel/pi/rev/c348f263a0a40d6739dee137f55bd3904fabc13c [^]

Fixes issue 32390: Cannot close an order with an allocated reservation if is not released the total reserved quantity.

Cannot close an order with an allocated reservation if the released quantity is different than the total reserved quantity.

---
M src-db/database/model/functions/C_ORDER_POST1.xml
M src-db/database/sourcedata/AD_MESSAGE.xml
---
(0085268)
aferraz   
2016-03-22 20:12   
Code review OK
(0085276)
hudsonbot   
2016-03-23 01:59   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/f4f7526c0d97 [^]
Maturity status: Test