Add comprehensive admin-only UI for managing award definitions stored as JSON files. Backend changes: - Add awards-admin.service.js with file operations and validation - Add clearAwardCache() function to invalidate in-memory cache after changes - Add API routes: GET/POST/PUT/DELETE /api/admin/awards, POST /api/admin/awards/:id/test - Support testing unsaved awards by passing award definition directly Frontend changes: - Add awards list view at /admin/awards - Add create form at /admin/awards/create with safety checks for: - Impossible filter combinations (e.g., mode=CW AND mode=SSB) - Redundant filters and mode groups - Logical contradictions (e.g., satellite_only with HF-only bands) - Duplicate callsigns, empty mode groups, etc. - Add edit form at /admin/awards/[id] with same validation - Add FilterBuilder component for nested filter structures - Add TestAwardModal with deep validation and test calculation - Add Awards tab to admin dashboard Safety validation includes: - Schema validation (required fields, types, formats) - Business rule validation (valid rule types, operators, bands, modes) - Cross-field validation (filter contradictions, allowed_bands conflicts) - Edge case detection (complex filters, impossible targets) Co-Authored-By: Claude <noreply@anthropic.com>
25 lines
554 B
JSON
25 lines
554 B
JSON
{
|
|
"id": "qo100grids",
|
|
"name": "QO100 Grids",
|
|
"description": "Work as much Grids as possible on QO100 Satellite",
|
|
"caption": "Work as much Grids as possible on QO100 Satellite",
|
|
"category": "satellite",
|
|
"rules": {
|
|
"type": "entity",
|
|
"satellite_only": true,
|
|
"filters": {
|
|
"operator": "AND",
|
|
"filters": [
|
|
{
|
|
"field": "satName",
|
|
"operator": "eq",
|
|
"value": "QO-100"
|
|
}
|
|
]
|
|
},
|
|
"entityType": "grid",
|
|
"target": 100,
|
|
"displayField": "grid"
|
|
},
|
|
"modeGroups": {}
|
|
} |