Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0036005Openbravo ERP04. Warehouse managementpublic2017-05-16 11:362017-06-08 17:12
ngarcia 
collazoandy4 
urgentmajoralways
closedfixed 
5
 
3.0PR17Q3 
aferraz
Core
No
0036005: Wrong cost for produced product in a work effort if the consumed product has duplicated cost entry
Wrong cost for produced product in a work effort if the consumed product has duplicated cost entry.

Duplicated costs can be obtained manually but also when a product do not set as production is received in two warehouses and the costing rule is configured with WH dimension and the product is then consumed in a work effort
As group admin role:
   Create two products, set them as production
   Set the storage bin in the Manufacturing tab to the produced one
   Add two manual costs to the consumed one:
      Starting Date: today
      Ending Date: 31-12-9999
   Increase the stock of the consumed one
   Create a Manufacturing Cost Center and Version
   Create an Activity associated to it
   Create a Process Plan, Version and Operation
   Assign the previously created activity to it
   Add the previously created products to it: one as P+ and the other one as P-
   Create a Work Requirement from the Process Plan
   Create a Work Effort from the Work Requirement
   Validate it
   Launch the Costing Background Process
   Check the two costs of the consumed product were taken into account for calculating the cost of the produced one
No tags attached.
related to defect 0036008 closed collazoandy4 It is possible to add not production products in work efforts 
Issue History
2017-05-16 11:36ngarciaNew Issue
2017-05-16 11:36ngarciaAssigned To => Triage Finance
2017-05-16 11:36ngarciaModules => Core
2017-05-16 11:36ngarciaResolution time => 1496700000
2017-05-16 11:36ngarciaTriggers an Emergency Pack => No
2017-05-16 11:36ngarciaIssue Monitored: networkb
2017-05-16 13:02ngarciaRelationship addedrelated to 0036008
2017-05-17 13:36aferrazAssigned ToTriage Finance => collazoandy4
2017-05-26 00:05collazoandy4Statusnew => scheduled
2017-06-03 02:15collazoandy4Note Added: 0097117
2017-06-05 18:34hgbotCheckin
2017-06-05 18:34hgbotNote Added: 0097143
2017-06-05 18:34hgbotStatusscheduled => resolved
2017-06-05 18:34hgbotResolutionopen => fixed
2017-06-05 18:34hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/042fe61f85f7f180dc2967a5554cb22a1dbcd2b0 [^]
2017-06-05 18:35aferrazReview Assigned To => aferraz
2017-06-05 18:35aferrazNote Added: 0097146
2017-06-05 18:35aferrazStatusresolved => closed
2017-06-05 18:35aferrazFixed in Version => 3.0PR17Q3
2017-06-08 17:12hudsonbotCheckin
2017-06-08 17:12hudsonbotNote Added: 0097242

Notes
(0097117)
collazoandy4   
2017-06-03 02:15   
Test Plan
 Go to Product window and create a new record:
   Search Key/Name: Consume
   Check Production field
   Create a new record in Costing tab:
     Cost Type: Standard
     Cost: 10
     Manual: Y
     Starting Date: 01-05-2017
     Ending Date: 01-05-2099
    Create a new record in Costing tab:
     Cost Type: Average
     Cost: 20
     Manual: Y
     Starting Date: 01-05-2017
     Ending Date: 01-05-2099
    Create a new record in Costing tab:
     Cost Type: Average
     Cost: 30
     Manual: Y
     Starting Date: 01-05-2017
     Ending Date: 01-05-2099
  In Product window create a new record:
    Search Key/Name: Produced
    Check Production field
    Create a new record in Manufacturing tab:
      Storage Bin: Rn-0-0-0
  Go to Physical Inventory and create a new record:
    Movement Date: Today
    Create a new record in Lines tab:
      Product: Consume
      Quantity count: 500
    Process inventory count
  Go to Manufacturing Cost Center and create a new record:
    Search Key/Name: Issue Cost Center
    Create a new record in Version tab:
      Valid From Date: Today
  Go to Activity window and create a new record:
    Search Key/Name: Issue Activity
    Cost Center: Issue Cost Center
  Go to Process Plan window and create a new record:
    Search Key/Name: Issue Plan
    Create a new record in Version Tab:
      Starting Date: 01-05-2017
      Ending Date: 01-05-2099
      Create a new record in Operation tab:
        Search Key/Name: Issue Operation
        Activity: Issue Activity
        Create a new record in I/O Products tab:
          Product: Consume
          Production Type: Product use (P-)
          Quantity: 5
        Create a new record in I/O Products tab:
          Product: Produced
          Production Type: Product Production (P+)
          Quantity: 1
  Go to Work Requirement window and create a new record:
      Process Plan: Issue Plan
      Starting Date: 01-05-2017
    Ending Date: 01-05-2099
    Quantity: 50
    Process the requirement
    Clic on Create a Work Effort button
      Date: Today
  Go to Production Run window and edit the previous production created:
    Completed Quantity: 1
    Clic on Create Standard button
  Go to Work Effort window and validate the previous one created
  Launch the Costing Background Process and check that the min consume product cost was used for the produced product cost
(0097143)
hgbot   
2017-06-05 18:34   
Repository: erp/devel/pi
Changeset: 042fe61f85f7f180dc2967a5554cb22a1dbcd2b0
Author: Armaignac <collazoandy4 <at> gmail.com>
Date: Fri Jun 02 17:55:47 2017 -0400
URL: http://code.openbravo.com/erp/devel/pi/rev/042fe61f85f7f180dc2967a5554cb22a1dbcd2b0 [^]

Fixes issue 36005: Wrong cost for produced product in a work effort

When exist a consume product with duplicated cost entry both cost was used to calculate the cost of the produced product.

Now to compute the cost of the produced product will only take the min cost of the consume product.

---
M src-db/database/model/functions/MA_PRODUCTION_COST.xml
---
(0097146)
aferraz   
2017-06-05 18:35   
Code review + Testing OK
(0097242)
hudsonbot   
2017-06-08 17:12   
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/fda0f16ab470 [^]
Maturity status: Test