Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0042515 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] 04. Warehouse management | major | always | 2019-12-11 12:15 | 2020-03-20 17:54 | |||
Reporter | gorkaion | View Status | public | |||||
Assigned To | AtulOpenbravo | |||||||
Priority | high | Resolution | fixed | Fixed in Version | 3.0PR20Q2 | |||
Status | closed | Fix in branch | Fixed in SCM revision | 7443fbd2b224 | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Merge Request Status | ||||||||
Review Assigned To | dmiguelez | |||||||
OBNetwork customer | OBPS | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | 13616 | |||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0042515: Wrong cost calculated for backdated goods movements | |||||||
Description | When a backdated goods movement is processed the cost is wrongly calculated. The M- transaction is correctly adjusted, but the M+ is not. This results that the transactions have different total cost which is wrong. When the cost of the M+ transaction is calculated it should be 20 instead of 25 as it should consider all the adjustments done to the M- transaction. | |||||||
Steps To Reproduce | 1. Login as F&B International 2. Create a New Costing Rules : Organization : F&B US, Inc, Average, Fix BackDate : Y 3. Create New Product : Product A, Organization : F&B US, Inc. , Type : Item, Stocked = Yes 4. Create Physical Inventory :Date : Today, Product A, Qty 100, Cost: USD1 , warehouse : US East Cost 5. Create Physical Inventory : Date : Tomorrow, Product A, Qty : 200, Cost USD1.5 , Warehouse : US East Cost 6. Product A Total Stock : 200, Avg Cost USD1.25 7. Goods Movement : Date : Today, Product A, Qty 20, From Us East Cost To US West Cost (back date transaction) 8. Execute Costing Process 9. Go to Window Product, select Product A, go to tab transaction, there are 4 transaction there, 10. Check the total cost for M+ & M-. * M- is 20 (correct) * M+ is 25 (wrong) 11. Check average costs: * M+ avg is 1.05 -> it should be 1 * 2nd Inv. Avg is 1.28 -> it should be 1.25 | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
|
![]() |
|
(0116683) AtulOpenbravo (viewer) 2020-01-08 09:43 |
Test Plan 1. Login as F&B International 2. Create a New Costing Rule Organization : F&B US, Inc, Costing Algorithm: Average Fix BackDate : Y 3. Create New Product : Product A, Organization : F&B US, Inc. , Type : Item, Stocked = Yes 4. Create Physical Inventory (1st) Movement Date : Today, Product A, Qty 100, Cost: USD 1 Warehouse : US East Cost 5. Create another Physical Inventory (2nd) Movement Date : Today +1, Product A, Qty : 200, Cost USD 1.5 Warehouse : US East Cost 6. Schedule Costing Background process in Process Request. 7. Check that Product A has Total Stock : 200, Avg Cost USD 1.25 8. Create a Goods Movement Movement Date : Today, Product A, Qty 20, From Us East Cost To US West Cost 9. Execute Costing Background Process 10. Go to Window Product, select Product A, go to tab transaction, there are 4 transaction there, 11. Check the total cost for M+ & M-. * M- is 20 (This is correct) * M+ is 20 (This is correct) 12. Check average costs: * M+ avg is 1 * 2nd Inv. Avg is 1.25 This is correct. |
(0116714) hgbot (developer) 2020-01-09 08:12 |
Repository: erp/devel/pi Changeset: 7443fbd2b22481ddf912d350cf01420359d0d393 Author: Atul Gaware <atul.gaware <at> openbravo.com> Date: Tue Jan 07 18:37:21 2020 +0530 URL: http://code.openbravo.com/erp/devel/pi/rev/7443fbd2b22481ddf912d350cf01420359d0d393 [^] Fixes BUG-42515:Wrong cost calculated for backdated goods movements **Implement a method to get cost adjustment amount from related Movement From Transaction to consider it into the outgoing Movement To Transaction --- M src/org/openbravo/costing/CostingAlgorithmAdjustmentImp.java --- |
(0116715) hgbot (developer) 2020-01-09 08:12 |
Repository: erp/devel/pi Changeset: a7b87d4144703b58dbf34ad346a29a56b2aee72f Author: David Miguelez <david.miguelez <at> openbravo.com> Date: Wed Jan 08 18:36:44 2020 +0100 URL: http://code.openbravo.com/erp/devel/pi/rev/a7b87d4144703b58dbf34ad346a29a56b2aee72f [^] Related to Issue 42515: Code Review changes * Added final modifiers to variables and parameters * Combined logic of if clauses into one and extracted the condition into a different method * Use a query to retrieve the TransactionCosts instead of looping throught the generated .getList method and then filter the results. --- M src/org/openbravo/costing/CostingAlgorithmAdjustmentImp.java --- |
(0116716) dmiguelez (viewer) 2020-01-09 08:13 |
Code Review + Testing Ok |
(0118724) hudsonbot (viewer) 2020-03-20 17:54 |
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/b31620115262 [^] Maturity status: Test |
![]() |
|||
Date Modified | Username | Field | Change |
2019-12-11 12:15 | gorkaion | New Issue | |
2019-12-11 12:15 | gorkaion | Assigned To | => Triage Finance |
2019-12-11 12:15 | gorkaion | OBNetwork customer | => OBPS |
2019-12-11 12:15 | gorkaion | Modules | => Core |
2019-12-11 12:15 | gorkaion | Support ticket | => 13616 |
2019-12-11 12:15 | gorkaion | Resolution time | => 1577833200 |
2019-12-11 12:15 | gorkaion | Triggers an Emergency Pack | => No |
2019-12-12 08:37 | dmiguelez | Assigned To | Triage Finance => AtulOpenbravo |
2019-12-20 12:43 | AtulOpenbravo | Status | new => scheduled |
2020-01-08 09:43 | AtulOpenbravo | Note Added: 0116683 | |
2020-01-09 08:12 | hgbot | Checkin | |
2020-01-09 08:12 | hgbot | Note Added: 0116714 | |
2020-01-09 08:12 | hgbot | Status | scheduled => resolved |
2020-01-09 08:12 | hgbot | Resolution | open => fixed |
2020-01-09 08:12 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/7443fbd2b22481ddf912d350cf01420359d0d393 [^] |
2020-01-09 08:12 | hgbot | Checkin | |
2020-01-09 08:12 | hgbot | Note Added: 0116715 | |
2020-01-09 08:13 | dmiguelez | Review Assigned To | => dmiguelez |
2020-01-09 08:13 | dmiguelez | Note Added: 0116716 | |
2020-01-09 08:13 | dmiguelez | Status | resolved => closed |
2020-01-09 08:13 | dmiguelez | Fixed in Version | => 3.0PR20Q2 |
2020-03-20 17:54 | hudsonbot | Checkin | |
2020-03-20 17:54 | hudsonbot | Note Added: 0118724 |
Copyright © 2000 - 2009 MantisBT Group |