From 17984be82c4eed22b18b66a0e8b0b5ab534f3bcd Mon Sep 17 00:00:00 2001 From: Simon Lejeune Date: Fri, 8 Jun 2018 16:31:16 +0200 Subject: [PATCH] [REF] barcodes: form view: better error messages --- addons/barcodes/static/src/js/barcode_form_view.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/barcodes/static/src/js/barcode_form_view.js b/addons/barcodes/static/src/js/barcode_form_view.js index 525d0b84ebd..15e27498f94 100644 --- a/addons/barcodes/static/src/js/barcode_form_view.js +++ b/addons/barcodes/static/src/js/barcode_form_view.js @@ -60,7 +60,7 @@ FormController.include({ */ _barcodeAddX2MQuantity: function (barcode, activeBarcode) { if (this.mode === 'readonly') { - this.do_warn(_t('Error : Document not editable'), + this.do_warn(_t('Error: Document not editable'), _t('To modify this document, please first start edition.')); return new $.Deferred().reject(); } @@ -323,7 +323,7 @@ FormController.include({ } } if (prefixed && !hasCommand) { - self.do_warn(_t('Error : Barcode command is undefined'), barcode); + self.do_warn(_t('Error: Barcode command is undefined'), barcode); } return self.alive($.when.apply($, defs)).then(function () { if (!prefixed) { @@ -359,7 +359,7 @@ FormController.include({ } if (!_.compact(_.pluck(barcodeInfos, 'candidate')).length) { - return this.do_warn(_t('Error : No last scanned barcode'), + return this.do_warn(_t('Error: No last scanned barcode'), _t('To set the quantity please scan a barcode first.')); }