fix: fix Arma 3 log discovery and improve config editor UX
- Fix logfiles_router and thread_registry to resolve .rpt log files from Path(server["exe_path"]).parent/server/ instead of the languard data dir, which never contained log files — log list and live tail both now work correctly - Rewrite get_ui_schema() in config_generator to cover all ~80 fields across all 5 sections (server/basic/profile/launch/rcon) with proper toggle/select/number/password/tag-list/hidden widgets and labels; missions field is hidden (managed by Missions tab) - Add formatSelectDisplay() to ConfigEditor so select fields show descriptive text (e.g. "0 - Never") instead of raw numbers in view mode - Add ToggleDisplay for boolean fields (Enabled/Disabled with indicator dot) - Add section tab labels and descriptions to ConfigEditor - Add MissionList UX hints and dynamic Add/In Rotation button labels - Add "hidden" to FieldSchema widget union type - Update API.md, ARCHITECTURE.md, CLAUDE.md, FRONTEND.md, MODULES.md, THREADING.md to document log path fix and schema coverage
This commit is contained in:
17
API.md
17
API.md
@@ -792,10 +792,20 @@ Get all config sections combined. Sensitive fields (passwords) are masked with `
|
||||
|
||||
### GET /servers/{server_id}/config/schema
|
||||
|
||||
Returns per-field widget hints for the frontend config editor. Used by `ConfigEditor` to render the correct UI widget (text box, toggle, select, tag list, etc.) for each field.
|
||||
Returns per-field widget hints for the frontend config editor. Used by `ConfigEditor` to render the correct UI widget for each field. Covers all ~80 Arma 3 config fields across 5 sections.
|
||||
|
||||
**Auth:** Required (any role)
|
||||
|
||||
**Widget types:**
|
||||
- `text` — Text input
|
||||
- `password` — Password input (masked)
|
||||
- `number` — Numeric input with optional `min`/`max`
|
||||
- `toggle` — Boolean toggle (0/1)
|
||||
- `select` — Dropdown with `options` array. Options may be `["value1", "value2"]` or `["0 - Never", "1 - Always"]` format
|
||||
- `textarea` — Multi-line text area
|
||||
- `tag-list` — Dynamic string list (add/remove items)
|
||||
- `hidden` — Field not displayed in UI (managed elsewhere; e.g., `missions` managed by Missions tab)
|
||||
|
||||
**Response 200:**
|
||||
|
||||
```json
|
||||
@@ -806,10 +816,11 @@ Returns per-field widget hints for the frontend config editor. Used by `ConfigEd
|
||||
"hostname": { "widget": "text", "label": "Server Hostname" },
|
||||
"max_players": { "widget": "number", "label": "Max Players", "min": 1, "max": 1000 },
|
||||
"password": { "widget": "password", "label": "Player Password" },
|
||||
"forced_difficulty": { "widget": "select", "label": "Difficulty Preset", "options": ["Recruit", "Regular", "Veteran", "Custom"] },
|
||||
"forced_difficulty": { "widget": "select", "label": "Difficulty Preset", "options": ["0 - Recruit", "1 - Regular", "2 - Veteran", "3 - Custom"] },
|
||||
"battleye": { "widget": "toggle", "label": "BattleEye Anti-Cheat" },
|
||||
"motd_lines": { "widget": "textarea", "label": "Message of the Day (one line per row)" },
|
||||
"admin_uids": { "widget": "tag-list", "label": "Admin Steam UIDs", "placeholder": "76561198000000000" }
|
||||
"admin_uids": { "widget": "tag-list", "label": "Admin Steam UIDs", "placeholder": "76561198000000000" },
|
||||
"missions": { "widget": "hidden", "label": "Missions" }
|
||||
},
|
||||
"rcon": {
|
||||
"rcon_password": { "widget": "password", "label": "RCon Password" }
|
||||
|
||||
Reference in New Issue
Block a user