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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0032012
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 04. Warehouse managementmajoralways2016-01-26 12:272016-07-20 11:36
ReporterVictorVillarView Statuspublic 
Assigned Toaferraz 
PriorityurgentResolutionfixedFixed in Version3.0PR16Q2
StatusclosedFix in branchFixed in SCM revisiond74b9acdfd3c
ProjectionnoneETAnoneTarget Version3.0PR16Q2
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionpiSCM revision 
Review Assigned Todmiguelez
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0032012: Not possible to either validate a costing rule or create an inventory amount update under some circumstancies

DescriptionNot possible to either validate a costing rule or create an inventory amount update under some circumstancies
Steps To ReproduceIf the client was working with a Product A with uom: unit. Then remove the stock and change the unit of measure to pallet and create new warehouse transactions, having stock.
It will not be possible to validate a costing rule in the past defining an Starting date different than null. Error @DocUOMMismatch@ 60 when trying to process the closing inventory because the current product uom is different than the one that existed in the past.

Besides it could happen if a product has stock in 2 organizations and you allow negative stock. Example: one month ago you have:
Org A: 100 units
Org B: -100 units
You change the unit of measure to pallet.
Try to validate a costing rule for Org A. Error @DocUOMMismatch@ 60 when trying to process the closing inventory because the current product uom is different than the one that existed in the past.

Also it could happen creating an inventory amount update in the past with the same stock situation explained in the examples above.
Proposed SolutionUse a new column in the m_transaction in order not to take into account the unit of measure when you are creating closing and opening physical inventories.

Besides, it would be nice to review the trigger in the m_product in order to restrict properly the possibility to change the product's unit of measure by dimensions
TagsNo tags attached.
Attached Filespng file icon Issue 32012_A.png [^] (95,652 bytes) 2016-02-09 14:14


png file icon Issue_32012_B.png [^] (69,755 bytes) 2016-02-09 14:15

- Relationships Relation Graph ] Dependency Graph ]
related to defect 00317723.0PR16Q2 closedaferraz Performance problem when you try to validate the costing rule with high volume of data 
related to defect 00339683.0PR17Q1 closeddmiguelez Wrong costs calculated with Backdated Transactions 

-  Notes
(0084051)
psanjuan (manager)
2016-02-09 12:25
edited on: 2016-02-09 14:14

Test Plan run locally (before applying the fix):

- As system Admin, go to Initial Client Setup and create a new client "Nuevo Cliente 32012"
- As "Nuevo Cliente 32012 Admin" go to Initial Organization Setup and create a new organization "legal with accounting". Name "F&B Pamplona". Currency EUR. Choose an accounting file.
- Go to Fiscal Calendar window and create a new one for *, with 2015 and 2016 year and their corresponding periods.
- Go to Warehouse and Storage bins window and create a warehouse for the org. Location Spain.
- Go to Organization window, select the org just created, set allow period control= yes, select the calendar, enter EUR as currency. Set the org as Ready. Select the Warehouse and enter Spain location.
- Go to Open/Close periods and open all periods.
- Create a price list schema and a sales&purchase price list, valid from 01-01-2015
- Create BP Category: customer, vendor
- Create product category: product
- Create a financial Account: Bank Nueva Org 32012
- Create a Payment Method: Transferencia. Set this payment method in the Financial Account.
- Create a Payment Terms: 30 d.
- Create a tax category: VAT Normal
- Create two tax rates related to that tax category: Sale and Purchase Tax rate, at a 21% rate. No info in Country/Destination Country.
- Create a vendor and a customer in the Business Partner window. located in Spain.
- Create a product in the Product window, named "Product A", Unit of Measure = Unit. Select purchase / sales price list in Price tab, enter any prices.
- Go to Unit of Measure window and create a new one named: EDI code = NA, Name = Synthetic pallet 80*120cm. Costing Precision = 4. Save.
- Dated on 15-03-2015 receipt 120 units of the product.
- Dated on 30-03-2015 ship 100 units of the product.
- Launch Stock Report dated on 30-03-2015. Verify stock is 20 units
- Dated on 15-04-2015 ship 20 units of the product.
- Launch Stock Report dated on 16-04-2015. Verify stock it is empty.
- Change unit of measure of the product to NA. Save. It is possible to change because there is no stock.
- Dated on 15-05-2015 receipt 50 pallets.
- Dated on 30-05-2015 ship 10 pallets.
- Launch Stock Report dated on 30-05-2015. Verify stock is 40 pallets.
- Go to costing rule window and create a new one for the org with below data:
Costing Algorithm = Average Algorithm
Starting Date = 10-04-2015
Press Validate costing rule.

