diff --git a/static/src/css/style.css b/static/src/css/style.css index 1dbe0de..0d58c94 100644 --- a/static/src/css/style.css +++ b/static/src/css/style.css @@ -73,6 +73,17 @@ height: 100%; } +.pos .close-button-bls { + position: absolute; + left: 15px; + padding: 10px; + text-transform: uppercase; + position: absolute; + border-radius: 3px; + border: solid 1px #d1d1d1; + cursor: pointer; +} + .logo-scan{ width: 250px; } diff --git a/static/src/js/container.js b/static/src/js/container.js index 64b1e5e..657db2f 100644 --- a/static/src/js/container.js +++ b/static/src/js/container.js @@ -1020,13 +1020,25 @@ odoo.define('vracoop_pos_free_balance_v2.container_balance', function (require) build_chrome: function() { this._super(); + var self = this; if (this.pos.config.is_balance_free) { this.$('.pos-topheader').addClass('oe_hidden'); + this.$('.close-button-bls').click(function(){ + self.click_close(); + }); } else { this.$('.pos-topheader-title').addClass('oe_hidden'); } + }, + + click_close: function() { + var self = this; + clearTimeout(this.confirmed); + this.gui.close(); + }, + }); gui.Gui.include({ diff --git a/static/src/xml/pos.xml b/static/src/xml/pos.xml index c1c0cff..cbca37e 100644 --- a/static/src/xml/pos.xml +++ b/static/src/xml/pos.xml @@ -4,6 +4,7 @@
+ close