From a0cf136818f4b4728f5509a43229c54c767f79b4 Mon Sep 17 00:00:00 2001 From: Yenthe666 Date: Wed, 22 Jan 2020 07:57:42 +0000 Subject: [PATCH] [FIX] stock: fix typos in UserErrors Two of the UserErrors mentioned 'quantites' instead of 'quantities' before this commit. This commit fixes the terms and the translation file. closes odoo/odoo#43902 X-original-commit: 68a849bfb507c5fa14b869a44ea50bf88ff3ce1f Signed-off-by: Martin Trigaux (mat) --- addons/stock/i18n/stock.pot | 4 ++-- addons/stock/models/stock_picking.py | 4 ++-- addons/stock/tests/test_move.py | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/stock/i18n/stock.pot b/addons/stock/i18n/stock.pot index f7c7eaed4d1..0de2e4af173 100644 --- a/addons/stock/i18n/stock.pot +++ b/addons/stock/i18n/stock.pot @@ -39,7 +39,7 @@ msgstr "" msgid "" "\n" "\n" -"Transfers %s: You cannot validate these transfers if no quantites are reserved nor done. To force these transfers, switch in edit more and encode the done quantities." +"Transfers %s: You cannot validate these transfers if no quantities are reserved nor done. To force these transfers, switch in edit more and encode the done quantities." msgstr "" #. module: stock @@ -7076,7 +7076,7 @@ msgstr "" #: code:addons/stock/models/stock_picking.py:0 #, python-format msgid "" -"You cannot validate a transfer if no quantites are reserved nor done. To " +"You cannot validate a transfer if no quantities are reserved nor done. To " "force the transfer, switch in edit mode and encode the done quantities." msgstr "" diff --git a/addons/stock/models/stock_picking.py b/addons/stock/models/stock_picking.py index 3885dc5874b..fc6a3779da4 100644 --- a/addons/stock/models/stock_picking.py +++ b/addons/stock/models/stock_picking.py @@ -836,7 +836,7 @@ class Picking(models.Model): if pickings_without_moves: raise UserError(_('Please add some items to move.')) if pickings_without_quantities: - raise UserError(_('You cannot validate a transfer if no quantites are reserved nor done. To force the transfer, switch in edit mode and encode the done quantities.')) + raise UserError(_('You cannot validate a transfer if no quantities are reserved nor done. To force the transfer, switch in edit mode and encode the done quantities.')) if pickings_without_lots: raise UserError(_('You need to supply a Lot/Serial number for products %s.') % ', '.join(products_without_lots.mapped('display_name'))) else: @@ -844,7 +844,7 @@ class Picking(models.Model): if pickings_without_moves: message += _('Transfers %s: Please add some items to move.') % ', '.join(pickings_without_moves.mapped('name')) if pickings_without_quantities: - message += _('\n\nTransfers %s: You cannot validate these transfers if no quantites are reserved nor done. To force these transfers, switch in edit more and encode the done quantities.') % ', '.join(pickings_without_quantities.mapped('name')) + message += _('\n\nTransfers %s: You cannot validate these transfers if no quantities are reserved nor done. To force these transfers, switch in edit more and encode the done quantities.') % ', '.join(pickings_without_quantities.mapped('name')) if pickings_without_lots: message += _('\n\nTransfers %s: You need to supply a Lot/Serial number for products %s.') % (', '.join(pickings_without_lots.mapped('name')), ', '.join(products_without_lots.mapped('display_name'))) if message: diff --git a/addons/stock/tests/test_move.py b/addons/stock/tests/test_move.py index a1351d944af..238b4a388d6 100644 --- a/addons/stock/tests/test_move.py +++ b/addons/stock/tests/test_move.py @@ -3443,7 +3443,7 @@ class StockMove(SavepointCase): }) picking.action_confirm() picking.action_assign() - # No quantites filled, immediate transfer wizard should pop up. + # No quantities filled, immediate transfer wizard should pop up. immediate_trans_wiz_dict = picking.button_validate() self.assertEqual(immediate_trans_wiz_dict.get('res_model'), 'stock.immediate.transfer') immediate_trans_wiz = Form(self.env[immediate_trans_wiz_dict['res_model']].with_context(immediate_trans_wiz_dict['context'])).save()