An error is shown: see image attached.

(0084055)
psanjuan (manager)
2016-02-09 14:28

Test Plan run locally (after applying the fix):

- Go to costing rule window and try to validate the one created above with below data:
Costing Algorithm = Average Algorithm
Starting Date = 10-04-2015
Press Validate costing rule.

Check that the costing rule can be validated and two inventories have been created:
Closing Inventory = Quantity Count = 0; UOM = Unit; Book Quantity = 20
Opening Inventory = Quantity count = 20 ; UOM = UNit; Book Quantity= 0

Issue can be code reviewed and closed.
(0084074)
hgbot (developer)
2016-02-10 10:14

Repository: erp/devel/pi
Changeset: d74b9acdfd3c888a84ca59fb87a53687b8eba501
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Thu Jan 28 11:52:33 2016 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/d74b9acdfd3c888a84ca59fb87a53687b8eba501 [^]

Fixes issue 32012:Error when validating a costing rule under some circumstances

Update M_TRANSACTION_TRG to avoid raise @DocUOMMismatch@ error in case transaction has been created from a opening or closing inventory.

---
M src-db/database/model/triggers/M_TRANSACTION_TRG.xml
---
(0084075)
dmiguelez (developer)
2016-02-10 10:15

Code Review + Testing Ok
(0085123)
hudsonbot (developer)
2016-03-17 10:56

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

- Issue History
Date Modified Username Field Change
2016-01-26 12:27 VictorVillar New Issue
2016-01-26 12:27 VictorVillar Assigned To => Triage Finance
2016-01-26 12:27 VictorVillar Modules => Core
2016-01-26 12:27 VictorVillar Resolution time => 1454972400
2016-01-26 12:27 VictorVillar Triggers an Emergency Pack => No
2016-01-26 12:27 VictorVillar Issue Monitored: networkb
2016-01-27 09:24 aferraz Status new => scheduled
2016-01-27 09:24 aferraz Assigned To Triage Finance => aferraz
2016-01-29 14:59 aferraz Relationship added related to 0031772
2016-02-09 12:25 psanjuan Note Added: 0084051
2016-02-09 12:29 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 12:38 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 12:41 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 12:45 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 12:49 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 12:53 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 12:57 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 13:02 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 13:02 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 13:06 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 13:10 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 14:11 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 14:12 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 14:12 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 14:14 psanjuan Note Edited: 0084051 View Revisions
2016-02-09 14:14 psanjuan File Added: Issue 32012_A.png
2016-02-09 14:15 psanjuan File Added: Issue_32012_B.png
2016-02-09 14:28 psanjuan Note Added: 0084055
2016-02-10 10:14 hgbot Checkin
2016-02-10 10:14 hgbot Note Added: 0084074
2016-02-10 10:14 hgbot Status scheduled => resolved
2016-02-10 10:14 hgbot Resolution open => fixed
2016-02-10 10:14 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/d74b9acdfd3c888a84ca59fb87a53687b8eba501 [^]
2016-02-10 10:15 dmiguelez Review Assigned To => dmiguelez
2016-02-10 10:15 dmiguelez Note Added: 0084075
2016-02-10 10:15 dmiguelez Status resolved => closed
2016-03-17 10:56 hudsonbot Checkin
2016-03-17 10:56 hudsonbot Note Added: 0085123
2016-07-20 11:36 aferraz Relationship added related to 0033411
2016-07-20 11:36 aferraz Fixed in Version => 3.0PR16Q2
2016-07-20 11:37 aferraz Relationship deleted related to 0033411
2016-09-16 13:40 aferraz Relationship added related to 0033411
2016-09-16 13:41 aferraz Relationship deleted related to 0033411
2016-09-16 13:42 aferraz Relationship added related to 0033968


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker