Amit Parik (OpenERP) has proposed merging
lp:~openerp-dev/openobject-addons/trunk-bug-938787-amp into
lp:openobject-addons.
Requested reviews:
qdp (OpenERP) (qdp)
Related bugs:
Bug #938787 in OpenERP Addons: "[Trunk, 6.1]Partial picking changes UoS
quantity without converting to UoS"
https://bugs.launchpad.net/openobject-addons/+bug/938787
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-938787-amp/+merge/98335
--
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-938787-amp/+merge/98335
Your team OpenERP R&D Team is subscribed to branch
lp:~openerp-dev/openobject-addons/trunk-bug-938787-amp.
=== modified file 'stock/stock.py'
--- stock/stock.py 2012-02-28 14:08:16 +0000
+++ stock/stock.py 2012-03-20 04:38:19 +0000
@@ -1251,6 +1251,7 @@
for move in too_few:
+ uom_uos_diff = move.product_qty / move.product_uos_qty
product_qty = move_product_qty[move.id]
if not new_picking:
new_picking = self.copy(cr, uid, pick.id,
@@ -1262,7 +1263,7 @@
if product_qty != 0:
defaults = {
'product_qty' : product_qty,
- 'product_uos_qty': product_qty, #TODO: put correct uos_qty
+ 'product_uos_qty': product_qty / uom_uos_diff, #TODO: put correct uos_qty
'picking_id' : new_picking,
'state': 'assigned',
'move_dest_id': False,
@@ -1276,7 +1277,7 @@
move_obj.write(cr, uid, [move.id],
{
'product_qty' : move.product_qty - partial_qty[move.id],
- 'product_uos_qty': move.product_qty - partial_qty[move.id], #TODO: put correct uos_qty
+ 'product_uos_qty': move.product_qty - partial_qty[move.id] / uom_uos_diff, #TODO: put correct uos_qty
})
_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help : https://help.launchpad.net/ListHelp