Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0012492Openbravo ERP04. Warehouse managementpublic2010-02-26 17:502010-03-12 22:40
networkb 
adrianromero 
immediatemajoralways
closedfixed 
5
2.50MP11 
2.50MP142.50MP14 
Core
No
0012492: m_get_product_cost error
when there are 2 costs defined and ending_date of one is identical to beginning_date of the other one, m_get_product_cost takes the first one instead of the second one
1. Procurement Management || Transactions || Goods Receipt || Header : create goods receipt with
date=01-03-2006
business partner = mcgiver
product=hammer
qty=1
complete
2. Procurement Management || Transactions || Purchase Invoice || Header :
date=01-03-2006
business partner = mcgiver
create lines from the receipt
complete
3. run generate average costs
4. Master Data Management || Product || Product >> Costing : edit the first cost of hammer product to 6.35
5. Warehouse Management || Analysis Tools || Valued Stock Report || Valued Stock Report : execute report for 01-03-2006 and Main warehouse

Realize that cost obtained is 6.35 instead of 4.50
No tags attached.
has duplicate defect 00124632.50MP17 closed adrianromero Issue 4370: Valued Stock Report doesn't include changes made on the selected date 
Issue History
2010-02-26 17:50networkbNew Issue
2010-02-26 17:50networkbAssigned To => adrianromero
2010-02-26 17:51networkbAssigned Toadrianromero => dalsasua
2010-03-01 12:20adrianromeroRelationship addedhas duplicate 0012463
2010-03-01 12:21adrianromeroAssigned Todalsasua => adrianromero
2010-03-01 12:21adrianromeroStatusnew => scheduled
2010-03-01 14:31hgbotCheckin
2010-03-01 14:31hgbotNote Added: 0024906
2010-03-01 14:31hgbotStatusscheduled => resolved
2010-03-01 14:31hgbotResolutionopen => fixed
2010-03-01 14:31hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/67ff744003242ddb903cf3db313b4453b75c24cf [^]
2010-03-01 14:48adrianromeroNote Added: 0024909
2010-03-03 07:33sureshbabuNote Added: 0024977
2010-03-03 15:52networkbNote Added: 0025011
2010-03-08 07:53arunkumarNote Added: 0025105
2010-03-08 07:53arunkumarStatusresolved => closed
2010-03-08 07:53arunkumarFixed in Version => 2.50MP13
2010-03-08 16:04jpabloaeFixed in Version2.50MP13 => 2.50MP14
2010-03-08 16:05jpabloaeTarget Version2.50MP13 => 2.50MP14
2010-03-10 17:25anonymoussf_bug_id0 =>
2010-03-10 18:30anonymoussf_bug_id => 2968113
2010-03-12 22:40hudsonbotCheckin
2010-03-12 22:40hudsonbotNote Added: 0025366

Notes
(0024906)
hgbot   
2010-03-01 14:31   
Repository: erp/devel/pi
Changeset: 67ff744003242ddb903cf3db313b4453b75c24cf
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Mon Mar 01 14:34:31 2010 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/67ff744003242ddb903cf3db313b4453b75c24cf [^]

Fixes issue 0012492: m_get_product_cost error

---
M src-db/database/model/functions/M_GET_PRODUCT_COST.xml
---
(0024909)
adrianromero   
2010-03-01 14:48   
To test the issue just follow the "Steps to reproduce" and notice that now the cost for hammer is 4.50 instead of 6.35
(0024977)
sureshbabu   
2010-03-03 07:33   
@ Adrian, i have followed the same steps provided above, but i am finding 6.35 as price for hammer in valued stock report
(0025011)
networkb   
2010-03-03 15:52   
In Step5 the correct date to execute the report is 31/03/2006 (instead of 01/03/2006)

Sorry for inconveniences.
(0025105)
arunkumar   
2010-03-08 07:53   
Now the cost for hammer is 4.50 in valued stock report by executing the report date is 31/03/2006

Tested & Working fine
(0025366)
hudsonbot   
2010-03-12 22:40   
A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/67ff74400324 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/631c626866c1 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.16685.obx [^]