mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-24 17:51:13 -05:00
Refactor: Make photo upload reusable
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
-- Update content_submissions submission_type to support all entity types
|
||||
ALTER TABLE public.content_submissions
|
||||
DROP CONSTRAINT IF EXISTS content_submissions_submission_type_check;
|
||||
|
||||
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'
|
||||
));
|
||||
|
||||
COMMENT ON COLUMN public.content_submissions.content IS 'JSONB structure: { title?, photos: Array<{url, caption?, title?, date?, order}>, context: "park"|"ride"|"manufacturer"|"operator"|"designer"|"property_owner", entity_id: string, park_id?: string (legacy), ride_id?: string (legacy), company_id?: string (legacy) }';
|
||||
Reference in New Issue
Block a user