ores.dq.badge_mapping
Table of Contents
Universal mapping table that associates any (code_domain, entity_code) pair with a badge definition. This is the single join point between domain values and their visual presentation.
Examples:
- ('party_status', 'ACTIVE') -> 'active'
- ('party_status', 'FROZEN') -> 'frozen'
- ('fsm_state', 'DRAFT') -> 'fsm_draft'
- ('login_status', 'Online') -> 'login_online'
- ('dq_nature', 'Actual') -> 'dq_actual'
Populated via seed scripts; no management UI needed.
The junction is on the canonical generated stack: its protocol, handler, registrar and service are generated from this model like any other junction's, so the mapping read cannot drift from the entity it projects.
1. Flags
2. Left
Code of the domain this mapping belongs to.
Mappings are read a code domain at a time: the badge lookup asks for one domain's rows and indexes them by entity code. The partial index on this column is the read's index.
References code_domain.code (soft FK). Examples: 'party_status', 'fsm_state'.
std::string(faker::word::noun()) + "_status"
3. Right
The domain value being mapped to a badge.
Examples: 'ACTIVE', 'DRAFT', 'Online', 'Actual'.
std::string(faker::word::adjective()).substr(0, 1)
4. Columns
4.1. badge_code
The badge definition to use for this mapping.
References badge_definition.code (soft FK). Examples: 'active', 'fsm_draft'.
std::string(faker::word::adjective())
5. SQL
5.1. Flags
6. Repository
7. C++
7.1. Flags
7.2. Domain includes
#include <string>
7.3. Entity includes
#include <string>
7.4. Conventions
7.5. Table display
| column | header |
|---|---|
| code_domain_code | Code Domain |
| entity_code | Entity Code |
| badge_code | Badge |
| modified_by | Modified By |
| version | Version |
8. See also
- ores.dq — component group overview.