[REF] pos_adyen: migration to OWL framework

This commit is contained in:
Joseph Caburnay
2020-05-12 12:48:58 +00:00
committed by Pierre Masereel
parent 548af5781f
commit 82b89762b7
@@ -4,6 +4,7 @@ odoo.define('pos_adyen.payment', function (require) {
var core = require('web.core');
var rpc = require('web.rpc');
var PaymentInterface = require('point_of_sale.PaymentInterface');
const { Gui } = require('point_of_sale.Gui');
var _t = core._t;
@@ -271,12 +272,6 @@ var PaymentAdyen = PaymentInterface.extend({
} else {
line.set_payment_status('waitingCard');
// This is not great, the payment screen should be
// refactored so it calls render_paymentlines whenever a
// paymentline changes. This way the call to
// set_payment_status would re-render it automatically.
this.pos.chrome.gui.current_screen.render_paymentlines();
var self = this;
var res = new Promise(function (resolve, reject) {
// clear previous intervals just in case, otherwise
@@ -301,7 +296,7 @@ var PaymentAdyen = PaymentInterface.extend({
if (!title) {
title = _t('Adyen Error');
}
this.pos.gui.show_popup('error',{
Gui.showPopup('ErrorPopup',{
'title': title,
'body': msg,
});