Fix Phase 4 in calendar sync to reset unauthorized changes in target system based on timestamps for source_system_wins strategy

This commit is contained in:
root
2025-10-23 11:26:25 +00:00
parent 7d5403b4af
commit 9f50f201df
2 changed files with 18 additions and 3 deletions

View File

@@ -61,7 +61,7 @@ CREATE TABLE calendar_sync_audit (
-- Indizes (angepasst für Soft Deletes)
CREATE UNIQUE INDEX idx_calendar_sync_advoware ON calendar_sync (employee_kuerzel, advoware_frnr) WHERE advoware_frnr IS NOT NULL AND deleted = FALSE;
CREATE UNIQUE INDEX idx_calendar_sync_google ON calendar_sync (employee_kuerzel, google_event_id) WHERE google_event_id IS NOT NULL;
CREATE UNIQUE INDEX idx_calendar_sync_google ON calendar_sync (employee_kuerzel, google_event_id) WHERE google_event_id IS NOT NULL AND deleted = FALSE;
```
## Funktionalität