feat: add aveiro cash units to the devices table

feat: change data fetching to accomodate the new cash units
This commit is contained in:
Sérgio Salgado 2023-04-16 23:42:34 +01:00
parent 06f534fa48
commit 211c4b1ea7
19 changed files with 1011 additions and 155 deletions

View file

@ -26,7 +26,7 @@ function notifyCashboxRemoval (req, res, next) {
}
logger.info('** DEBUG ** - Cashbox removal - Cashbox reset is set to automatic. A cashbox batch WILL be created')
logger.info('** DEBUG ** - Cashbox removal - Creating new batch...')
return cashbox.createCashboxBatch(req.deviceId, machine.cashbox)
return cashbox.createCashboxBatch(req.deviceId, machine.cashUnits.cashbox)
.then(() => {
logger.info(`** DEBUG ** - Cashbox removal - Finished creating the new cashbox batch`)
logger.info(`** DEBUG ** - Cashbox removal - Resetting the cashbox counter on device ${req.deviceId}`)