diff options
| author | qsm-odoo <qsm@odoo.com> | 2019-02-12 13:20:23 +0000 |
|---|---|---|
| committer | qsm-odoo <qsm@odoo.com> | 2019-02-26 17:09:23 +0000 |
| commit | d946b7a85d2c1bbc20ace8e2b269be56a63876fd (patch) | |
| tree | 00bf82d77d98719fe717ddde11463d21fed3507c /addons/website_mail_channel/static | |
| parent | 335a505d1f9b6a978c0fe0f6ea760a45b0d0a67f (diff) | |
[REF] website, *: use public widgets instead of website animations
* website_blog, website_crm_partner_assign, website_event,
website_event_track, website_form, website_forum, website_links,
website_mail, website_mail_channel, website_mass_mailing,
website_sale, website_sale_comparison, website_sale_delivery,
website_sale_stock, website_sale_wishlist, website_slides,
website_twitter
While using the 'Animation' class of website instead of the frontend
'Widget' class leads to the same behaviors, this refactoring is done for
two reasons:
- Stop using the confusing 'Animation' name for non-animated behaviors
- Instantiation of 'Widget' is slightly faster than 'Animation'
Part of https://github.com/odoo/odoo/pull/29442
task-1932066
Diffstat (limited to 'addons/website_mail_channel/static')
| -rw-r--r-- | addons/website_mail_channel/static/src/js/website_mail_channel.js | 4 | ||||
| -rw-r--r-- | addons/website_mail_channel/static/src/js/website_mail_channel.snippet.js | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/addons/website_mail_channel/static/src/js/website_mail_channel.js b/addons/website_mail_channel/static/src/js/website_mail_channel.js index b30f9c583e3..aab009898c8 100644 --- a/addons/website_mail_channel/static/src/js/website_mail_channel.js +++ b/addons/website_mail_channel/static/src/js/website_mail_channel.js @@ -1,9 +1,9 @@ odoo.define('website_mail_channel', function (require) { 'use strict'; -var sAnimations = require('website.content.snippets.animation'); +var publicWidget = require('web.public.widget'); -sAnimations.registry.websiteMailChannel = sAnimations.Class.extend({ +publicWidget.registry.websiteMailChannel = publicWidget.Widget.extend({ selector: '#wrapwrap', events: { 'click .o_mg_link_hide': '_onHideLinkClick', diff --git a/addons/website_mail_channel/static/src/js/website_mail_channel.snippet.js b/addons/website_mail_channel/static/src/js/website_mail_channel.snippet.js index 7ac4319a88b..cb9e32f62b2 100644 --- a/addons/website_mail_channel/static/src/js/website_mail_channel.snippet.js +++ b/addons/website_mail_channel/static/src/js/website_mail_channel.snippet.js @@ -1,9 +1,9 @@ odoo.define('website_mail_channel.snippet', function (require) { 'use strict'; -var sAnimation = require('website.content.snippets.animation'); +var publicWidget = require('web.public.widget'); -sAnimation.registry.follow_alias = sAnimation.Class.extend({ +publicWidget.registry.follow_alias = publicWidget.Widget.extend({ selector: ".js_follow_alias", disabledInEditableMode: false, start: function () { |
