From f76e7b4f1909df0dc2190f97d3c034e87c283cee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A9ry=20Debongnie?= Date: Mon, 27 Oct 2014 10:19:07 +0100 Subject: [IMP] add warning when removing non global favorite --- addons/web/static/src/js/search.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'addons/web/static/src/js') diff --git a/addons/web/static/src/js/search.js b/addons/web/static/src/js/search.js index 8c495fe7480..366cae1f829 100644 --- a/addons/web/static/src/js/search.js +++ b/addons/web/static/src/js/search.js @@ -1768,8 +1768,9 @@ instance.web.search.FavoriteMenu = instance.web.Widget.extend({ }, remove_filter: function (filter, $filter, key) { var self = this; - var warning = _t("This filter is global and will be removed for everybody if you continue."); - if (!(filter.user_id || confirm(warning))) { + var global_warning = _t("This filter is global and will be removed for everybody if you continue."), + warning = _t("Are you sure that you want to remove this filter?"); + if (!confirm(filter.user_id ? warning : global_warning)) { return; } this.model.call('unlink', [filter.id]).done(function () { -- cgit v1.2.3