TeamCalendar.ktTeamCalDO) with access resolution via TeamCalCache. Serves as the base class for StyledTeamCalendar (see #861).| Property | Type | Default | Description |
|---|---|---|---|
id | Long? | — | Unique calendar identifier |
title | String? | — | Display name of the calendar |
access | ACCESS? | null | User's access level to this calendar |
externalSubscription | Boolean | false | Whether this is an externally subscribed calendar |
DataobjectAccessType but scoped to calendar-level semantics.| Value | Meaning |
|---|---|
OWNER | User is the owner of the calendar |
FULL | Full read/write access |
READ | Read-only access |
MINIMAL | Minimal access (e.g. times only, no details) |
NONE | No access (only admins receive this) |
TeamCalendar(id: Long?, title: String?, access: ACCESS? = null, externalSubscription: Boolean = false)
Direct construction with explicit property values.
constructor(teamCalDO: TeamCalDO, userId: Long, teamCalCache: TeamCalCache)
Builds a TeamCalendar from a JPA entity. Resolves the user's access level by calling teamCalCache.teamCalRight.getAccessType(teamCalDO, userId) and mapping the DataobjectAccessType result to the ACCESS enum. Also reads externalSubscription from the entity.
| Constant | Value | Purpose |
|---|---|---|
BIRTHDAYS_FAVS_CAL_ID | -2L | ID for the "favorite peoples' birthdays" pseudo-calendar |
BIRTHDAYS_ALL_CAL_ID | -3L | ID for the "all peoples' birthdays" pseudo-calendar |
fun createFavoritesBirthdaysPseudoCalendar(): TeamCalendar
Returns a TeamCalendar with ID -2, localized title "calendar.birthdays.favorites", and ACCESS.READ.
fun createAllBirthdaysPseudoCalendar(): TeamCalendar
Returns a TeamCalendar with ID -3, localized title "calendar.birthdays.all", and ACCESS.READ.
TeamCalendar is the base class for StyledTeamCalendar (#861), which adds CalendarStyle and a visible flag. This separation follows the decorator pattern: TeamCalendar holds core data and access logic, while StyledTeamCalendar adds UI rendering metadata.
868d6abb7 2025 -> 2026 63081666f Source file headers: 2024-> 2025. 4c04cfd65 MAJOR-CHANGE! Migration of integer id's to Long id's (including fk's etc.) b6092df09 Copyright 2023 -> 2024 ab45d51fa Copyright 2001-2022 -> 2001-2023. 5f7ef41b8 Copyright 2021 -> 2022 ceb63e8a1 Source code header: (C) 2001-2021. 7c79f1922 Copyright of source header -> 2020. d3a178833 Wrong substitution of "calendar" -> "datetime" while refactoring, reverted commit from 12.12.2019. 5dc55cb4a WIP: Calendar: selection of showing timesheets/select timesheet user (dependend on user's role). b05d8a8be WIP: Calendar: styles and birthdays. f1d5f2915 Addressbooks and calendars: BaseUserGroupRight introduced and optimized. f4aee80f0 WIP: CalendarFilter: access to calendars fixed. 05244ff19 CopyRight of all Kotlin file-header updated or created. 46f71e71a WIP CalendarFilter: moved to business module. bd3a3e824 Module projectforge-jax-rs renamed to projectforge-rest. d27ecfa74 WIP: CalendarFilter... 7b2661bfc WIP: Calendars, calendars, calendars and colors...