[FIX] pos_hr: No close button

When pos_hr is installed but not checked in the current pos.config,
the close button was not showing for non admin users.

closes odoo/odoo#57141

X-original-commit: ead7e3b801d4f7dcb2d48cf308e405d643dc5368
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Signed-off-by: Antoine Prieëls <aprieels@users.noreply.github.com>
This commit is contained in:
Antoine Prieels
2020-09-07 06:57:20 +00:00
parent 4c46615e6a
commit 41c0f7c7dd
+1 -1
View File
@@ -12,7 +12,7 @@ odoo.define('pos_hr.chrome', function (require) {
if (this.env.pos.config.module_pos_hr) this.showTempScreen('LoginScreen');
}
get headerButtonIsShown() {
return this.env.pos.get('cashier').role == 'manager';
return !this.env.pos.config.module_pos_hr || this.env.pos.get('cashier').role == 'manager';
}
};