Files
logbuch/drizzle/0011_concerned_domino.sql
T
Matthias G 0fd6da62d1 Manage the Slack digest in the admin
New settings area: the webhook lives in the database and is only shown
shortened afterwards, the environment variable stays as a fallback. A switch
decides whether internal entries travel, a button sends the digest right
away, and every run is recorded with period, count, projects, result and
who triggered it.
2026-08-03 12:13:57 +02:00

18 lines
576 B
SQL

CREATE TABLE "app_setting" (
"key" text PRIMARY KEY NOT NULL,
"value" text NOT NULL,
"updated_at" timestamp with time zone DEFAULT now() NOT NULL
);
--> statement-breakpoint
CREATE TABLE "report_run" (
"id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
"created_at" timestamp with time zone DEFAULT now() NOT NULL,
"from_at" timestamp with time zone NOT NULL,
"to_at" timestamp with time zone NOT NULL,
"total" integer NOT NULL,
"projects" jsonb DEFAULT '[]'::jsonb NOT NULL,
"sent" boolean DEFAULT false NOT NULL,
"trigger" text NOT NULL,
"detail" text
);