Skip to content

Commit

Permalink
Merge PR #402 into 11.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Nov 11, 2019
2 parents 5d3846e + 7c16312 commit 14fe4e4
Showing 1 changed file with 9 additions and 17 deletions.
26 changes: 9 additions & 17 deletions pos_order_mgmt/static/src/js/widgets.js
Original file line number Diff line number Diff line change
Expand Up @@ -163,23 +163,15 @@ odoo.define('pos_order_mgmt.widgets', function (require) {
// taxes based on fiscal position
this.pos.current_order = this.pos.get_order()
this.pos.set_order(order);
if (this.pos.config.iface_print_via_proxy) {
this.pos.proxy.print_receipt(QWeb.render(
'XmlReceipt', {
receipt: receipt,
widget: this,
pos: this.pos,
order: order,
orderlines: order.get_orderlines(),
paymentlines: order.get_paymentlines(),
}));
this.pos.set_order(this.pos.current_order);
this.pos.current_order = false;
} else {
this.pos.reloaded_order = order;
this.gui.show_screen('receipt');
this.pos.reloaded_order = false;
}
this.pos.reloaded_order = order;
var skip_screen_state = this.pos.config.iface_print_skip_screen;
// Disable temporarily skip screen if set
this.pos.config.iface_print_skip_screen = false;
this.gui.show_screen('receipt');
this.pos.reloaded_order = false;
// Set skip screen to whatever previous state
this.pos.config.iface_print_skip_screen = skip_screen_state;

},

action_return: function (order) {
Expand Down

0 comments on commit 14fe4e4

Please sign in to comment.