WIP
This commit is contained in:
parent
896bec93cb
commit
35cbb46688
6 changed files with 62 additions and 23 deletions
|
|
@ -21,8 +21,7 @@ exports.up = function (next) {
|
|||
tx_hash text,
|
||||
phone text,
|
||||
error text,
|
||||
created timestamptz NOT NULL default now(),
|
||||
unique (session_id)
|
||||
created timestamptz NOT NULL default now()
|
||||
)`,
|
||||
`create table cash_out_txs (
|
||||
session_id uuid PRIMARY KEY,
|
||||
|
|
@ -40,8 +39,7 @@ exports.up = function (next) {
|
|||
phone text,
|
||||
error text,
|
||||
created timestamptz NOT NULL default now(),
|
||||
confirmation_time timestamptz,
|
||||
unique (session_id)
|
||||
confirmation_time timestamptz
|
||||
)`,
|
||||
`create type cash_out_action_types AS ENUM (${actions})`,
|
||||
`create table cash_out_actions (
|
||||
|
|
|
|||
20
migrations/012-add-hd-path-serial.js
Normal file
20
migrations/012-add-hd-path-serial.js
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
var db = require('./db')
|
||||
|
||||
exports.up = function (next) {
|
||||
var sql = [
|
||||
`create table cash_out_hds (
|
||||
session_id uuid PRIMARY KEY,
|
||||
to_address text NOT NULL,
|
||||
crypto_code text NOT NULL,
|
||||
hd_path_prefix text NOT NULL,
|
||||
hd_serial integer NOT NULL,
|
||||
created timestamptz NOT NULL default now(),
|
||||
unique (crypto_code, hd_serial)
|
||||
)`
|
||||
]
|
||||
db.multi(sql, next)
|
||||
}
|
||||
|
||||
exports.down = function (next) {
|
||||
next()
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue