fix: cashbox batches
fix: pairing missing stacker parameter
This commit is contained in:
parent
4655d733b2
commit
2e9bb3c7df
2 changed files with 2 additions and 2 deletions
|
|
@ -36,7 +36,7 @@ function updateMachineWithBatch (machineContext, oldCashboxCount) {
|
|||
WHERE bills.cash_in_txs_id = cash_in_txs.id AND
|
||||
cash_in_txs.device_id = $2 AND
|
||||
bills.cashbox_batch_id IS NULL`, [batchId, deviceId])
|
||||
const q3 = t.none(`UPDATE devices SET cashbox=$1, cassette1=$2, cassette2=$3, cassette3=$4, cassette4=$5, stacker1f=$6, stacker1r=$7, stacker1f=$8, stacker1r=$9, stacker1f=$10, stacker1r=$11 WHERE device_id=$12`, [
|
||||
const q3 = t.none(`UPDATE devices SET cashbox=$1, cassette1=$2, cassette2=$3, cassette3=$4, cassette4=$5, stacker1f=$6, stacker1r=$7, stacker2f=$8, stacker2r=$9, stacker3f=$10, stacker3r=$11 WHERE device_id=$12`, [
|
||||
cashUnits.cashbox,
|
||||
cashUnits.cassette1,
|
||||
cashUnits.cassette2,
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ function pair (token, deviceId, machineModel, numOfCassettes = DEFAULT_NUMBER_OF
|
|||
.then(r => {
|
||||
if (r.expired) return false
|
||||
|
||||
const insertSql = `insert into devices (device_id, name, number_of_cassettes, number_of_stackers) values ($1, $2, $3)
|
||||
const insertSql = `insert into devices (device_id, name, number_of_cassettes, number_of_stackers) values ($1, $2, $3, $4)
|
||||
on conflict (device_id)
|
||||
do update set paired=TRUE, display=TRUE`
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue