Found in the first browser pass, on the Role catalog screen.
A catalog item created with form: 'standing' and no frequency renders as:
| Duty |
Form |
Frequency |
| Keep the chemical register current |
Standing |
Monthly |
frequency defaults to monthly on both duly_catalog_item and duly_duty, and the default applies regardless of form. A standing duty never dispatches — that is the whole point of the form — so a frequency on one is meaningless, and worse, it reads to a configurer as though the thing runs monthly.
The dispatcher is not affected: it skips form: 'standing' outright and #43's tests pin that. This is a data-integrity and comprehension defect, not a dispatch defect. But the person setting up a customer's catalog reads this screen, and it tells them something false.
Scope
Decide and implement one of:
- A — make
frequency conditional: no default when form is standing, and a validation rule refusing a frequency on a standing duty. Mirrors the existing recurring_needs_frequency rule, which already asserts the converse.
- B — leave the field but hide it in the UI for standing rows and exclude it from the catalog list view's columns.
A is the stronger answer — B leaves the wrong value in the data where an export, an import round-trip (#19) or an API consumer still sees it, and it is the data that is wrong, not the rendering. The object already carries recurring_needs_frequency; this is the missing other half of the same rule.
Apply to both duly_duty and duly_catalog_item — #5's instantiation copies cadence fields across, so a wrong value on the catalog side is replicated onto every duty made from it.
Same treatment worth checking for due_anchor, due_offset_days, lead_days and grace_days, which are equally meaningless on a standing duty and equally defaulted.
Found in the first browser pass, on the Role catalog screen.
A catalog item created with
form: 'standing'and no frequency renders as:frequencydefaults tomonthlyon bothduly_catalog_itemandduly_duty, and the default applies regardless ofform. A standing duty never dispatches — that is the whole point of the form — so a frequency on one is meaningless, and worse, it reads to a configurer as though the thing runs monthly.The dispatcher is not affected: it skips
form: 'standing'outright and #43's tests pin that. This is a data-integrity and comprehension defect, not a dispatch defect. But the person setting up a customer's catalog reads this screen, and it tells them something false.Scope
Decide and implement one of:
frequencyconditional: no default whenformisstanding, and a validation rule refusing a frequency on a standing duty. Mirrors the existingrecurring_needs_frequencyrule, which already asserts the converse.A is the stronger answer — B leaves the wrong value in the data where an export, an import round-trip (#19) or an API consumer still sees it, and it is the data that is wrong, not the rendering. The object already carries
recurring_needs_frequency; this is the missing other half of the same rule.Apply to both
duly_dutyandduly_catalog_item— #5's instantiation copies cadence fields across, so a wrong value on the catalog side is replicated onto every duty made from it.Same treatment worth checking for
due_anchor,due_offset_days,lead_daysandgrace_days, which are equally meaningless on a standing duty and equally defaulted.