feature/IO-3060-Realtime-Notifications-System

- Add handlers for Job and Bill Change / Register Routers
- Add Tables / Modify Tables / Add permissions.
This commit is contained in:
Dave Richer
2025-01-09 13:28:56 -08:00
parent 7a88dd1aae
commit e2e5f3f885
14 changed files with 208 additions and 4 deletions

View File

@@ -0,0 +1 @@
DROP TABLE "public"."notifications";

View File

@@ -0,0 +1,2 @@
CREATE TABLE "public"."notifications" ("id" uuid NOT NULL DEFAULT gen_random_uuid(), "created_at" timestamptz NOT NULL DEFAULT now(), "updated_at" timestamptz NOT NULL DEFAULT now(), "job_id" uuid NOT NULL, "association_id" uuid NOT NULL, "ui_translation_string" text NOT NULL, "ui_translation_meta" jsonb, "fcm_title" text NOT NULL, "fcm_message" text NOT NULL, "fcm_data" jsonb, "read" timestamptz, "meta" jsonb, "scenario" Integer NOT NULL, PRIMARY KEY ("id") , FOREIGN KEY ("job_id") REFERENCES "public"."jobs"("id") ON UPDATE restrict ON DELETE restrict, FOREIGN KEY ("association_id") REFERENCES "public"."associations"("id") ON UPDATE restrict ON DELETE restrict, UNIQUE ("id"));COMMENT ON TABLE "public"."notifications" IS E'Real Time Notifications System';
CREATE EXTENSION IF NOT EXISTS pgcrypto;