Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0028113
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 04. Warehouse managementmajoralways2014-11-06 18:052014-12-30 23:26
ReporterpsanjuanView Statuspublic 
Assigned Toumartirena 
PriorityurgentResolutionfixedFixed in Version3.0PR15Q1
StatusclosedFix in branchFixed in SCM revision7084255c151e
ProjectionnoneETAnoneTarget Version
OSLinux 32 bitDatabaseOracleJava version1.6
OS VersionUbuntu 8.04.1Database version11.1.0.6.0Ant version1.7.0
Product VersionSCM revision 
Review Assigned ToSandrahuguet
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0028113: [Costing] wrong negative stock correction adjustment

Description[Costing] wrong negative stock correction adjustment
Steps To ReproduceIn QA Testing Client create a new product named Costing V221.
Select a purchase price list and enter a unit/list price of 15.00

Go to purchase order and create a new one dated on 17/10/2014. Select the product and enter 500 units. Book the order.

Go to purchase order and create a new one dated on 18/10/2014. Select the product and enter 700 units. Change the price to 12.00. Book the order.

Go to goods receipt window and create a new one dated on 19/10/2014. Select the first purchase order and receipt 150 units. Complete the receipt.

Go to process request window and launch costing background process.

Go to the goods receipt and post it. Realize that the value post is 2250 (150 units * 15.00)

Go to goods shipment window and create a new one dated on 20/10/2014. Enter 600 units.

Go to process request window and launch costing background process.

Go to the goods shipment and post it. Realize that the value post is 9000 (600 units * 15.00)

Go to goods receipt window and create a new one dated on 22/10/2014. Select the second purchase order and receipt 500 units.

Go to process request window and launch costing background process.

Go to the goods receipt and post it. Realize that the value post is 6000 (500 units * 12.00)

Go to Cost adjustment window and realize that negative stock correction one has been created for an adjustment amount of X= 1350 (2250-9000+6000+X)/50 = 12

Go to Product window, search the product and navigate to Costing tab. Realize that cost shown is 12, Total mov quty = 50

Go to purchase invoice window and create a new one dated on 30/10/2014. Create purchase lines by using "Create Lines From" button, selecting both purchase order.

Change 150 units line price from 15.00 to 20.00
Change 500 units line price from 12.00 to 18.00

Complete and post the invoice.

Go to process request window and launch price correction background process.

Go to Cost adjustment window and realize that a price difference correction has been created including below adjustments:

1.- Vendor receipt dated on 19/10/2014 - Adj Amount 750.00 (150 units * 20.00 - 150 units * 15.00)
2.- Vendor receipt dated on 22/10/2014 - Adj Amount 3000.00 (500 units * 18.00 - 500 units * 12.00)
3.- Customer Shipment dated on 20/10/2014 - Adj Amount 3000.00 (600 units * 20.00 - 600 units * 15.00)
4 - Vendor receipt dated on 22/10/2014 - Set as Negative Stock Correction- Adj Amount -315 - this last adjustment is not correct.

Correct negative stock correction adjustment should be: -450 = (2250+750-9000-3000+6000+1350+3000+X)/50 = 18

Go to the product window, search the product and navigate to costing tab. Realize that there are two lines.

Line 1 related to Vendor receipt 19/10/2014 inventory transaction - Cost 20 - total mov quantity - 150 - this is correct

Line 2 related to Vendor receipt 22/10/2014 inventory transaction - Cost 20.7 - total mov quanity - 50 - this is NOT correct as it should have a cost of 18.00




Proposed SolutionCorrect negative stock correction adjustment should be: -450 = (2250+750-9000-3000+6000+1350+3000+X)/50 = 18

Go to the product window, search the product and navigate to costing tab.
There should be below two lines.

Line 1 related to Vendor receipt 19/10/2014 inventory transaction - Cost 20 - total mov quantity - 150

Line 2 related to Vendor receipt 22/10/2014 inventory transaction - Cost 18.00 - total mov quanity - 50
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0028029 closedumartirena [Costing] Negative Stock Correction adjustments should NOT be marked as "Unit Cost". 

-  Notes
(0071562)
hgbot (developer)
2014-11-11 17:21

