feat: add event service, dashboard activity, rsvp tracking, and date packages#110
Merged
kevinrutledge merged 2 commits intodevelopfrom Apr 5, 2026
Merged
feat: add event service, dashboard activity, rsvp tracking, and date packages#110kevinrutledge merged 2 commits intodevelopfrom
kevinrutledge merged 2 commits intodevelopfrom
Conversation
suesuee
approved these changes
Apr 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Developer
Kevin Rutledge
What changed?
Added the event feature backend - service layer, server actions, Zod schemas, dashboard activity service, and three date packages.
Event service (src/services/event.ts) - full CRUD for events plus calendar queries. createEvent, updateEvent, deleteEvent, getEventById (with RSVP count), getEventsByOwner, getAllEvents, getUpcomingEvents (dashboard), getEventsForMonth (calendar month view), getEventsForWeek (calendar week view), getEventsByGroup, isEventOwner (authorization), rsvpToEvent (upsert), getEventRsvps (with member names via member API), getEventRsvpCounts (going/maybe/declined counts). Uses a shared queryEventSummaries helper to avoid repeating the select/map pattern.
Dashboard activity service (src/services/dashboard.ts) - getRecentActivity() queries recent messages from Message table and recent events from Event table, merges them sorted by timestamp. Covers "Message sent to X Members" and "Event Created: Title" activity types. "New Member Joined" is omitted because the member API has no join date field.
Event server actions (src/actions/event.ts) - createEventAction, updateEventAction, deleteEventAction with owner/admin authorization. rsvpAction for member RSVPs. fetchEventDetail returns event + RSVPs with authorization. fetchDashboardData aggregates total members, upcoming events, recent activity, and recent messages for the dashboard page.
Zod schemas (src/schema/event.ts) - CreateEventSchema with date coercion for string-to-Date conversion, eventType enum validation (social/networking/volunteer/meeting). UpdateEventSchema as partial. RsvpSchema with status enum (going/maybe/declined).
Packages installed - date-fns for date manipulation and calendar range queries, date-fns-tz for Pacific timezone handling (TCPA compliance), react-day-picker for the frontend calendar component (Tailwind-native, shadcn/ui compatible, 2.5KB).
How to test
Checklist