Custom Fields feature is entirely disconnected from ticket creation/editing/viewing #47

Open
opened 2026-08-31 21:36:16 -04:00 by jared · 0 comments
Owner

Severity: High (functional gap)

CustomFieldModel::setValue()/setValues()/getValuesForTicket() (models/CustomFieldModel.php ~lines 214-250) are never called anywhere outside api/custom_fields.php itself (confirmed via repo-wide grep). views/CreateTicketView.php never renders custom fields, controllers/TicketController.php::create() never collects or saves them, and views/TicketView.php never displays them.

Impact: An admin can define fields at /admin/custom-fields, including marking them "Required," but they never appear on the ticket creation/edit form, are never persisted anywhere, and is_required is enforced nowhere. The entire feature documented in README.md ("Per-Category Fields," "Required Fields: Mark fields as required for validation") is admin-config-only with no consumer — it currently does nothing from an end-user perspective.

Fix: Wire custom field rendering into CreateTicketView.php/TicketView.php (category-scoped, per the admin config) and persist submitted values via CustomFieldModel::setValues() on ticket create/update, enforcing is_required server-side.

**Severity:** High (functional gap) `CustomFieldModel::setValue()/setValues()/getValuesForTicket()` (models/CustomFieldModel.php ~lines 214-250) are never called anywhere outside `api/custom_fields.php` itself (confirmed via repo-wide grep). `views/CreateTicketView.php` never renders custom fields, `controllers/TicketController.php::create()` never collects or saves them, and `views/TicketView.php` never displays them. **Impact:** An admin can define fields at `/admin/custom-fields`, including marking them "Required," but they never appear on the ticket creation/edit form, are never persisted anywhere, and `is_required` is enforced nowhere. The entire feature documented in README.md ("Per-Category Fields," "Required Fields: Mark fields as required for validation") is admin-config-only with no consumer — it currently does nothing from an end-user perspective. **Fix:** Wire custom field rendering into `CreateTicketView.php`/`TicketView.php` (category-scoped, per the admin config) and persist submitted values via `CustomFieldModel::setValues()` on ticket create/update, enforcing `is_required` server-side.
jared added the priority/highux labels 2026-09-08 10:15:45 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: LotusGuild/tinker_tickets#47