Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0037334Openbravo ERP04. Warehouse managementpublic2017-11-20 18:352017-11-30 18:41
ngarcia 
nonofrancisco 
urgentmajoralways
closedfixed 
5
 
3.0PR18Q1 
dmiguelez
OBPS
Core
No
0037334: If same product is consumed and produced in same Bill Of Materials Production, produced transaction cost is calculated first
If same product is consumed and produced in same Bill Of Materials Production, produced transaction cost is calculated first if the production plan in which it is consumed produces more quantity than the production plan in which it is produced
As group admin role:
   Create a product BOM1
   Set it as Bill Of Materials
   Add Cerveza Ale to it in Bill Of Materials tab and Verify BOM

   Create a new product BOM2
   Set it as Bill Of Materials
   Add 0.5 units of BOM1 and Verify BOM

   Create a BOM Production
   Add two Product Plans:
      - First to produce 1 unit of BOM1
      - Second to produce 2 units of BOM2

   Create Production

   Add -1 unit of BOM1 product in second production plan (It was not automatically added because there is not stock)

   Process Production

   Launch Costing Background Process and check the transaction related with consumed BOM1 is calculated before the transaction related with produced BOM1
  
   In Product - Costing tab, Total Movement Quantity and Total Stock Valuation are taken into account the negative transaction when calculating the cost of the positive transaction that happened before
No tags attached.
? BOMProduction.fix (4,299) 2017-11-21 18:41
https://issues.openbravo.com/file_download.php?file_id=11311&type=bug
Issue History
2017-11-20 18:35ngarciaNew Issue
2017-11-20 18:35ngarciaAssigned To => Triage Finance
2017-11-20 18:35ngarciaOBNetwork customer => Yes
2017-11-20 18:35ngarciaModules => Core
2017-11-20 18:35ngarciaResolution time => 1512946800
2017-11-20 18:35ngarciaTriggers an Emergency Pack => No
2017-11-20 18:36ngarciaIssue Monitored: networkb
2017-11-21 09:42vmromanosAssigned ToTriage Finance => nonofrancisco
2017-11-21 18:41ngarciaFile Added: BOMProduction.fix
2017-11-23 15:33nonofranciscoStatusnew => scheduled
2017-11-24 15:00nonofranciscoNote Added: 0100707
2017-11-30 18:35dmiguelezNote Added: 0100843
2017-11-30 18:40dmiguelezNote Added: 0100847
2017-11-30 18:40dmiguelezStatusscheduled => resolved
2017-11-30 18:40dmiguelezFixed in SCM revision => https://code.openbravo.com/erp/devel/pi/rev/e5b78d273dd8 [^]
2017-11-30 18:40dmiguelezResolutionopen => fixed
2017-11-30 18:41dmiguelezNote Added: 0100848
2017-11-30 18:41dmiguelezReview Assigned To => dmiguelez
2017-11-30 18:41dmiguelezNote Added: 0100849
2017-11-30 18:41dmiguelezStatusresolved => closed
2017-11-30 18:41dmiguelezFixed in Version => 3.0PR18Q1

Notes
(0100707)
nonofrancisco   
2017-11-24 15:00   
As group admin role:
* Create a product BOM1
  Set it as Bill Of Materials
  Add 1 unit Cerveza Ale to it in Bill Of Materials tab and Verify BOM

* Create a new product BOM2
  Set it as Bill Of Materials
  Add 0.5 units of BOM1 and Verify BOM

* Create a BOM Production
  Add two Product Plans:
   - First to produce 1 unit of BOM1
   - Second to produce 2 units of BOM2

* Create Production

* Add -1 unit of BOM1 product in second production plan (It was not automatically added because there is not stock)

* Process Production

* Launch Costing Background Process

* Select Costing tab of product BOM1 and verify:
  Cost: 1.36 (same as Cerveza Ale)
  Quantity: 1
  Total Stock Valuation: 1.36

* Select Costing tab of product BOM2 and verify
  Cost: 0.68
  Quantity: 2
  Total Stock Valuation: 1.36
(0100843)
dmiguelez   
2017-11-30 18:35   
As group admin role:
* Create a product BOM1
  Set it as Bill Of Materials
  Add 1 unit Cerveza Ale to it in Bill Of Materials tab and Verify BOM

* Create a new product BOM2
  Set it as Bill Of Materials
  Add 0.5 units of BOM1 and Verify BOM

* Create a new product BOM3
  Set it as Bill Of Materials
  Add 0.25 units of BOM2 and Verify BOM

* Create a BOM Production
  Add three Product Plans:
   - First to produce 1 unit of BOM1
   - Second to produce 2 units of BOM2
   - Third to produce 4 units of BOM3

* Create Production

* Add -1 unit of BOM1 product in second production plan (It was not automatically added because there is not stock)
* Add -1 unit of BOM2 product in third production plan (It was not automatically added because there is not stock)

* Process Production

* Launch Costing Background Process

* Select Costing tab of product BOM1 and verify:
  Cost: 1.36 (same as Cerveza Ale)
  Quantity: 1
  Total Stock Valuation: 1.36

* Select Costing tab of product BOM2 and verify
  Cost: 0.68
  Quantity: 2
  Total Stock Valuation: 1.36

* Select Costing tab of product BOM2 and verify
  Cost: 0.17
  Quantity: 4
  Total Stock Valuation: 0.68
(0100847)
dmiguelez   
2017-11-30 18:40   
Wrong commit message did not link issue
(0100848)
dmiguelez   
2017-11-30 18:41   
Fixed by commit: https://code.openbravo.com/erp/devel/pi/rev/e5b78d273dd8 [^]
Code Review Commit: https://code.openbravo.com/erp/devel/pi/rev/1fde3c15b1a6 [^]
(0100849)
dmiguelez   
2017-11-30 18:41   
Code Review + changes Ok