- YT Video For Setup Kinde Kinde Auth Setup Video
- Make Sure To Add Github, Facebook And Google Outh2.0 In Kinde
KINDE_CLIENT_ID=<change this>
KINDE_CLIENT_SECRET=<change this>
KINDE_ISSUER_URL=<change this>
KINDE_SITE_URL=http://localhost:3000
KINDE_POST_LOGOUT_REDIRECT_URL=http://localhost:3000
KINDE_POST_LOGIN_REDIRECT_URL=http://localhost:3000/dashboard
- Go to Your Supabase Dashboard.
- YT Video For Setup Supabase Supabase DB Setup
- Select Your Project / Create A New One.
- Navigate To The
Project Settings
In The Sidebar Of Your Newly Created Project. - Now Go To
API
UnderCONFIGURATION
Section. - Copy The
URL
AndANON-PUBLIC
From This Tab And Paste In Your .env.local File Respectively.
NEXT_PUBLIC_SUPABASE_PASSWORD=
NEXT_PUBLIC_SUPABASE_URL=
NEXT_PUBLIC_SUPABASE_ANON_KEY=
NEXT_PUBLIC_BASE_URL=http://localhost:3000
- Go To Your Supabase Dashboard.
- Select Your Project.
- Navigate To The
SQL Editor
Tab In The Sidebar. - Run The Following SQL Query:
create table
public.event_details (
id uuid not null default gen_random_uuid (),
created_at timestamp with time zone not null default now(),
event_title text not null,
event_description text not null,
event_location text not null,
event_registration_startdate timestamp with time zone not null,
event_registration_enddate timestamp with time zone not null,
team_size smallint not null default '1'::smallint,
event_enddate timestamp with time zone not null,
event_price text null default 'Free'::text,
event_likes bigint null default '0'::bigint,
event_formlink text not null,
organizer_name text not null,
organizer_email text not null,
organizer_contact bigint not null,
event_category text not null,
event_tags text[] not null,
event_social_links text[] not null,
event_duration bigint not null,
event_startdate timestamp with time zone not null,
updated_at timestamp with time zone null default (now() at time zone 'utc'::text),
constraint event_details_pkey primary key (id),
constraint event_details_created_at_key unique (created_at),
constraint event_details_event_title_key unique (event_title)
) tablespace pg_default;
-
Navigate To The
Storage
In The Sidebar Of Your Newly Created Project. -
Now Go To
New Bucket
And Create APublic Buckets
Namedevent_images
Andevent_space
. -
Then Under The Buckets We Have
CONFIGURATION
SelectPolicies
Make New Policy WithFor Full Customization
Forevent_images
Andevent_space
Withall
Permissions.
create table
public.event_images (
id uuid not null default gen_random_uuid (),
created_at timestamp with time zone not null default now(),
url text not null,
event_id uuid not null,
constraint event_images_pkey primary key (id),
constraint event_images_event_id_fkey foreign key (event_id) references event_details (id)
) tablespace pg_default;
create table
public.event_participants (
id uuid not null default gen_random_uuid (),
created_at timestamp with time zone not null default now(),
participant_name text not null,
participant_email text not null,
participant_contact bigint not null,
event_id uuid not null,
is_registered boolean null default false,
constraint event_participants_pkey primary key (id),
constraint event_participants_event_id_fkey foreign key (event_id) references event_details (id)
) tablespace pg_default;
create table
public.event_space (
id uuid not null default gen_random_uuid (),
created_at timestamp with time zone not null default now(),
name text not null,
description text not null,
location text not null,
capacity bigint not null,
price_per_hour bigint not null,
owner_email character varying not null,
updated_at timestamp with time zone null default (now() at time zone 'utc'::text),
owner_contact bigint not null,
availability boolean null default true,
amenities text[] not null,
space_likes bigint null default '0'::bigint,
constraint event_space_pkey primary key (id),
constraint event_space_name_key unique (name)
) tablespace pg_default;
create table
public.event_space_img_vid (
id uuid not null default gen_random_uuid (),
created_at timestamp with time zone not null default now(),
url text not null,
event_space_id uuid not null,
constraint event_space_img - vid_pkey primary key (id),
constraint event_space_img - vid_event_space_id_fkey foreign key (event_space_id) references event_space (id)
) tablespace pg_default;
create table
public.event_space_request (
id uuid not null default gen_random_uuid (),
created_at timestamp with time zone not null default now(),
organiser_id text not null,
space_id uuid not null,
request_date timestamp with time zone not null,
status character varying not null default 'pending'::character varying,
constraint event_space_request_pkey primary key (id),
constraint event_space_request_space_id_fkey foreign key (space_id) references event_space (id)
) tablespace pg_default;
-
This Will Create A Table Named
event_details
,event_images
,event_participants
,event_space
,event_space_img_vid
,event_space_request
. -
Now Go To
Policies
UnderCONFIGURATION
Section. -
Create Policy for
event_details
,event_images
,event_participants
,event_space
,event_space_img_vid
,event_space_request
Withall
Permissions.
Learn Whole Supabase (Optional)
YT Platlist
⭐️ Support The Project!
If You Find This Project Helpful, Please Consider Giving It A Star On GitHub! Your Support Helps To Grow The Project And Reach More Contributors.