timezone migrations
This commit is contained in:
parent
694f3e5e96
commit
5418498d06
2 changed files with 18 additions and 1 deletions
|
|
@ -12,7 +12,7 @@ exports.up = function (next) {
|
|||
'alter table transactions add dispensed boolean NOT NULL DEFAULT false',
|
||||
'alter table transactions add notified boolean NOT NULL DEFAULT false',
|
||||
'alter table transactions add redeem boolean NOT NULL DEFAULT false',
|
||||
'alter table transactions add confirmation_time timestamp',
|
||||
'alter table transactions add confirmation_time timestamptz',
|
||||
'alter table transactions add status status_stage NOT NULL DEFAULT \'notSeen\''
|
||||
]
|
||||
db.multi(sql, next)
|
||||
|
|
|
|||
17
migrations/009-update-timestamps.js
Normal file
17
migrations/009-update-timestamps.js
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
var db = require('./db')
|
||||
|
||||
exports.up = function (next) {
|
||||
var sql = [
|
||||
'alter table transactions alter created type timestamptz',
|
||||
'alter table bills alter created type timestamptz',
|
||||
'alter table dispenses alter created type timestamptz',
|
||||
'alter table machine_events alter created type timestamptz',
|
||||
'alter table pairing_tokens alter created type timestamptz',
|
||||
'alter table pending_transactions alter updated type timestamptz'
|
||||
]
|
||||
db.multi(sql, next)
|
||||
}
|
||||
|
||||
exports.down = function (next) {
|
||||
next()
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue