Openbravo Issue Tracking System - Openbravo ERP |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0032078 | Openbravo ERP | 04. Warehouse management | public | 2016-02-01 17:13 | 2016-03-17 10:56 |
|
Reporter | aferraz | |
Assigned To | aferraz | |
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | fixed | |
Platform | | OS | 5 | OS Version | |
Product Version | | |
Target Version | 3.0PR16Q2 | Fixed in Version | | |
Merge Request Status | |
Review Assigned To | dmiguelez |
OBNetwork customer | |
Web browser | |
Modules | Core |
Support ticket | |
Regression level | Packaging and release |
Regression date | 2015-12-04 |
Regression introduced in release | main |
Regression introduced by commit | https://code.openbravo.com/erp/devel/pi/rev/e32a6dfe59e6 [^] |
Triggers an Emergency Pack | No |
|
Summary | 0032078: Reserved quantity is not correct under certain circumstances |
Description | Reserved quantity is not correct under certain circumstances. |
Steps To Reproduce | Reservations are disabled by default. To be able to use them please insert a new Preference using property Enable Stock Reservations with value Y.
http://wiki.openbravo.com/wiki/Stock_Reservation [^] [^]
As group Admin role,
Go to Physical inventory and remove the stock for Cerveza Lager. Keep 700 units in Warehouse España Región Norte 0-0-0
Go to Sales Order window,
Org: España
Lines:
Cerveza Lager: qty: 900
Stock Reservation: blank
Book it.
Once you select the line, you will see Manage Reservations button. Click on it, and indicate you would like to reserve 400 units. Click on Done.
Go to Stock reservation window.
Realize that the register created indicates 900 units, but the user said 400. That is wrong.
If you "Manage Stock" again from the Stock Reservation window, and you indicate 400, now the "Reserved Qty" has the correct quantity that is 400. |
Proposed Solution | |
Additional Information | |
Tags | No tags attached. |
Relationships | related to | design defect | 0028051 | 3.0PR15Q2 | closed | umartirena | Reserved quantity is not correct under certain circumstancies | related to | defect | 0031876 | 3.0PR16Q2 | closed | aferraz | Cannot void a goods shipment if two lines are related with the same sales order line which is reserved and released | depends on | backport | 0032098 | 3.0PR16Q1 | closed | aferraz | Reserved quantity is not correct under certain circumstances | caused by | defect | 0031514 | | closed | markmm82 | Prereservation from Sales Order window is created in Completed status if there is available stock and in Draft if there is not | related to | defect | 0033752 | | closed | markmm82 | Cannot close an order if the stock was reserved and the associated goods shipment is voided | blocks | defect | 0032089 | | closed | aferraz | Product with stock in second UOM is automatically reserved but it is not possible to reserve it manually |
|
Attached Files | |
|
Issue History |
Date Modified | Username | Field | Change |
2016-02-01 17:13 | aferraz | New Issue | |
2016-02-01 17:13 | aferraz | Assigned To | => Triage Finance |
2016-02-01 17:13 | aferraz | Modules | => Core |
2016-02-01 17:13 | aferraz | Regression level | => Packaging and release |
2016-02-01 17:13 | aferraz | Regression date | => 2015-12-04 |
2016-02-01 17:13 | aferraz | Regression introduced in release | => main |
2016-02-01 17:13 | aferraz | Regression introduced by commit | => https://code.openbravo.com/erp/devel/pi/rev/e32a6dfe59e6 [^] |
2016-02-01 17:13 | aferraz | Triggers an Emergency Pack | => No |
2016-02-01 17:14 | aferraz | Relationship added | caused by 0031514 |
2016-02-01 17:14 | aferraz | Relationship added | related to 0028051 |
2016-02-02 13:26 | aferraz | Relationship added | related to 0031876 |
2016-02-02 14:34 | aferraz | Note Added: 0083850 | |
2016-02-02 14:38 | aferraz | Note Added: 0083851 | |
2016-02-02 17:13 | aferraz | Note Added: 0083858 | |
2016-02-02 17:13 | aferraz | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10857 |
2016-02-02 17:14 | aferraz | Status | new => scheduled |
2016-02-02 17:14 | aferraz | Assigned To | Triage Finance => aferraz |
2016-02-03 10:04 | psanjuan | Steps to Reproduce Updated | bug_revision_view_page.php?rev_id=10868#r10868 |
2016-02-03 10:05 | psanjuan | Steps to Reproduce Updated | bug_revision_view_page.php?rev_id=10869#r10869 |
2016-02-03 10:08 | psanjuan | Note Added: 0083885 | |
2016-02-03 10:32 | psanjuan | Note Edited: 0083850 | bug_revision_view_page.php?bugnote_id=0083850#r10871 |
2016-02-03 14:35 | psanjuan | Note Edited: 0083850 | bug_revision_view_page.php?bugnote_id=0083850#r10876 |
2016-02-03 14:36 | psanjuan | Note Edited: 0083850 | bug_revision_view_page.php?bugnote_id=0083850#r10877 |
2016-02-03 14:37 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10878 |
2016-02-03 15:21 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10879 |
2016-02-03 15:24 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10880 |
2016-02-03 15:29 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10884 |
2016-02-03 15:30 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10885 |
2016-02-03 15:31 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10886 |
2016-02-03 15:32 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10887 |
2016-02-03 15:33 | psanjuan | Note Edited: 0083858 | bug_revision_view_page.php?bugnote_id=0083858#r10889 |
2016-02-03 15:36 | psanjuan | Note Edited: 0083858 | bug_revision_view_page.php?bugnote_id=0083858#r10890 |
2016-02-03 15:43 | psanjuan | Note Added: 0083898 | |
2016-02-04 09:17 | psanjuan | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r10895 |
2016-02-04 09:19 | psanjuan | Note Edited: 0083898 | bug_revision_view_page.php?bugnote_id=0083898#r10897 |
2016-02-04 10:09 | psanjuan | Note Edited: 0083898 | bug_revision_view_page.php?bugnote_id=0083898#r10909 |
2016-02-05 11:40 | aferraz | Relationship added | related to 0032089 |
2016-02-05 13:20 | aferraz | Relationship deleted | related to 0032089 |
2016-02-05 13:20 | aferraz | Relationship added | blocks 0032089 |
2016-02-05 13:35 | hgbot | Checkin | |
2016-02-05 13:35 | hgbot | Note Added: 0083970 | |
2016-02-05 13:35 | hgbot | Status | scheduled => resolved |
2016-02-05 13:35 | hgbot | Resolution | open => fixed |
2016-02-05 13:35 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/acc489e2a1839a10a53a3302b96b248ec4e13f5b [^] |
2016-02-05 13:36 | dmiguelez | Review Assigned To | => dmiguelez |
2016-02-05 13:36 | dmiguelez | Note Added: 0083973 | |
2016-02-05 13:36 | dmiguelez | Status | resolved => closed |
2016-03-17 10:56 | hudsonbot | Checkin | |
2016-03-17 10:56 | hudsonbot | Note Added: 0085109 | |
2016-08-20 21:54 | aferraz | Relationship added | related to 0033752 |
2018-07-19 11:51 | AtulOpenbravo | Note Edited: 0083851 | bug_revision_view_page.php?bugnote_id=0083851#r17432 |
Notes |
|
(0083850)
|
aferraz
|
2016-02-02 14:34
(edited on: 2016-02-03 14:36) |
|
Test plan I:
As group admin role:
Create the Enable Stock Reservations preference
Log out and log in
Create a product for España named "32078 A"
Add a price list for "Tarifa de Bebidas Alegres" and "Tarifa de ventas" .
Create a receipt for created product with qty=10 in RN-0-0-0 locator.
Create a sales order, add the previously created product and qty=10. Complete it.
Add a reservation to it of qty=7 in RN-0-0-0.
Realize a stock reservation has been created with qty=10, reserved qty=7, released=0 and a line with qty=7 released=0 in RN-0-0-0.
Create another receipt for the same product.
This time received 100 units in the storage bin RN-1-0-0. Complete it.
Create a sales order, add previously created product and qty = 50.
Complete it.
Add reservation to it of qty=50 from RN-1-0-0.
Realize that a new stock reservation has been created with qty = 50, Reserved qty= 50
|
|
|
(0083851)
|
aferraz
|
2016-02-02 14:38
(edited on: 2018-07-19 11:51) |
|
Test plan II:
As group admin role:
Create the Enable Stock Reservations preference
Log out and log in
Create a product for España named "32078 B"
Add a price list for "Tarifa de Bebidas Alegres" and "Tarifa de ventas".
Create a Purchase Order for that product and qty=10. Book it.
Create a Sales Order for the same product and qty=10. Book it.
Go to the line, click on Manage Reservation button and select the purchase order line and enter 10 in the column Quantity.
Realize a stock reservation has been created with qty=10, reserved qty=10, released=0 and a line related with purchase order line with qty=10 and released=0.
Create another Purchase Order for that product and qty=100. Book it.
Create a Sales Order for the same product and qty=90. Book it.
Go to the line, click on Manage Reservation button and select the purchase order line and enter 50 in the column Quantity.
Realize a stock reservation has been created with qty=90, reserved qty=50, released=0.
Create a Goods Receipt from the purchase order, receipt all 100 units in storage bin RN-1-0-0.Complete it.
Create a Goods Shipment fro the sales order, to ship 90 units from the storage bin RN-1-0-0. Complete it.
Go to the Stock reservation and verify it has changed as below:
- Quantity = 90
- Reserved Qty = 50
- Released = 50
|
|
|
(0083858)
|
aferraz
|
2016-02-02 17:13
(edited on: 2016-02-03 15:36) |
|
Test plan III:
As group admin role:
Create the Enable Stock Reservations preference
Log out and log in
Create a product for España, named "32078 C".
Add a price list for "Tarifa de Bebidas Alegres" and "Tarifa de ventas".
Create a Goods Receipt for that product and qty=10 in RN-0-0-0. Complete it.
Create a Purchase Order for that product and qty=10. Book it.
Create a Sales Order for the same product and qty=10. Book it.
Go to the line, click on Manage Reservation button and select the purchase order line, enter a qty=10
Realize a stock reservation has been created with qty=10, reserved qty=10, released=0 and a line related with purchase order line with qty=10 and released=0.
Once more:
Create a Goods Receipt for that product and qty=10 in RN-0-0-0. Complete it.
Create a Purchase Order for that product and qty=20. Book it.
Create a Sales Order for the same product and qty=10. Book it.
Go to the line, click on Manage Reservation button and select the purchase order line, enter a qty=10
Realize a stock reservation has been created with qty=10, reserved qty=10, released=0 and a line related with purchase order line with qty=10 and released=0.
|
|
|
|
|
|
(0083898)
|
psanjuan
|
2016-02-03 15:43
(edited on: 2016-02-04 10:09) |
|
Test Plan above verified.
Issue can be code review and closed.
|
|
|
(0083970)
|
hgbot
|
2016-02-05 13:35
|
|
Repository: erp/devel/pi
Changeset: acc489e2a1839a10a53a3302b96b248ec4e13f5b
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Fri Feb 05 11:37:39 2016 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/acc489e2a1839a10a53a3302b96b248ec4e13f5b [^]
Fixes issue 32078: Reserved quantity is not correct
In ManageReservationActionHandler, when clicking Done in Manage Reservation P&E, it was first reserving what the user was typing in the P&E, and if it was not processed the reservation, it was processing it. As the M_RESERVATION_POST tries always to reserve as much as possible, it was overriding the previously set amounts. In order to prevent this, now first the reservation is being processed and after that the values typed in the UI are being set to the reservation.
In case no stock reservation is created by m_reservation_post when processing the reservation, res_status will be Draft. To be sure reservation is set as completed, force status after call ReservationUtils.processReserve method.
Reservation will only be kept as draft in case it has no lines after execute manageReservedStockLines.
---
M src/org/openbravo/common/actionhandler/ManageReservationActionHandler.java
---
|
|
|
|
|
|
|
|