Skip to content

Commit 5202829

Browse files
committed
TA#57380 [IMP] stock_picking_barcode
1 parent 17b53dc commit 5202829

File tree

3 files changed

+27
-9
lines changed

3 files changed

+27
-9
lines changed

stock_picking_barcode/I18n/fr.po

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ msgid ""
66
msgstr ""
77
"Project-Id-Version: Odoo Server 14.0\n"
88
"Report-Msgid-Bugs-To: \n"
9-
"POT-Creation-Date: 2024-06-04 19:54+0000\n"
10-
"PO-Revision-Date: 2024-06-04 19:54+0000\n"
9+
"POT-Creation-Date: 2024-06-06 16:33+0000\n"
10+
"PO-Revision-Date: 2024-06-06 16:33+0000\n"
1111
"Last-Translator: \n"
1212
"Language-Team: \n"
1313
"MIME-Version: 1.0\n"
@@ -59,6 +59,12 @@ msgstr "Type de préparation"
5959
msgid "Scan from this Operation Type"
6060
msgstr "Numériser depuis ce type d'opération"
6161

62+
#. module: stock_picking_barcode
63+
#: code:addons/stock_picking_barcode/models/stock_picking.py:0
64+
#, python-format
65+
msgid "The barcode \"%(barcode)s\" does not match any product on this picking."
66+
msgstr "Le code barre \"%(barcode)s\" ne correspond à aucun article sur ce transfert."
67+
6268
#. module: stock_picking_barcode
6369
#: code:addons/stock_picking_barcode/models/stock_picking.py:0
6470
#, python-format
@@ -71,7 +77,8 @@ msgid ""
7177
"This field allows you to choose the Barcodes Nomenclature\n"
7278
" to apply when scanning."
7379
msgstr ""
74-
"Ce champ vous permet de choisir la nomenclature des code-barres à appliquer lors de la numérisation."
80+
"Ce champ vous permet de choisir la nomenclature des code-barres à appliquer "
81+
"lors de la numérisation."
7582

7683
#. module: stock_picking_barcode
7784
#: model:ir.model,name:stock_picking_barcode.model_stock_picking
@@ -89,11 +96,13 @@ msgid ""
8996
"When this box is checked, a new “Scan” field is displayed on\n"
9097
" transfers of this type of operation to allow scanning of a barcode."
9198
msgstr ""
92-
"Lorsque cette case est cochée, un nouveau champ “Code-barres numérisé” est affiché sur"
93-
" les transferts de ce type d’opération afin de permettre de numériser un code-barres."
99+
"Lorsque cette case est cochée, un nouveau champ “Code-barres numérisé” est "
100+
"affiché sur les transferts de ce type d’opération afin de permettre"
101+
" de numériser un code-barres."
94102

95103
#. module: stock_picking_barcode
96104
#: code:addons/stock_picking_barcode/models/stock_picking.py:0
105+
#: code:addons/stock_picking_barcode/models/stock_picking.py:0
97106
#, python-format
98107
msgid "Wrong barcode"
99-
msgstr "Mauvais code-barres."
108+
msgstr "Mauvais code-barres."

stock_picking_barcode/data/picking_barcodes_data.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<odoo noupdate="1">
33
<record id="picking_barcode_nomenclature" model="barcode.nomenclature">
4-
<field name="name">Operations/ Detailed Operations</field>
4+
<field name="name">Operations / Detailed Operations</field>
55
</record>
66

77
<record id="barcode_rule_picking_product_weight" model="barcode.rule">

stock_picking_barcode/models/stock_picking.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,7 @@ def on_barcode_scanned(self, barcode):
3333
limit=1,
3434
)
3535
if product:
36-
if self._check_product(product, qty):
37-
return
36+
self._check_product(product, qty)
3837
return {
3938
"warning": {
4039
"title": _("Wrong barcode"),
@@ -63,4 +62,14 @@ def _check_product(self, product, qty=1.0):
6362
)[:1]
6463
if corresponding_ml:
6564
corresponding_ml.qty_done += qty
65+
else:
66+
return {
67+
"warning": {
68+
"title": _("Wrong barcode"),
69+
"message": _(
70+
'The barcode "%(barcode)s" does not match any product on this picking.'
71+
)
72+
% {"barcode": barcode},
73+
}
74+
}
6675
return True

0 commit comments

Comments
 (0)