From 6fb85cddc0a6295391f0dd2c153cf804aa0dec95 Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Thu, 2 Oct 2025 19:08:26 +0000 Subject: [PATCH] Fix: Update content_submissions constraint --- ...3_be6a61c4-7399-4ff3-9bf9-96d5f93133e8.sql | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 supabase/migrations/20251002190813_be6a61c4-7399-4ff3-9bf9-96d5f93133e8.sql diff --git a/supabase/migrations/20251002190813_be6a61c4-7399-4ff3-9bf9-96d5f93133e8.sql b/supabase/migrations/20251002190813_be6a61c4-7399-4ff3-9bf9-96d5f93133e8.sql new file mode 100644 index 00000000..f4b084ed --- /dev/null +++ b/supabase/migrations/20251002190813_be6a61c4-7399-4ff3-9bf9-96d5f93133e8.sql @@ -0,0 +1,19 @@ +-- Drop existing constraint +ALTER TABLE public.content_submissions +DROP CONSTRAINT IF EXISTS content_submissions_submission_type_check; + +-- Add updated constraint with photo_edit and photo_delete +ALTER TABLE public.content_submissions +ADD CONSTRAINT content_submissions_submission_type_check +CHECK (submission_type IN ( + 'park', + 'ride', + 'review', + 'photo', + 'manufacturer', + 'operator', + 'designer', + 'property_owner', + 'photo_edit', + 'photo_delete' +)); \ No newline at end of file