Repository: erp/devel/pi
Changeset: c05011cca9f937e4969fe2577ffcb9b122817835
Author: Unai Martirena <unai.martirena <at> openbravo.com>
Date: Tue Nov 11 17:20:36 2014 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/c05011cca9f937e4969fe2577ffcb9b122817835 [^]

Fixes bug 28113: Use costing Price to calculate Adjustment Amount

In some cases the transaction price it was not being properly calculated in order to calculate the negative stock correction amounts. Starting from now the Net Unit Price field of Costing tab will be used in Cost Adjustments. To get the transaction price this Net Unit Price will be used.

---
M src/org/openbravo/costing/AverageCostAdjustment.java
---
(0071581)
psanjuan (manager)
2014-11-12 09:35

Verified.
See product: Costing V221 test in the excel sheet below:
https://docs.google.com/a/openbravo.com/spreadsheets/d/1Ilm1oct0vH4iKFlI1I0VbmYM-r8fdo1moK02jd2Zigg/edit#gid=1025660841 [^]
(0071600)
umartirena (developer)
2014-11-12 12:21

Reopened due to rounding amount issues.
(0071601)
hgbot (developer)
2014-11-12 12:22

Repository: erp/devel/pi
Changeset: b852c03d58e701020cdbbd66d3875331c77f7ca0
Author: Unai Martirena <unai.martirena <at> openbravo.com>
Date: Wed Nov 12 11:56:25 2014 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/b852c03d58e701020cdbbd66d3875331c77f7ca0 [^]

Related to Issue 28113: Add some missing currency roundings

---
M src/org/openbravo/costing/AverageCostAdjustment.java
---
(0071614)
aferraz (developer)
2014-11-12 19:34

Verified.
(0072278)
hgbot (developer)
2014-12-04 12:21

Repository: erp/devel/pi
Changeset: 7084255c151e87dba55b4f7a7c475b4db9f277a0
Author: Unai Martirena <unai.martirena <at> openbravo.com>
Date: Thu Dec 04 12:12:34 2014 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/7084255c151e87dba55b4f7a7c475b4db9f277a0 [^]

Related to Issue 28113: Revert a change on issue 28115.

In this cases the net unit price is the cost of the transaction

---
M src/org/openbravo/costing/AverageCostAdjustment.java
---
(0072284)
psanjuan (manager)
2014-12-04 14:49

Verified.
(0072305)
psanjuan (manager)
2014-12-05 10:49

Issue resolved that was closed by mistake.
Code review required to close the issue.
(0072452)
Sandrahuguet (developer)
2014-12-12 14:33

