only allow guests to register for specific events; don't even show them the other trips

This commit is contained in:
2023-04-29 18:57:01 +02:00
parent 5b06eaeebc
commit bb4dba7bc9
12 changed files with 96 additions and 29 deletions

View File

@ -21,6 +21,7 @@ CREATE TABLE IF NOT EXISTS "trip_details" (
"planned_starting_time" text NOT NULL,
"max_people" INTEGER NOT NULL,
"day" TEXT NOT NULL,
"allow_guests" boolean NOT NULL default false,
"notes" TEXT,
"trip_type_id" INTEGER,
FOREIGN KEY(trip_type_id) REFERENCES trip_type(id)
@ -30,7 +31,6 @@ CREATE TABLE IF NOT EXISTS "planned_event" (
"id" integer NOT NULL PRIMARY KEY AUTOINCREMENT,
"name" text NOT NULL,
"planned_amount_cox" INTEGER unsigned NOT NULL,
"allow_guests" boolean NOT NULL default false,
"trip_details_id" INTEGER NOT NULL,
"created_at" text NOT NULL DEFAULT CURRENT_TIMESTAMP,
FOREIGN KEY(trip_details_id) REFERENCES trip_details(id) ON DELETE CASCADE