summaryrefslogtreecommitdiff
path: root/addons/website_livechat/static/src/js/website_livechat.editor.js
diff options
context:
space:
mode:
authorqsm-odoo <qsm@odoo.com>2018-09-28 14:50:18 +0200
committerqsm-odoo <qsm@odoo.com>2018-09-30 19:55:17 +0200
commit55131b8f5becdd3d4776f4c3e7e4288a0b185706 (patch)
tree4eca54d0cd14a2180227ad2b155e3380d37fb9a6 /addons/website_livechat/static/src/js/website_livechat.editor.js
parentfeae553b98c88282695c77382f4a52c78b3f8f70 (diff)
[REF] website, *: add automatic context for call_kw rpc
* web_editor, website_blog, website_crm_partner_assign, website_links, website_livechat, website_mail_channel, website_mass_mailing, website_slides Calling a model's method thanks to an RPC will now always send the web_editor context automatically, making sure the method gets the website_id all the time, removing the need to guess the current website (now the get_current_website method uses the context website_id if any). Note: other routes already have the website_id via request.env.context if they correctly set website=True (this commit also adds website=True for scss files customization routes).
Diffstat (limited to 'addons/website_livechat/static/src/js/website_livechat.editor.js')
-rw-r--r--addons/website_livechat/static/src/js/website_livechat.editor.js2
1 files changed, 0 insertions, 2 deletions
diff --git a/addons/website_livechat/static/src/js/website_livechat.editor.js b/addons/website_livechat/static/src/js/website_livechat.editor.js
index 32ad9f8d268..2ec5bc2a793 100644
--- a/addons/website_livechat/static/src/js/website_livechat.editor.js
+++ b/addons/website_livechat/static/src/js/website_livechat.editor.js
@@ -4,7 +4,6 @@ odoo.define('website_livechat.editor', function (require) {
var core = require('web.core');
var wUtils = require('website.utils');
var WebsiteNewMenu = require('website.newMenu');
-var weContext = require('web_editor.context');
var _t = core._t;
@@ -36,7 +35,6 @@ WebsiteNewMenu.include({
return self._rpc({
model: 'im_livechat.channel',
method: 'create_and_get_website_url',
- context: weContext.get(),
args: [[]],
kwargs: {
name: name,