Chore: refactor to use new schema changing queries
This commit is contained in:
parent
304f792484
commit
e6059be8d2
44 changed files with 185 additions and 171 deletions
|
|
@ -14,14 +14,14 @@ function logActionById (t, action, _rec, txId) {
|
|||
const rec = _.assign(_rec, {action, tx_id: txId, redeem: false})
|
||||
const sql = pgp.helpers.insert(rec, null, 'cash_out_actions')
|
||||
|
||||
return t.none(sql)
|
||||
return t.$none(sql)
|
||||
}
|
||||
|
||||
function logAction (t, action, _rec, tx) {
|
||||
const rec = _.assign(_rec, {action, tx_id: tx.id, redeem: !!tx.redeem, device_id: tx.deviceId})
|
||||
const sql = pgp.helpers.insert(rec, null, 'cash_out_actions')
|
||||
|
||||
return t.none(sql)
|
||||
return t.$none(sql)
|
||||
.then(_.constant(tx))
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue