diff options
| author | Christophe Simonis <chs@odoo.com> | 2016-09-28 16:28:31 +0200 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2016-09-28 16:28:31 +0200 |
| commit | a7ba6cde9c7951fa54cf031deb3bebc8d511bf95 (patch) | |
| tree | 89e2e1f62bc3973dde713099af357a33264256dd /addons/website/static/src/js/website.snippets.gallery.js | |
| parent | d04a42022b2338d529d245080fa506f72cdc8daa (diff) | |
| parent | 7134affc89c3ad04b365e64b49b911c8bc3f433e (diff) | |
[MERGE] forward port branch saas-12 up to 7134aff
Diffstat (limited to 'addons/website/static/src/js/website.snippets.gallery.js')
| -rw-r--r-- | addons/website/static/src/js/website.snippets.gallery.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/website/static/src/js/website.snippets.gallery.js b/addons/website/static/src/js/website.snippets.gallery.js index 481ba06e6f3..cde906ca764 100644 --- a/addons/website/static/src/js/website.snippets.gallery.js +++ b/addons/website/static/src/js/website.snippets.gallery.js @@ -67,7 +67,7 @@ options.registry.gallery = options.Class.extend({ }, bind_change: function () { var self = this; - return this.$target.find("img").off('saved').on('saved', function (event, img) { + return this.$target.find("img").off('save').on('save', function (event, img) { var $parent = $(img).parent(); $parent.addClass("saved_active"); var index = self.$target.find(".item.saved_active").index(); @@ -228,7 +228,7 @@ options.registry.gallery = options.Class.extend({ var $container = this.$target.find(".container:first"); var editor = new widget.MediaDialog(null, {select_images: true}, this.$target.closest('.o_editable'), null).open(); var index = Math.max(0, _.max(_.map(this.$target.find("img").get(), function (img) { return img.dataset.index | 0; })) + 1); - editor.on('saved', this, function (attachments) { + editor.on('save', this, function (attachments) { for (var i = 0 ; i < attachments.length; i++) { $('<img class="img img-responsive mb8 mt8"/>') .attr("src", attachments[i].src) |
