feat: reports
This commit is contained in:
12
supabase/migrations/20250610163930_add_report_table.sql
Normal file
12
supabase/migrations/20250610163930_add_report_table.sql
Normal file
@@ -0,0 +1,12 @@
|
||||
CREATE TABLE reports (
|
||||
id uuid PRIMARY KEY DEFAULT gen_random_uuid(),
|
||||
study_space_id uuid REFERENCES study_spaces(id) ON DELETE CASCADE,
|
||||
created_at timestamp with time zone DEFAULT now(),
|
||||
updated_at timestamp with time zone DEFAULT now(),
|
||||
type text NOT NULL,
|
||||
content text
|
||||
);
|
||||
|
||||
CREATE TRIGGER reports_updated_at
|
||||
AFTER UPDATE ON reports
|
||||
FOR EACH ROW EXECUTE FUNCTION handle_updated_at();
|
||||
Reference in New Issue
Block a user