feat: implement comprehensive recurring event single occurrence editing

- Add detach functionality for individual occurrences of recurring events
- Create POST /api/events/<id>/occurrences/<date>/detach endpoint
- Implement EventException-based EXDATE generation for master events
- Add user confirmation dialog for single vs series editing choice
- Implement manual recurrence expansion with DST timezone tolerance
- Support FREQ=DAILY and FREQ=WEEKLY with BYDAY patterns and UNTIL dates
- Create standalone events from detached occurrences without affecting master series
- Add GET /api/events/<id> endpoint for fetching master event data
- Allow editing recurring series even when master event date is in the past
- Replace browser confirm dialogs with Syncfusion dialog components
- Remove debug logging while preserving error handling
- Update documentation for recurring event functionality

BREAKING: Frontend now manually expands recurring events instead of relying on Syncfusion's EXDATE handling

This enables users to edit individual occurrences of recurring events (creating standalone events)
or edit the entire series (updating all future occurrences) through an intuitive UI workflow.
The system properly handles timezone transitions, holiday exclusions, and complex recurrence patterns.
This commit is contained in:
RobbStarkAustria
2025-10-12 20:04:23 +00:00
parent 773628c324
commit e53cc619ec
6 changed files with 739 additions and 120 deletions

View File

@@ -54,6 +54,7 @@ A comprehensive multi-service digital signage solution for educational instituti
- **Messages**: Text announcements
- **WebUntis**: Educational schedule integration
- **Recurrence & Holidays**: Recurring events can be configured to skip holidays. The backend generates EXDATEs (RecurrenceException) for holiday occurrences so the calendar never shows those instances. The "Termine an Ferientagen erlauben" toggle does not affect these events.
- **Single Occurrence Editing**: Users can edit individual occurrences of recurring events without affecting the master series. The system provides a confirmation dialog to choose between editing a single occurrence or the entire series.
### 🏫 **Academic Period Management**
- Support for school years, semesters, and trimesters
@@ -144,6 +145,7 @@ For detailed deployment instructions, see:
- **Database**: MariaDB with timezone-aware timestamps
- **Features**: RESTful API, file uploads, MQTT integration
- Recurrence/holidays: returns only master events with `RecurrenceRule` and `RecurrenceException` (EXDATEs) so clients render recurrences and skip holiday instances reliably.
- Single occurrence detach: `POST /api/events/<id>/occurrences/<date>/detach` creates standalone events from recurring series without modifying the master event.
- **Port**: 8000
- **Health Check**: `/health`
@@ -258,6 +260,7 @@ mosquitto_sub -h localhost -t "infoscreen/+/heartbeat" -v
- `GET /api/groups` - List client groups with alive status
- `GET /api/events` - List events with filtering
- `POST /api/events` - Create new event
- `POST /api/events/{id}/occurrences/{date}/detach` - Detach single occurrence from recurring series
- `GET /api/academic_periods` - List academic periods
- `POST /api/academic_periods/active` - Set active period
@@ -275,9 +278,10 @@ mosquitto_sub -h localhost -t "infoscreen/+/heartbeat" -v
## 🎨 Frontend Features
### Recurrence & holidays
- The Scheduler (Syncfusion) expands master events via `RecurrenceRule`.
- The API supplies `recurrenceException` (EXDATE) with exact occurrence start times (UTC) so holiday instances are excluded.
- Events with skip holidays display a TentTree icon next to the main event icon.
- The frontend manually expands recurring events due to Syncfusion EXDATE handling limitations.
- The API supplies `RecurrenceException` (EXDATE) with exact occurrence start times (UTC) so holiday instances are excluded.
- Events with "skip holidays" display a TentTree icon next to the main event icon.
- Single occurrence editing: Users can detach individual occurrences via confirmation dialog, creating standalone events while preserving the master series.
### Syncfusion Components Used (Material 3)
- **Schedule**: Event calendar with drag-drop support