Review Bufdir category mapping for activity types
The bufdir-report-structure-mapper translates internal activity type IDs into the official Bufdir category taxonomy. The preview screen exposes this mapping so coordinators are not left guessing how their data was categorized. Within the preview, a mapping summary section shows each internal activity type alongside its Bufdir category equivalent and the count of activities mapped. If any activity type could not be mapped (unknown mapping), it appears in a separate 'unmapped activities' section that feeds into the validation summary. This transparency is critical for organizations like NHF and HLF that have complex activity type hierarchies.
User Story
Acceptance Criteria
- Given the preview screen is open, When I navigate to the 'Category Mapping' section, Then I see a list of all internal activity types used in the reporting period alongside their resolved Bufdir category names
- Given I am reviewing category mappings, When an activity type has no Bufdir category mapping configured, Then it appears in a highlighted 'Unmapped' section and is counted as a blocking validation error
- Given all activity types are mapped, When I tap on a specific mapping row, Then I see the count of activities of that type in the selected period and their contribution to the Bufdir category total
- Given the mapping is correct, When I view the main report preview sections, Then the aggregated values match the sum of activities per Bufdir category shown in the mapping view
- Given I am a coordinator for an organization with custom activity type labels, When I view the mapping, Then I see my organization's terminology (via org-labels-provider) alongside the canonical Bufdir category name
- Given I navigate away from and return to the mapping section, When the screen reloads, Then the mapping data is cached and loads instantly without re-fetching
Business Value
Bufdir's reporting taxonomy does not always align intuitively with how peer-mentor organizations categorize their activities internally. Exposing the mapping in the preview prevents the common scenario where coordinators submit reports only to discover later that activities were incorrectly categorized, requiring amended submissions and creating friction with the funder.
Components
- Bufdir Report Structure Mapper service
- Bufdir Report Preview Screen ui
- Bufdir Report Section Widget ui
- Bufdir Preview Service service
- Validation Summary Banner ui
- Organization Labels Provider infrastructure
- Activity Category Mapping Configuration infrastructure