Code review done
(0073042)
hudsonbot (developer)
2014-12-30 23:24

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/6525fe229e06 [^]
Maturity status: Test
(0073049)
hudsonbot (developer)
2014-12-30 23:24

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/6525fe229e06 [^]
Maturity status: Test
(0073170)
hudsonbot (developer)
2014-12-30 23:26

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/6525fe229e06 [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2014-11-06 18:05 psanjuan New Issue
2014-11-06 18:05 psanjuan Assigned To => dmiguelez
2014-11-06 18:05 psanjuan Modules => Core
2014-11-06 18:05 psanjuan Triggers an Emergency Pack => No
2014-11-06 18:06 psanjuan Relationship added related to 0028029
2014-11-07 09:20 psanjuan Assigned To dmiguelez => umartirena
2014-11-07 11:32 psanjuan Steps to Reproduce Updated View Revisions
2014-11-07 11:38 psanjuan Steps to Reproduce Updated View Revisions
2014-11-07 11:46 psanjuan Steps to Reproduce Updated View Revisions
2014-11-07 11:46 psanjuan Proposed Solution updated
2014-11-07 11:49 psanjuan Steps to Reproduce Updated View Revisions
2014-11-07 11:51 psanjuan Proposed Solution updated
2014-11-11 17:21 hgbot Checkin
2014-11-11 17:21 hgbot Note Added: 0071562
2014-11-11 17:21 hgbot Status new => resolved
2014-11-11 17:21 hgbot Resolution open => fixed
2014-11-11 17:21 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/c05011cca9f937e4969fe2577ffcb9b122817835 [^]
2014-11-12 09:35 psanjuan Note Added: 0071581
2014-11-12 09:35 psanjuan Status resolved => closed
2014-11-12 12:21 umartirena Note Added: 0071600
2014-11-12 12:21 umartirena Status closed => new
2014-11-12 12:21 umartirena Resolution fixed => open
2014-11-12 12:22 hgbot Checkin
2014-11-12 12:22 hgbot Note Added: 0071601
2014-11-12 12:29 umartirena Status new => scheduled
2014-11-12 12:29 umartirena fix_in_branch => pi
2014-11-12 12:30 umartirena Status scheduled => resolved
2014-11-12 12:30 umartirena Fixed in Version => pi
2014-11-12 12:30 umartirena Fixed in SCM revision http://code.openbravo.com/erp/devel/pi/rev/c05011cca9f937e4969fe2577ffcb9b122817835 [^] => https://code.openbravo.com/erp/devel/pi/rev/b852c03d58e7 [^]
2014-11-12 12:30 umartirena Resolution open => fixed
2014-11-12 13:45 psanjuan Status resolved => closed
2014-11-12 13:45 psanjuan fix_in_branch pi =>
2014-11-12 19:31 aferraz Status closed => new
2014-11-12 19:31 aferraz Resolution fixed => open
2014-11-12 19:31 aferraz Fixed in Version pi =>
2014-11-12 19:33 aferraz Steps to Reproduce Updated View Revisions
2014-11-12 19:33 aferraz Proposed Solution updated
2014-11-12 19:33 aferraz Status new => scheduled
2014-11-12 19:33 aferraz fix_in_branch => pi
2014-11-12 19:34 aferraz Status scheduled => resolved
2014-11-12 19:34 aferraz Resolution open => fixed
2014-11-12 19:34 aferraz Review Assigned To => aferraz
2014-11-12 19:34 aferraz Note Added: 0071614
2014-11-12 19:34 aferraz Status resolved => closed
2014-11-17 10:42 aferraz Status closed => new
2014-11-17 10:42 aferraz Resolution fixed => open
2014-11-27 13:19 psanjuan Relationship added related to 0028301
2014-12-01 10:40 psanjuan Relationship deleted related to 0028301
2014-12-02 13:30 umartirena fix_in_branch pi =>
2014-12-02 13:30 umartirena Steps to Reproduce Updated View Revisions
2014-12-04 12:21 hgbot Checkin
2014-12-04 12:21 hgbot Note Added: 0072278
2014-12-04 12:24 umartirena Status new => scheduled
2014-12-04 12:24 umartirena fix_in_branch => pi
2014-12-04 12:24 umartirena Status scheduled => resolved
2014-12-04 12:24 umartirena Fixed in Version => pi
2014-12-04 12:24 umartirena Fixed in SCM revision https://code.openbravo.com/erp/devel/pi/rev/b852c03d58e7 [^] => https://code.openbravo.com/erp/devel/pi/rev/7084255c151e [^]
2014-12-04 12:24 umartirena Resolution open => fixed
2014-12-04 14:49 psanjuan Status resolved => closed
2014-12-04 14:49 psanjuan fix_in_branch pi =>
2014-12-04 14:49 psanjuan Note Added: 0072284
2014-12-05 10:49 psanjuan Note Added: 0072305
2014-12-05 10:49 psanjuan Status closed => new
2014-12-05 10:50 psanjuan Status new => scheduled
2014-12-05 10:55 umartirena Status scheduled => resolved
2014-12-11 18:21 Sandrahuguet Review Assigned To aferraz => Sandrahuguet
2014-12-12 14:33 Sandrahuguet Note Added: 0072452
2014-12-12 14:33 Sandrahuguet Status resolved => closed
2014-12-12 14:33 Sandrahuguet Fixed in Version pi => 3.0PR15Q1
2014-12-30 23:24 hudsonbot Checkin
2014-12-30 23:24 hudsonbot Note Added: 0073042
2014-12-30 23:24 hudsonbot Checkin
2014-12-30 23:24 hudsonbot Note Added: 0073049
2014-12-30 23:26 hudsonbot Checkin
2014-12-30 23:26 hudsonbot Note Added: 0073170


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker