diff --git a/addons/sale_stock/i18n/sale_stock.pot b/addons/sale_stock/i18n/sale_stock.pot index db2bf052fb0..34ca26249f4 100644 --- a/addons/sale_stock/i18n/sale_stock.pot +++ b/addons/sale_stock/i18n/sale_stock.pot @@ -349,7 +349,7 @@ msgstr "" #. module: sale_stock #: code:addons/sale_stock/sale_stock.py:270 #, python-format -msgid "You selected a quantity of %d Units.\n" +msgid "You selected a quantity of %s %s.\n" "But it's not compatible with the selected packaging.\n" "Here is a proposition of quantities according to the packaging:\n" "EAN: %s Quantity: %s Type of ul: %s" diff --git a/addons/sale_stock/sale_stock.py b/addons/sale_stock/sale_stock.py index 4c943325f6a..00585a9abb3 100644 --- a/addons/sale_stock/sale_stock.py +++ b/addons/sale_stock/sale_stock.py @@ -260,11 +260,12 @@ class sale_order_line(osv.osv): qty_pack = pack.qty type_ul = pack.ul if not warning_msgs: - warn_msg = _("You selected a quantity of %d Units.\n" + uom_obj = product_uom_obj.browse(cr, uid, uom, context=context) + warn_msg = _("You selected a quantity of %s %s.\n" "But it's not compatible with the selected packaging.\n" "Here is a proposition of quantities according to the packaging:\n" "EAN: %s Quantity: %s Type of ul: %s") % \ - (qty, ean, qty_pack, type_ul.name) + (qty, uom_obj.name, ean, qty_pack, type_ul.name) warning_msgs += _("Picking Information ! : ") + warn_msg + "\n\n" warning = { 'title': _('Configuration Error!'),