manga-app/drizzle/meta/0001_snapshot.json

165 lines
3.8 KiB
JSON
Raw Permalink Normal View History

2024-04-01 21:17:17 +00:00
{
"id": "94be70b1-469e-45d7-b78e-ce1cbe863401",
"prevId": "432591f9-af02-4d29-89ec-2c89c53477ff",
"version": "5",
"dialect": "pg",
"tables": {
"books": {
"name": "books",
"schema": "",
"columns": {
"id": {
"name": "id",
"type": "uuid",
"primaryKey": true,
"notNull": true,
"default": "gen_random_uuid()"
},
"name": {
"name": "name",
"type": "text",
"primaryKey": false,
"notNull": true
},
"type": {
"name": "type",
"type": "bookType",
"primaryKey": false,
"notNull": true
}
},
"indexes": {},
"foreignKeys": {},
"compositePrimaryKeys": {},
"uniqueConstraints": {}
},
"reading_progress": {
"name": "reading_progress",
"schema": "",
"columns": {
"id": {
"name": "id",
"type": "uuid",
"primaryKey": true,
"notNull": true,
"default": "gen_random_uuid()"
},
"user_id": {
"name": "user_id",
"type": "uuid",
"primaryKey": false,
"notNull": true
},
"book_id": {
"name": "book_id",
"type": "uuid",
"primaryKey": false,
"notNull": true
},
"chapters_read": {
"name": "chapters_read",
"type": "integer",
"primaryKey": false,
"notNull": true
},
"date_created": {
"name": "date_created",
"type": "date",
"primaryKey": false,
"notNull": true,
"default": "now()"
}
},
"indexes": {},
"foreignKeys": {
"reading_progress_user_id_users_id_fk": {
"name": "reading_progress_user_id_users_id_fk",
"tableFrom": "reading_progress",
"tableTo": "users",
"columnsFrom": [
"user_id"
],
"columnsTo": [
"id"
],
"onDelete": "no action",
"onUpdate": "no action"
},
"reading_progress_book_id_books_id_fk": {
"name": "reading_progress_book_id_books_id_fk",
"tableFrom": "reading_progress",
"tableTo": "books",
"columnsFrom": [
"book_id"
],
"columnsTo": [
"id"
],
"onDelete": "no action",
"onUpdate": "no action"
}
},
"compositePrimaryKeys": {},
"uniqueConstraints": {}
},
"users": {
"name": "users",
"schema": "",
"columns": {
"id": {
"name": "id",
"type": "uuid",
"primaryKey": true,
"notNull": true,
"default": "gen_random_uuid()"
},
"discord_id": {
"name": "discord_id",
"type": "text",
"primaryKey": false,
"notNull": true
},
"name": {
"name": "name",
"type": "text",
"primaryKey": false,
"notNull": true
},
"role": {
"name": "role",
"type": "roleEnum",
"primaryKey": false,
"notNull": true,
"default": "'Member'"
}
},
"indexes": {},
"foreignKeys": {},
"compositePrimaryKeys": {},
"uniqueConstraints": {}
}
},
"enums": {
"bookType": {
"name": "bookType",
"values": {
"shonen": "shonen",
"seinen": "seinen",
"manhua": "manhua"
}
},
"roleEnum": {
"name": "roleEnum",
"values": {
"Member": "Member",
"Admin": "Admin"
}
}
},
"schemas": {},
"_meta": {
"columns": {},
"schemas": {},
"tables": {}
}
}