Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0038469Openbravo ERP04. Warehouse managementpublic2018-04-27 14:032018-05-14 13:09
ngarcia 
collazoandy4 
urgentmajoralways
closedfixed 
5
 
3.0PR18Q3 
aferraz
Core
No
0038469: Wrong Total Movement Quantity and Stock Valuation resulting in wrong average cost if Costing Rule 'Fix Backdated From' is empty
Wrong Total Movement Quantity and Stock Valuation resulting in wrong average cost if Costing Rule 'Fix Backdated From' is empty
As group admin role:
   Create a Legal With Accounting Organization and set it as ready
   Create the required master data on it: vendor, product, tax category, warehouse, storage bin (2)
   Open the current period
   Create a new costing rule for that organization
   Select Backdated Transactions Fixed
   Leave empty Starting Date and Fix Backdated From fields
   Validate it
   Create a goods receipt with today's date, include the previously created product and complete it
   Create a Physical Inventory with tomorrow's date
   Decrease the stock of the product in 1 unit
   Create a goods receipt with the day after tomorrow, include the previously created product and complete it
   Schedule the Costing Background Process to be run immediately and check it finishes successfully
   Check in the last entry in Product - Costing tab that Total Movement Quantity does not match the sum of the movement quantities in Product Transactions tab (the output transaction is not taken into account)
Attached a possible patch to be tested
No tags attached.
diff 38469test.diff (1,193) 2018-04-27 14:04
https://issues.openbravo.com/file_download.php?file_id=11771&type=bug
Issue History
2018-04-27 14:03ngarciaNew Issue
2018-04-27 14:03ngarciaAssigned To => Triage Finance
2018-04-27 14:03ngarciaModules => Core
2018-04-27 14:03ngarciaResolution time => 1526594400
2018-04-27 14:03ngarciaTriggers an Emergency Pack => No
2018-04-27 14:04ngarciaFile Added: 38469test.diff
2018-04-27 14:04ngarciaProposed Solution updated
2018-04-27 14:04ngarciaIssue Monitored: networkb
2018-05-03 18:27dmiguelezAssigned ToTriage Finance => collazoandy4
2018-05-04 22:50collazoandy4Statusnew => scheduled
2018-05-09 17:28collazoandy4Note Added: 0104359
2018-05-10 18:45hgbotCheckin
2018-05-10 18:45hgbotNote Added: 0104461
2018-05-10 18:45hgbotStatusscheduled => resolved
2018-05-10 18:45hgbotResolutionopen => fixed
2018-05-10 18:45hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/8ba7ab55dd7aa9c60cbfd47cee04dd155690ef2d [^]
2018-05-10 18:48aferrazReview Assigned To => aferraz
2018-05-10 18:48aferrazNote Added: 0104462
2018-05-10 18:48aferrazStatusresolved => closed
2018-05-10 18:48aferrazFixed in Version => 3.0PR18Q3
2018-05-14 13:09hudsonbotCheckin
2018-05-14 13:09hudsonbotNote Added: 0104494

Notes
(0104359)
collazoandy4   
2018-05-09 17:28   
As group admin role:
  Create a Legal With Accounting Organization and set it as ready
  Create the required master data on it: vendor, product, tax category, warehouse, storage bin
  Go to Open/Close Period Control window and open de period created
  Create a new costing rule for the organization, Backdated Transactions Fixed: 'Y' and leave empty the Starting Date and Fix Backdated From fields. Validate it
  Create a Goods receipt with today's date, include the previously created product and complete it
  Create a Physical Inventory with tomorrow's date
  Decrease the stock of the product in 1 unit
  Create a Goods receipt with the day after tomorrow, include the previously created product and complete it
  Schedule the Costing Background Process to be run immediately and check it finishes successfully
  Check in the last entry in Product - Costing tab that Total Movement Quantity match the sum of the movement quantities in Product Transactions tab (the output transaction is now taken into account)
(0104461)
hgbot   
2018-05-10 18:45   
Repository: erp/devel/pi
Changeset: 8ba7ab55dd7aa9c60cbfd47cee04dd155690ef2d
Author: Armaignac <collazoandy4 <at> gmail.com>
Date: Mon May 07 18:21:59 2018 -0400
URL: http://code.openbravo.com/erp/devel/pi/rev/8ba7ab55dd7aa9c60cbfd47cee04dd155690ef2d [^]

Fixes issue 38469:Wrong Total Movement Quantity and Stock Valuation resulting in
wrong average cost if Costing Rule 'Fix Backdated From' is empty

---
M src/org/openbravo/costing/CostingUtils.java
---
(0104462)
aferraz   
2018-05-10 18:48   
Code review + Testing OK
(0104494)
hudsonbot   
2018-05-14 13:09   
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/ed385e0e027b [^]
Maturity status: Test