aboutsummaryrefslogtreecommitdiffstats
path: root/db/normalized
diff options
context:
space:
mode:
authorRan Guin <[email protected]>2021-07-26 19:21:11 -0700
committerRan Guin <[email protected]>2021-07-26 19:21:11 -0700
commit71e8209a83c139c7dd2096a287774436daa3d76d (patch)
treedfab172eb29d95820d02f39f2f4795591aa904c4 /db/normalized
parent1c184089ef4704365c7b426a0fd7f13e68c63b36 (diff)
downloadcoinos-server-71e8209a83c139c7dd2096a287774436daa3d76d.tar.gz
coinos-server-71e8209a83c139c7dd2096a287774436daa3d76d.zip
add accounts.contract, user.subscriptions
Diffstat (limited to 'db/normalized')
-rw-r--r--db/normalized/accounts.js5
-rw-r--r--db/normalized/user_preferences.js6
2 files changed, 8 insertions, 3 deletions
diff --git a/db/normalized/accounts.js b/db/normalized/accounts.js
index d09f2dcf..6136d0a0 100644
--- a/db/normalized/accounts.js
+++ b/db/normalized/accounts.js
@@ -11,7 +11,10 @@ exports.up = function(knex) {
t.enu('network', ['Bitcoin', 'Liquid', 'Lightning', 'CoinOS']).notNull();
- // t.string('contract');
+ t.longtext('contract').collate('utf8mb4').nullable(); // custodial ?
+
+ // knex.raw("ALTER TABLE accounts MODIFY `contract` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL")
+
// t.string('hide');
// t.string('index');
diff --git a/db/normalized/user_preferences.js b/db/normalized/user_preferences.js
index fafe5f1a..36956dc0 100644
--- a/db/normalized/user_preferences.js
+++ b/db/normalized/user_preferences.js
@@ -8,11 +8,13 @@ exports.up = function(knex) {
t.enum('default_currency', ['CAD', 'USD']).notNull().defaultTo('CAD');
t.enum('default_fiat', ['CAD', 'USD']).notNull().defaultTo('CAD');
t.set('show_currencies', ['CAD', 'USD']).notNull().defaultTo('CAD');
-
+ t.longtext(`subscriptions`).collate('utf8mb4').nullable(); // CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL")
t.timestamps();
+
+ // knex.raw("ALTER TABLE users MODIFY `subscriptions` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL")
})
}
exports.down = function(knex) {
return knex.schema.dropTable('user_preferences');
-}; \ No newline at end of file
+};