#984: SearchFilterWithPeriodOfPerformance.kt
projectforge-business/src/main/kotlin/org/projectforge/business/fibu/SearchFilterWithPeriodOfPerformance.kt Kotlin interface — mixin contract for search filters that support date-range filtering by period of performance. Source: projectforge-business/src/main/kotlin/org/projectforge/business/fibu/SearchFilterWithPeriodOfPerformance.kt 32 lines · 6 code · 22 comments · 4 blank
Adds periodOfPerformanceStartDate / periodOfPerformanceEndDate properties to any search filter. Used by invoice and order filters to narrow queries to a specific service delivery window — distinct from invoice date or order date. The interface was extracted from duplicated code across multiple filter classes (PROJECTFORGE-3069).
Architecture
This is a mixin interface in the Kotlin style — two read-only properties with no implementation. Filter classes that need period-of-performance range filtering simply implement this interface alongside their existing filter interface. The consuming code (typically REST endpoints or DAO select() methods) checks if (filter is SearchFilterWithPeriodOfPerformance) and applies the date constraints.
Period of performance is distinct from other date concepts:
• Invoice date: when the invoice was issued
• Order date: when the order was placed
• Period of performance: when the actual work was performed (matters for cost accounting and revenue recognition)
Git History
868d6abb7 2025 → 2026
63081666f 2024→2025
b6092df09 2023→2024
5f7ef41b8 2021→2022
a6a7aece4 Optimize Imports
78b436d9e java.util.Date → java.time.LocalDate
7c79f1922 2020
c613e10b8 PROJECTFORGE-3069 cleanup SearchFilterWithPeriodOfPerformance interface
2965c2d8c PROJECTFORGE-3069 remove duplicated code
Key Commits
2965c2d8c / c613e10b8 — PROJECTFORGE-3069: This interface was created by extracting duplicated periodOfPerformanceStartDate/periodOfPerformanceEndDate fields that existed identically in AuftragFilter, RechnungFilter, EingangsrechnungFilter, and other FIBU filter classes. Before extraction, each filter class had copy-pasted date fields — the interface DRY'd them into a single contract.
78b436d9e — java.util.Date → LocalDate: The date types were migrated from legacy java.util.Date to java.time.LocalDate, part of the system-wide Java Time API migration.
| Implementing classes | Module |
|---|
AuftragFilter | fibu — order search |
RechnungFilter | fibu — outgoing invoice search |
EingangsrechnungFilter | fibu — incoming invoice search |
KostZuweisungFilter | fibu/kost — cost assignment search |