Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0019860Openbravo ERP04. Warehouse managementpublic2012-01-31 18:012012-03-29 17:12
maite 
jecharri 
urgentmajoralways
closedfixed 
5
 
2.50MP41 
Core
No
0019860: Generate Average cost process is not raising "unposting" error if all costing lines are set as "permanent"
Generate Average cost process is not raising "unposting" error if all costing lines are set as "permanent", although document needs to be unposted as cost is going to change after running process
1. Set all costing lines of all products as "permanent"
2. Create Purchase Order for "Zumo de Pera Bio 0,33L" product for tomorrow's date at price=50euros. Process.
3. Create associated goods receipt and Post it. Verify that it has been posted using already existent cost for product.
4.Run Generate Average cost process and realize that new Costing entry for product has been inserted and cost is now different.

Generate average cost process should have raised error to Unpost receipt before run process, as receipt should be posted using new cost, not old one
Variable "v_MinDateCosting" is calculated taken into account all costing lines with "permanent"=N. In case all costing lines are checked as "Permanent", receipt's date should be considered. In that case, minimum date between v_MinDateCosting and receipt's date should be used to raise unposting errors
No tags attached.
blocks defect 00196063.0MP9 closed jecharri Generate Average cost process is not raising "unposting" error if all costing lines are set as "permanent" 
Issue History
2012-02-24 09:07jecharriTypedefect => backport
2012-02-24 09:07jecharrifix_in_branch => 2.50
2012-02-24 09:08jecharriTarget Version3.0MP9 => 2.50MP41
2012-03-28 13:34hgbotCheckin
2012-03-28 13:34hgbotNote Added: 0046832
2012-03-28 13:34hgbotStatusscheduled => resolved
2012-03-28 13:34hgbotResolutionopen => fixed
2012-03-28 13:34hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/devel/pi/rev/91dacdd3f33dffa8e3afe1acfb075c0c38b51d0b [^] => http://code.openbravo.com/erp/stable/2.50/rev/c3fbfefd94e85fa18b2a467dcf4880eb62c4e728 [^]
2012-03-29 17:12maiteNote Added: 0046921
2012-03-29 17:12maiteStatusresolved => closed

Notes
(0046832)
hgbot   
2012-03-28 13:34   
Repository: erp/stable/2.50
Changeset: c3fbfefd94e85fa18b2a467dcf4880eb62c4e728
Author: Javier Etxarri <javier.echarri <at> openbravo.com>
Date: Wed Mar 28 13:34:04 2012 +0200
URL: http://code.openbravo.com/erp/stable/2.50/rev/c3fbfefd94e85fa18b2a467dcf4880eb62c4e728 [^]

Fixes issue 19861, Fixes issue 19860:
Generate Average Cost process should take into account goods receipts of same day checked as "permanent" and
Generate Average cost process is not raising unposting error if all costing lines are set as "permanent".
To solve the first problem I have added the permanets quantitites of the day first and to solve the second problem, now I take the min date from M_INOUT

---
M src-db/database/model/functions/M_GENERATE_AVERAGE_COSTS.xml
---
(0046921)
maite   
2012-03-29 17:12   
verified