import React from 'react'
import { useGetEventsByIdQuery } from '../../Services/api.service';
import { useNavigate, useParams } from 'react-router-dom';
import { Box, Divider, Image, Tag, useToast } from '@chakra-ui/react';
import FullscreenLoaders from '../../Components/Loaders/FullscreenLoaders';
import { OPACITY_ON_LOAD } from '../../Layout/animations';
import Header from '../../Components/Header';
import { formatDate } from '../../Components/Functions/UTCConvertor';
const ViewEvents = () => {
const { id } = useParams();
const toast = useToast();
const navigate = useNavigate();
const { data, error, isLoading } = useGetEventsByIdQuery(id);
const events = data?.data;
if (isLoading) {
return ;
}
return(
Events Info
Select the platform for which you need to create this campaign.
Events Banner image
Below is the profile that will be displayed on the community page.
Status
{events?.status ? (
Active
) : (
Inactive
)}
Title
{events?.title}
Content
{events?.content}
Location
{events?.location}
Organisation name
{events?.organizer_name}
Organisation number
{events?.organizer_mobile_number}
Organisation email
{events?.organizer_email}
Created at
{formatDate(events?.createdAt)}
Updated at
{formatDate(events?.updatedAt)}
)
}
export default ViewEvents