Comment 38 for bug 610738

Revision history for this message
Josse Colpaert (OpenERP) (jco-openerp) wrote :

I wanted to tell you that we are taking this seriously and are about to clean this up. Kevin, maybe I overlooked, but if you have a branch it would be interesting to have a look at least.

I see the average price is now updated like this (only for picking in): new_std_price = ((amount_unit * product_avail[product.id]) + (new_price * qty))/(product_avail[product.id] + qty)

So when returning products, you use a negative quantity (qty) and a new_price = price of original in move (of purchase order/supplier invoice)?