PurgeCalendarEntriesJob.ktIPrivacyProtectionJob to delete calendar events older than a configurable number of days. Configured via JSON property projectforge.privacyProtection.purgeCalendars specifying calendar IDs and expiry days. Typically used to auto-purge illness calendars.Reads purgeCalendars property as a JSON array of {calendarId, expiryDays} objects via JsonUtils.fromJson. On @PostConstruct, parses the config and registers itself with CronPrivacyProtectionJob. Handles parsing errors gracefully with error logging.
For each configured calendar:
TeamCalDao.find(calendarId, checkAccess=false).expiryDate = now - expiryDays.SELECT_ENTRIES_IN_THE_PAST_TO_PURGE in a transaction to find events ending before the expiry date.TeamEventDao.forceDelete(event, checkAccess=false), also removing history entries (commit c3a3a7476).868d6abb7 2025 -> 2026 63081666f Source file headers: 2024-> 2025. 1b50060c3 BaseDao: renamed: get -> find. 87aaf6a5a Migration stuff in progress... 3aeda5ef5 Big change: all save|update|...InTrans renamed. 1135ccbca Persistence: functions renamed: *NewTrans -> *InTrans b095e6f7d !!!!! Big change of Transaction handling. b6092df09 Copyright 2023 -> 2024 ab45d51fa Copyright 2001-2022 -> 2001-2023. 5f7ef41b8 Copyright 2021 -> 2022 c3a3a7476 PurgeCalendarEntriesJob deletes now also history entries. f491ef05c PROJECTFORGE-3690: SkillMatrixPrivacyProtectionJob. 534dab9cd PROJECTFORGE-3687: CronPrivacyProtectionJob implemented.