diff --git a/frontend/src/components/EventAdmin.tsx b/frontend/src/components/EventAdmin.tsx index 273a1fa..5aa77d4 100644 --- a/frontend/src/components/EventAdmin.tsx +++ b/frontend/src/components/EventAdmin.tsx @@ -729,7 +729,7 @@ const EventAdmin: React.FC = () => { if (loading) { return ( - + Loading... ); @@ -737,7 +737,7 @@ const EventAdmin: React.FC = () => { if (error || !event) { return ( - + {error || 'Event not found'} ); @@ -763,7 +763,7 @@ const EventAdmin: React.FC = () => { }} > - + @@ -826,16 +826,16 @@ const EventAdmin: React.FC = () => { Info: {event.description || 'None'} - - Location: {event.location} - Date: {new Date(event.date).toLocaleString()} + + Location: {event.location} + {event.rsvp_cutoff_date && ( - - RSVP cut-off date: {new Date(event.rsvp_cutoff_date).toLocaleString()} - + + RSVP cut-off date: {new Date(event.rsvp_cutoff_date).toLocaleString()} + )} diff --git a/frontend/src/components/EventView.tsx b/frontend/src/components/EventView.tsx index c472774..248af5f 100644 --- a/frontend/src/components/EventView.tsx +++ b/frontend/src/components/EventView.tsx @@ -126,7 +126,7 @@ const EventView: React.FC = () => { if (loading) { return ( - + Loading... ); @@ -134,7 +134,7 @@ const EventView: React.FC = () => { if (error || !event) { return ( - + {error || 'Event not found'} ); @@ -160,7 +160,7 @@ const EventView: React.FC = () => { }} > - + @@ -189,16 +189,16 @@ const EventView: React.FC = () => { Info: {event.description || 'None'} - - Location: {event.location} - Date: {new Date(event.date).toLocaleString()} + + Location: {event.location} + {event.rsvp_cutoff_date && ( - - RSVP cut-off date: {new Date(event.rsvp_cutoff_date).toLocaleString()} - + + RSVP cut-off date: {new Date(event.rsvp_cutoff_date).toLocaleString()} + )} @@ -350,4 +350,4 @@ const EventView: React.FC = () => { ); }; -export default EventView; \ No newline at end of file +export default EventView;