Browse Source

[FIX] compatibility with pos_restaurant

pull/339/head
Pierrick Brun 6 years ago
committed by Carlos
parent
commit
0af53fdce3
  1. 1
      pos_order_mgmt/readme/CONTRIBUTORS.rst
  2. 7
      pos_order_mgmt/static/src/js/widgets.js

1
pos_order_mgmt/readme/CONTRIBUTORS.rst

@ -1,3 +1,4 @@
* David Vidal <david.vidal@tecnativa.com>
* Sylvain LE GAL (https://twitter.com/legalsylvain)
* Carlos Martínez <carlos@domatix.com>
* Pierrick Brun <pierrick.brun@akretion.com>

7
pos_order_mgmt/static/src/js/widgets.js

@ -63,7 +63,10 @@ odoo.define('pos_order_mgmt.widgets', function (require) {
show: function () {
var self = this;
var previous_screen = this.pos.get_order().get_screen_data('previous-screen');
var previous_screen;
if (this.pos.get_order()) {
previous_screen = this.pos.get_order().get_screen_data('previous-screen');
}
if (previous_screen === 'receipt') {
this.gui.screen_instances.receipt.click_next();
this.gui.show_screen('orderlist');
@ -267,7 +270,7 @@ odoo.define('pos_order_mgmt.widgets', function (require) {
method: 'load_done_order_for_pos',
args: [order_id],
}).then(function (order_data) {
self.gui.back();
self.gui.show_screen('orderlist');
var correct_order_print = true;
if (action === 'return') {
order_data.return = true;

Loading…
Cancel
Save