From c14a7a4610cfd529f47205b6c4c9d7e7ef97b899 Mon Sep 17 00:00:00 2001 From: lejeune quentin Date: Mon, 25 Oct 2021 07:50:18 +0000 Subject: [PATCH] [FIX] hw_drivers: fix open cashbox with mapped action In the new version of Odoo and in the drivers we "map" the actions. The "mapped" functions must take at least 2 variables as parameters; Self and Data closes odoo/odoo#78912 X-original-commit: 86653d2024075129c3f52390abdce0abb8d8ec31 Signed-off-by: Masereel Pierre --- addons/hw_drivers/iot_handlers/drivers/PrinterDriver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/hw_drivers/iot_handlers/drivers/PrinterDriver.py b/addons/hw_drivers/iot_handlers/drivers/PrinterDriver.py index 3e6530afeae..36d82b9aadd 100644 --- a/addons/hw_drivers/iot_handlers/drivers/PrinterDriver.py +++ b/addons/hw_drivers/iot_handlers/drivers/PrinterDriver.py @@ -250,7 +250,7 @@ class PrinterDriver(Driver): title = commands['title'] % b'IoTBox Status' self.print_raw(commands['center'] + title + b'\n' + wlan.encode() + mac.encode() + ip.encode() + homepage.encode() + pairing_code.encode() + commands['cut']) - def open_cashbox(self): + def open_cashbox(self, data): """Sends a signal to the current printer to open the connected cashbox.""" commands = RECEIPT_PRINTER_COMMANDS[self.receipt_protocol] for drawer in commands['drawers']: