diff options
| author | Frederic van der Essen <fva@openerp.com / fvdessen+o@gmail.com> | 2014-08-25 16:42:57 +0200 |
|---|---|---|
| committer | Frederic van der Essen <fva@openerp.com / fvdessen+o@gmail.com> | 2014-08-25 16:42:57 +0200 |
| commit | d7f93defb899b2b48a14d679e5dffffdb4a00eff (patch) | |
| tree | f8572183b480477622917a1f504cf49a8e202f6e /addons/mass_mailing/static/src/js | |
| parent | 2b67528fe9e366829d44d8aba756bc6e359b4c61 (diff) | |
| parent | 36146b3fadc47543f4b696ab75c31b3459afb15b (diff) | |
Merge branch 'master' into master-pos-new-payment-screen-fva
Conflicts:
addons/point_of_sale/point_of_sale.py
addons/point_of_sale/point_of_sale_view.xml
Diffstat (limited to 'addons/mass_mailing/static/src/js')
| -rw-r--r-- | addons/mass_mailing/static/src/js/website_mass_mailing.editor.js | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/addons/mass_mailing/static/src/js/website_mass_mailing.editor.js b/addons/mass_mailing/static/src/js/website_mass_mailing.editor.js index 4caba1d29b5..0a460caaa81 100644 --- a/addons/mass_mailing/static/src/js/website_mass_mailing.editor.js +++ b/addons/mass_mailing/static/src/js/website_mass_mailing.editor.js @@ -5,8 +5,9 @@ var _t = openerp._t; website.snippet.options.mailing_list_subscribe = website.snippet.Option.extend({ - on_prompt: function () { + choose_mailing_list: function (type, value) { var self = this; + if (type !== "click") return; return website.prompt({ id: "editor_new_mailing_list_subscribe_button", window_title: _t("Add a Newsletter Subscribe Button"), @@ -22,15 +23,10 @@ drop_and_build_snippet: function() { var self = this; this._super(); - this.on_prompt().fail(function () { + this.choose_mailing_list('click').fail(function () { self.editor.on_remove(); }); }, - start : function () { - var self = this; - this.$el.find(".js_mailing_list").on("click", _.bind(this.on_prompt, this)); - this._super(); - }, clean_for_save: function () { this.$target.addClass("hidden"); }, |
