[FIX] stock: UoS quantity in stock.picking
authorMohammad Alhashash <alhashash@alhashash.net>
Tue, 21 Oct 2014 19:12:58 +0000 (21:12 +0200)
committerMartin Trigaux <mat@odoo.com>
Wed, 29 Oct 2014 09:10:50 +0000 (10:10 +0100)
commit43db7267c5051c9ad4877c27ce1220d446d7552d
treedb316f106f576f0aec8c923cc2b0cb91b886cd8c
parentf4870f84182eb7a062f11e37e31827009d237cbb
[FIX] stock: UoS quantity in stock.picking

Implements the UoS TODO items on stock.picking.do_partial() to fix #1432.
Add a new method _compute_uos_qty() on product.product to computes
product's invoicing quantity in UoS from quantity in UoM.

The created invoice will use the product_uos of the stock.move, meaning keeping
the quantity specified on the partial picking and the unit of measure of the
original stock.move (e.g. recieving 1 dozen from a 12 unit picking should either
get uos=dozen, uos_qty=1 or uos=unit, uos_qty=12, not a mix of both)

Fixes #1432, opw 611479
addons/product/product.py
addons/stock/stock.py