From 68ff3ed164c4b9716ef17982addee6a5ff0d550f Mon Sep 17 00:00:00 2001 From: "Anand Patel (OpenERP)" Date: Thu, 31 Jan 2013 19:01:35 +0530 Subject: [PATCH] [IMP]removed the 'DO you really want to remove these record?'for many2many and add 'Are you Sure?' for normal list bzr revid: pan@tinyerp.com-20130131133135-t36zbgo3rhylhmy4 --- addons/web/static/src/js/view_list.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_list.js b/addons/web/static/src/js/view_list.js index fbbfabcacca..2ff9b9eb35a 100644 --- a/addons/web/static/src/js/view_list.js +++ b/addons/web/static/src/js/view_list.js @@ -587,8 +587,10 @@ instance.web.ListView = instance.web.View.extend( /** @lends instance.web.ListVi * @param {Array} ids the ids of the records to delete */ do_delete: function (ids) { - if (!(ids.length && confirm(_t("Do you really want to remove these records?")))) { - return; + if (!this.m2m_field){ + if (!(ids.length && confirm(_t("Are you sure?"))) && (this.m2m_field)) { + return; + } } var self = this; return $.when(this.dataset.unlink(ids)).done(function () {