[FIX] purchase, fifo_price.yml: negative quants created at the same second don't mess the order anymore since propagated_from_id has a higher priority than id
bzr revid: qdp-launchpad@openerp.com-20130917141346-dzyzau2czh0uw0sr
This commit is contained in:
parent
e04b82d240
commit
3561076595
|
@ -379,8 +379,8 @@ class stock_quant(osv.osv):
|
|||
domain += [('product_id','=',product.id)] + domain
|
||||
res = []
|
||||
offset = 0
|
||||
#id is added at the end of the order to make sure the order is always the same for quants created at the same second
|
||||
orderby += ', id asc'
|
||||
#'propagated_from_id' and 'id' are added at the end of the order to make sure the order is always the same for quants created at the same second
|
||||
orderby += ', propagated_from_id, id'
|
||||
while quantity > 0:
|
||||
quants = self.search(cr, uid, domain, order=orderby, limit=10, offset=offset, context=context)
|
||||
if not quants:
|
||||
|
|
Loading…
Reference in New Issue