[REF] *: adapt patches after new patch function
In the commit [1], the patch has been refactored to support the native keyword `super`. The current commit just adapts the codebase to that change. task 3410198 [1]: 19ea1ac08043e22a811630968e44715cc3bfc495 Part-of: odoo/odoo#125716
This commit is contained in:
@@ -4,10 +4,10 @@ import { PosStore } from "@point_of_sale/app/store/pos_store";
|
||||
import { EpsonPrinter } from "@pos_epson_printer/app/epson_printer";
|
||||
import { patch } from "@web/core/utils/patch";
|
||||
|
||||
patch(PosStore.prototype, "pos_epson_printer.PosStore", {
|
||||
patch(PosStore.prototype, {
|
||||
after_load_server_data() {
|
||||
var self = this;
|
||||
return this._super(...arguments).then(function () {
|
||||
return super.after_load_server_data(...arguments).then(function () {
|
||||
if (self.config.other_devices && self.config.epson_printer_ip) {
|
||||
self.hardwareProxy.printer = new EpsonPrinter({ ip: self.config.epson_printer_ip });
|
||||
}
|
||||
@@ -17,7 +17,7 @@ patch(PosStore.prototype, "pos_epson_printer.PosStore", {
|
||||
if (config.printer_type === "epson_epos") {
|
||||
return new EpsonPrinter({ ip: config.epson_printer_ip });
|
||||
} else {
|
||||
return this._super(...arguments);
|
||||
return super.create_printer(...arguments);
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user