Commit 8a43225d by François C.

#4665 : Don't show popup if no payments line, and do not remove payment lines on…

#4665 : Don't show popup if no payments line, and do not remove payment lines on payment screen start
parent b705e2e6
......@@ -144,9 +144,12 @@ odoo.define('lacagette_custom_pos.DB', function(require) {
payment_this = self;
$('.payment-screen .top-content .back').off();
$(document).on('click', '.payment-screen .top-content .back', function(event){
self.gui.show_popup('custom-return-to-order');
if (payment_this.pos.get_order().get_paymentlines().length > 0) {
self.gui.show_popup('custom-return-to-order');
} else {
self.gui.show_screen("products");
}
});
empty_payments_lines();
}
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment