diff --git a/components/TrainForm.vue b/components/TrainForm.vue index bece827..fe50f9b 100644 --- a/components/TrainForm.vue +++ b/components/TrainForm.vue @@ -58,11 +58,6 @@

Training Credits: {{ session?.user?.trainingCredits }}

-
@@ -145,5 +140,4 @@ const submit = async () => { emits("submit", values); }; -const buy = async () => navigateTo("/api/checkout", { external: true }); diff --git a/drizzle/0002_purple_captain_midlands.sql b/drizzle/0002_purple_captain_midlands.sql new file mode 100644 index 0000000..b6bd245 --- /dev/null +++ b/drizzle/0002_purple_captain_midlands.sql @@ -0,0 +1 @@ +DROP TABLE "checkouts"; \ No newline at end of file diff --git a/drizzle/meta/0002_snapshot.json b/drizzle/meta/0002_snapshot.json new file mode 100644 index 0000000..fdff3f2 --- /dev/null +++ b/drizzle/meta/0002_snapshot.json @@ -0,0 +1,397 @@ +{ + "id": "ae1c4ef5-bf8c-4e95-b54f-96997af22b4b", + "prevId": "66763655-4494-445d-a894-7f079ce20cd9", + "version": "7", + "dialect": "postgresql", + "tables": { + "public.images": { + "name": "images", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": true, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "prompt": { + "name": "prompt", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "url": { + "name": "url", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "data": { + "name": "data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp with time zone", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp with time zone", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": { + "images_user_id_idx": { + "name": "images_user_id_idx", + "columns": [ + { + "expression": "user_id", + "isExpression": false, + "asc": true, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + }, + "images_created_at_idx": { + "name": "images_created_at_idx", + "columns": [ + { + "expression": "created_at", + "isExpression": false, + "asc": false, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + }, + "images_updated_at_idx": { + "name": "images_updated_at_idx", + "columns": [ + { + "expression": "updated_at", + "isExpression": false, + "asc": false, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + } + }, + "foreignKeys": { + "images_user_id_users_id_fk": { + "name": "images_user_id_users_id_fk", + "tableFrom": "images", + "tableTo": "users", + "columnsFrom": [ + "user_id" + ], + "columnsTo": [ + "id" + ], + "onDelete": "cascade", + "onUpdate": "cascade" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.models": { + "name": "models", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": true, + "notNull": true, + "default": "gen_random_uuid()" + }, + "custom_name": { + "name": "custom_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "zip_url": { + "name": "zip_url", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "model_response_data": { + "name": "model_response_data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "training_response_data": { + "name": "training_response_data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "weights_url": { + "name": "weights_url", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp with time zone", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp with time zone", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "gender": { + "name": "gender", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "eye_color": { + "name": "eye_color", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "training_type": { + "name": "training_type", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": { + "trainings_user_id_idx": { + "name": "trainings_user_id_idx", + "columns": [ + { + "expression": "user_id", + "isExpression": false, + "asc": true, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + }, + "trainings_created_at_idx": { + "name": "trainings_created_at_idx", + "columns": [ + { + "expression": "created_at", + "isExpression": false, + "asc": false, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + }, + "trainings_updated_at_idx": { + "name": "trainings_updated_at_idx", + "columns": [ + { + "expression": "updated_at", + "isExpression": false, + "asc": false, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + } + }, + "foreignKeys": { + "models_user_id_users_id_fk": { + "name": "models_user_id_users_id_fk", + "tableFrom": "models", + "tableTo": "users", + "columnsFrom": [ + "user_id" + ], + "columnsTo": [ + "id" + ], + "onDelete": "cascade", + "onUpdate": "cascade" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.users": { + "name": "users", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": true, + "notNull": true + }, + "id_stripe": { + "name": "id_stripe", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "email": { + "name": "email", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "image": { + "name": "image", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "image_credits": { + "name": "image_credits", + "type": "integer", + "primaryKey": false, + "notNull": true, + "default": 100 + }, + "training_credits": { + "name": "training_credits", + "type": "integer", + "primaryKey": false, + "notNull": true, + "default": 1 + }, + "created_at": { + "name": "created_at", + "type": "timestamp with time zone", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp with time zone", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": { + "users_email_idx": { + "name": "users_email_idx", + "columns": [ + { + "expression": "email", + "isExpression": false, + "asc": true, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + }, + "users_created_at_idx": { + "name": "users_created_at_idx", + "columns": [ + { + "expression": "created_at", + "isExpression": false, + "asc": false, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + }, + "users_updated_at_idx": { + "name": "users_updated_at_idx", + "columns": [ + { + "expression": "updated_at", + "isExpression": false, + "asc": false, + "nulls": "last" + } + ], + "isUnique": false, + "concurrently": false, + "method": "btree", + "with": {} + } + }, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "users_email_unique": { + "name": "users_email_unique", + "nullsNotDistinct": false, + "columns": [ + "email" + ] + } + } + } + }, + "enums": {}, + "schemas": {}, + "sequences": {}, + "_meta": { + "columns": {}, + "schemas": {}, + "tables": {} + } +} \ No newline at end of file diff --git a/drizzle/meta/_journal.json b/drizzle/meta/_journal.json index 5061f33..2e68537 100644 --- a/drizzle/meta/_journal.json +++ b/drizzle/meta/_journal.json @@ -15,6 +15,13 @@ "when": 1728999450472, "tag": "0001_long_expediter", "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1729020163384, + "tag": "0002_purple_captain_midlands", + "breakpoints": true } ] } \ No newline at end of file diff --git a/pages/createimages.vue b/pages/createimages.vue index ac51a60..8fbd696 100644 --- a/pages/createimages.vue +++ b/pages/createimages.vue @@ -4,7 +4,6 @@