[FIX] point_of_sale: env.isMobile not defined at startup
Before this commit, env.isMobile was defined lately and you have to wait the next update of the template. Steps to reproduce: - Open "bar" POS session => 'pos-branding' is present in the header bar X-original-commit: 931304b9e7085c77e5b9bed8054ae47fc2a6168f Part-of: odoo/odoo#79448
This commit is contained in:
committed by
Romain Estievenart
parent
4bc7fbd720
commit
9c6cda791e
@@ -28,6 +28,8 @@ export class ChromeAdapter extends Component {
|
||||
|
||||
this.env = owl.Component.env;
|
||||
useBus(this.env.qweb, "update", () => this.render());
|
||||
setupResponsivePlugin(this.env);
|
||||
|
||||
const chrome = owl.hooks.useRef("chrome");
|
||||
owl.hooks.onMounted(async () => {
|
||||
// Add the pos error handler when the chrome component is available.
|
||||
@@ -47,7 +49,6 @@ export class ChromeAdapter extends Component {
|
||||
configureGui({ component: chrome.comp });
|
||||
await chrome.comp.start();
|
||||
registry.category("main_components").add("BlockUI", BlockUiFromRegistry);
|
||||
setupResponsivePlugin(this.env);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user