logo
This commit is contained in:
@@ -2,6 +2,16 @@ import type { NextConfig } from "next";
|
|||||||
|
|
||||||
const nextConfig: NextConfig = {
|
const nextConfig: NextConfig = {
|
||||||
/* config options here */
|
/* config options here */
|
||||||
|
images: {
|
||||||
|
remotePatterns: [
|
||||||
|
{
|
||||||
|
protocol: 'https',
|
||||||
|
hostname: 'apiilker.edoysoft.com',
|
||||||
|
port: '',
|
||||||
|
pathname: '/storage/v1/object/public/**',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
export default nextConfig;
|
export default nextConfig;
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import { Plus, Users, Edit } from "lucide-react"
|
|||||||
import Link from "next/link"
|
import Link from "next/link"
|
||||||
import { Card, CardContent, CardFooter, CardHeader, CardTitle } from "@/components/ui/card"
|
import { Card, CardContent, CardFooter, CardHeader, CardTitle } from "@/components/ui/card"
|
||||||
import { Badge } from "@/components/ui/badge"
|
import { Badge } from "@/components/ui/badge"
|
||||||
|
import Image from "next/image"
|
||||||
|
|
||||||
export default async function HallsPage() {
|
export default async function HallsPage() {
|
||||||
const supabase = await createClient()
|
const supabase = await createClient()
|
||||||
@@ -34,9 +35,6 @@ export default async function HallsPage() {
|
|||||||
<div className="grid gap-6 sm:grid-cols-2 lg:grid-cols-3">
|
<div className="grid gap-6 sm:grid-cols-2 lg:grid-cols-3">
|
||||||
{halls?.map((hall) => (
|
{halls?.map((hall) => (
|
||||||
<Card key={hall.id} className="flex flex-col overflow-hidden transition-all hover:shadow-md">
|
<Card key={hall.id} className="flex flex-col overflow-hidden transition-all hover:shadow-md">
|
||||||
import Image from "next/image"
|
|
||||||
|
|
||||||
// ... inside the CardHeader ...
|
|
||||||
<CardHeader className="bg-muted/20 pb-4 relative">
|
<CardHeader className="bg-muted/20 pb-4 relative">
|
||||||
<div className="flex items-start justify-between gap-4">
|
<div className="flex items-start justify-between gap-4">
|
||||||
<div className="flex items-center gap-3">
|
<div className="flex items-center gap-3">
|
||||||
|
|||||||
3
supabase/add_logo_url_to_halls.sql
Normal file
3
supabase/add_logo_url_to_halls.sql
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
-- Add logo_url column to halls table
|
||||||
|
alter table halls
|
||||||
|
add column logo_url text;
|
||||||
20
supabase/storage_setup.sql
Normal file
20
supabase/storage_setup.sql
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
-- 1. Create the storage bucket
|
||||||
|
insert into storage.buckets (id, name, public)
|
||||||
|
values ('hall-logos', 'hall-logos', true);
|
||||||
|
|
||||||
|
-- 2. Enable RLS (although buckets are publicly accessible via the 'public' flag, policies are good practice)
|
||||||
|
create policy "Public Access"
|
||||||
|
on storage.objects for select
|
||||||
|
using ( bucket_id = 'hall-logos' );
|
||||||
|
|
||||||
|
create policy "Authenticated Uploads"
|
||||||
|
on storage.objects for insert
|
||||||
|
with check ( bucket_id = 'hall-logos' and auth.role() = 'authenticated' );
|
||||||
|
|
||||||
|
create policy "Authenticated Updates"
|
||||||
|
on storage.objects for update
|
||||||
|
with check ( bucket_id = 'hall-logos' and auth.role() = 'authenticated' );
|
||||||
|
|
||||||
|
create policy "Authenticated Deletes"
|
||||||
|
on storage.objects for delete
|
||||||
|
using ( bucket_id = 'hall-logos' and auth.role() = 'authenticated' );
|
||||||
Reference in New Issue
Block a user