update db schema + populate allUser
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"version": "5",
|
||||
"dialect": "sqlite",
|
||||
"id": "58f80520-7300-4bc4-943d-87568666e42d",
|
||||
"id": "b46f7266-bc92-4a23-b12d-d162624db70a",
|
||||
"prevId": "00000000-0000-0000-0000-000000000000",
|
||||
"tables": {
|
||||
"groups": {
|
||||
@@ -35,6 +35,51 @@
|
||||
"compositePrimaryKeys": {},
|
||||
"uniqueConstraints": {}
|
||||
},
|
||||
"image_to_user": {
|
||||
"name": "image_to_user",
|
||||
"columns": {
|
||||
"user_id": {
|
||||
"name": "user_id",
|
||||
"type": "integer",
|
||||
"primaryKey": true,
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"image_name": {
|
||||
"name": "image_name",
|
||||
"type": "text",
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"created_on": {
|
||||
"name": "created_on",
|
||||
"type": "integer",
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false,
|
||||
"default": "CURRENT_TIMESTAMP"
|
||||
}
|
||||
},
|
||||
"indexes": {},
|
||||
"foreignKeys": {
|
||||
"image_to_user_user_id_users_id_fk": {
|
||||
"name": "image_to_user_user_id_users_id_fk",
|
||||
"tableFrom": "image_to_user",
|
||||
"tableTo": "users",
|
||||
"columnsFrom": [
|
||||
"user_id"
|
||||
],
|
||||
"columnsTo": [
|
||||
"id"
|
||||
],
|
||||
"onDelete": "no action",
|
||||
"onUpdate": "no action"
|
||||
}
|
||||
},
|
||||
"compositePrimaryKeys": {},
|
||||
"uniqueConstraints": {}
|
||||
},
|
||||
"opinions": {
|
||||
"name": "opinions",
|
||||
"columns": {
|
||||
@@ -58,7 +103,7 @@
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false,
|
||||
"default": "'3Choice'"
|
||||
"default": "'5Choice'"
|
||||
}
|
||||
},
|
||||
"indexes": {
|
||||
@@ -74,37 +119,6 @@
|
||||
"compositePrimaryKeys": {},
|
||||
"uniqueConstraints": {}
|
||||
},
|
||||
"phone_tokens": {
|
||||
"name": "phone_tokens",
|
||||
"columns": {
|
||||
"phone": {
|
||||
"name": "phone",
|
||||
"type": "text",
|
||||
"primaryKey": true,
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"token": {
|
||||
"name": "token",
|
||||
"type": "text",
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"created_on": {
|
||||
"name": "created_on",
|
||||
"type": "integer",
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false,
|
||||
"default": "CURRENT_TIMESTAMP"
|
||||
}
|
||||
},
|
||||
"indexes": {},
|
||||
"foreignKeys": {},
|
||||
"compositePrimaryKeys": {},
|
||||
"uniqueConstraints": {}
|
||||
},
|
||||
"provinces": {
|
||||
"name": "provinces",
|
||||
"columns": {
|
||||
@@ -160,6 +174,13 @@
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"registerno": {
|
||||
"name": "registerno",
|
||||
"type": "text",
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false
|
||||
},
|
||||
"title": {
|
||||
"name": "title",
|
||||
"type": "text",
|
||||
@@ -223,6 +244,13 @@
|
||||
"notNull": false,
|
||||
"autoincrement": false
|
||||
},
|
||||
"image": {
|
||||
"name": "image",
|
||||
"type": "text",
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false
|
||||
},
|
||||
"email": {
|
||||
"name": "email",
|
||||
"type": "text",
|
||||
@@ -271,29 +299,30 @@
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"verified": {
|
||||
"name": "verified",
|
||||
"type": "integer",
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false,
|
||||
"default": false
|
||||
}
|
||||
},
|
||||
"indexes": {
|
||||
"users_cid_unique": {
|
||||
"name": "users_cid_unique",
|
||||
"columns": [
|
||||
"cid"
|
||||
],
|
||||
"isUnique": true
|
||||
},
|
||||
"users_phone_unique": {
|
||||
"name": "users_phone_unique",
|
||||
"columns": [
|
||||
"phone"
|
||||
],
|
||||
"isUnique": true
|
||||
},
|
||||
"phone_idx": {
|
||||
"name": "phone_idx",
|
||||
"columns": [
|
||||
"phone"
|
||||
],
|
||||
"isUnique": false
|
||||
},
|
||||
"image_idx": {
|
||||
"name": "image_idx",
|
||||
"columns": [
|
||||
"image"
|
||||
],
|
||||
"isUnique": false
|
||||
}
|
||||
},
|
||||
"foreignKeys": {
|
||||
@@ -350,7 +379,7 @@
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false,
|
||||
"default": "'deciding'"
|
||||
"default": "'ignore'"
|
||||
}
|
||||
},
|
||||
"indexes": {},
|
||||
@@ -393,6 +422,56 @@
|
||||
},
|
||||
"uniqueConstraints": {}
|
||||
},
|
||||
"user_to_selection": {
|
||||
"name": "user_to_selection",
|
||||
"columns": {
|
||||
"user_id": {
|
||||
"name": "user_id",
|
||||
"type": "integer",
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false
|
||||
},
|
||||
"target_id": {
|
||||
"name": "target_id",
|
||||
"type": "integer",
|
||||
"primaryKey": false,
|
||||
"notNull": false,
|
||||
"autoincrement": false
|
||||
}
|
||||
},
|
||||
"indexes": {},
|
||||
"foreignKeys": {
|
||||
"user_to_selection_user_id_users_id_fk": {
|
||||
"name": "user_to_selection_user_id_users_id_fk",
|
||||
"tableFrom": "user_to_selection",
|
||||
"tableTo": "users",
|
||||
"columnsFrom": [
|
||||
"user_id"
|
||||
],
|
||||
"columnsTo": [
|
||||
"id"
|
||||
],
|
||||
"onDelete": "cascade",
|
||||
"onUpdate": "no action"
|
||||
},
|
||||
"user_to_selection_target_id_users_id_fk": {
|
||||
"name": "user_to_selection_target_id_users_id_fk",
|
||||
"tableFrom": "user_to_selection",
|
||||
"tableTo": "users",
|
||||
"columnsFrom": [
|
||||
"target_id"
|
||||
],
|
||||
"columnsTo": [
|
||||
"id"
|
||||
],
|
||||
"onDelete": "cascade",
|
||||
"onUpdate": "no action"
|
||||
}
|
||||
},
|
||||
"compositePrimaryKeys": {},
|
||||
"uniqueConstraints": {}
|
||||
},
|
||||
"zones": {
|
||||
"name": "zones",
|
||||
"columns": {
|
||||
@@ -416,6 +495,14 @@
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false
|
||||
},
|
||||
"total": {
|
||||
"name": "total",
|
||||
"type": "integer",
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"autoincrement": false,
|
||||
"default": 0
|
||||
}
|
||||
},
|
||||
"indexes": {
|
||||
|
||||
Reference in New Issue
Block a user