From adb484a1b5004e36d63fca5236de72b5c1cf064b Mon Sep 17 00:00:00 2001 From: Yannick Tivisse Date: Fri, 27 Jan 2017 14:49:14 +0100 Subject: [PATCH] [IMP] web: add a 'close' terminology on FieldBooleanButton widget This will be used on a sale_coupon_program --- addons/web/static/src/js/views/form_widgets.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/addons/web/static/src/js/views/form_widgets.js b/addons/web/static/src/js/views/form_widgets.js index c445e3d6d31..e76da1eec30 100644 --- a/addons/web/static/src/js/views/form_widgets.js +++ b/addons/web/static/src/js/views/form_widgets.js @@ -697,6 +697,12 @@ var FieldBooleanButton = common.AbstractField.extend({ this.string_false = _t("Archived"); this.hover_false = _t("Restore"); break; + case "close": + this.string_true = _t("Active"); + this.string_false = _t("Closed"); + this.hover_true = _t("Close"); + this.hover_false = _t("Open"); + break; default: var terms = typeof this.options["terminology"] === 'string' ? {} : this.options["terminology"]; this.string_true = _t(terms.string_true || "On");