mirror of https://github.com/OCA/web.git
[10.0][IMP] web_switch_company_warning module
parent
fb0744c1f0
commit
72f91a8366
|
@ -5,7 +5,7 @@
|
||||||
"name": "Multicompany - Switch Company Warning",
|
"name": "Multicompany - Switch Company Warning",
|
||||||
"summary": "Show a warning if current company has been switched"
|
"summary": "Show a warning if current company has been switched"
|
||||||
" in another tab or window.",
|
" in another tab or window.",
|
||||||
"version": "10.0.0.1.1",
|
"version": "10.0.0.1.2",
|
||||||
"category": "web",
|
"category": "web",
|
||||||
"website": "http://akretion.com",
|
"website": "http://akretion.com",
|
||||||
"license": "AGPL-3",
|
"license": "AGPL-3",
|
||||||
|
|
|
@ -38,7 +38,12 @@ odoo.define('web_switch_company_warning.widget', function (require) {
|
||||||
init: function(parent) {
|
init: function(parent) {
|
||||||
this._super(parent);
|
this._super(parent);
|
||||||
var switchCompanyWarning = new SwitchCompanyWarningWidget();
|
var switchCompanyWarning = new SwitchCompanyWarningWidget();
|
||||||
|
// Choose where to append depending on whether web_responsive is installed or not
|
||||||
|
if (document.getElementById('oe_main_menu_navbar')) {
|
||||||
switchCompanyWarning.appendTo('#oe_main_menu_navbar');
|
switchCompanyWarning.appendTo('#oe_main_menu_navbar');
|
||||||
|
} else {
|
||||||
|
switchCompanyWarning.insertAfter('.main-nav');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue