2.9 KiB
Phase 12.2: Admin form fields: date, file upload, relation editing with deferred binding - Discussion Log
Audit trail only. Do not use as input to planning, research, or execution agents. Decisions are captured in CONTEXT.md — this log preserves the alternatives considered.
Date: 2026-10-02 Phase: 12.2-admin-form-fields-date-file-upload-relation-editing-with-def Areas discussed: Deferred binding mechanics, Fileupload contract, Relation child CRUD, Datepicker semantics
Deferred binding mechanics
| Question | Options | Selected |
|---|---|---|
| Storage | Winter's deferred_bindings (+ owner admin id) / Go-native table | Winter's deferred_bindings |
| Session key | SPA random key bound to admin / server-issued signed key / Winter-exact unbound | SPA random key, bound to admin |
| When defer | Winter split (uploads always deferred, relation changes only on unsaved) / unsaved only / always deferred | Winter split |
| Purge | River periodic + command, 5 days / command only | River periodic + command |
Fileupload contract
| Question | Options | Selected |
|---|---|---|
| Declare | Model interface AttachRelations() / typed struct fields |
Model interface |
| Helper | Public attach helper / cabana-private | Public attach helper |
| Keys | Practical set (mode, fileTypes, mimeTypes, maxFilesize, maxFiles, imageWidth/Height, thumbOptions, useCaption, prompt) / minimal | Practical set |
| Protected | Support public and protected / public only | Support both |
Relation child CRUD
| Question | Options | Selected |
|---|---|---|
| Child form | config_relation manage.form / related model's default fields.yaml |
manage.form |
| Buttons | Winter toolbarButtons (create, update, delete, link, unlink) / create-edit-delete only for hasMany | Winter toolbarButtons |
| Pivot | pivot.form support / related record only |
pivot.form support |
| Nesting | Full form with own session key / simple fields only | Full form, own session key |
Datepicker semantics
| Question | Options | Selected |
|---|---|---|
| Timezone | UTC store, browser tz edit / one backend.timezone config | UTC store, browser tz edit |
| Go types | time.Time + lagoon.Date / lagoon.TimeOfDay / time.Time for everything | time.Time + lagoon types |
| Keys | Practical set (mode, format, minDate, maxDate, yearRange, firstDay, twelveHour, ignoreTimezone) / minimal | Practical set |
| Picker UI | Reka UI DatePicker / native inputs | Reka UI DatePicker |
Todos
Matcher flagged four todos (benchmark, nest packages, admin API tokens, bonfire duplicate commands) on keyword overlap only. User chose to fold none.
Claude's Discretion
Route names, session-key transport, attach API shapes, thumb sizes, date/time list columns, purge config keys, plan split.
Deferred Ideas
Image cropping; nested relation manager in a child modal; migrating fonoteka.go uploads onto the new attach helper.