From c453e50412169bd55dff75792646d662ffb652a8 Mon Sep 17 00:00:00 2001 From: "n.siegfried" Date: Sun, 16 Aug 2026 12:10:28 -0500 Subject: [PATCH] T5.6 - CR-002: Acumatica cost code and task, hidden by toggle The team concluded these two are noise on a field work package: cost codes are effectively constant on a job and the Acumatica task mapping is a PM concern. The cost visibility they actually want is by building and floor, which is CR-004 and CR-018. Hidden, not removed. CLAUDE.md: "Removed fields are hidden, not deleted (CR-002, CR-016). Retain the data and the model." So this is a second, narrower toggle list beside T5.5's sections - two fields inside General Information rather than two more sections, because a section is a block of the document and these are two rows in one. no migration the values live in the work package's JSON data blob, which nothing here writes to. The probe greps every migration for a drop_column touching either. no model change server/models.py is untouched by this task no code change to the toggles are SOP data. Another project turns them re-enable back on from step 12 and both fields return, values included A field is on only if its own toggle is on AND the section holding it is. Asked as one question (WPSections.fieldOn) so no caller has to remember to ask both - a field showing inside a hidden section is not a state worth reasoning about, and the probe checks that case explicitly. html/wp-sections.js FIELDS, fieldOn, normalizeFields html/work-package-suite-app.js field rows nested under their section html/work-package-suite-styles.css .field-toggle html/wp-creation-index.html ids on the two .field wrappers html/wp-creation-app.js WP_FIELD_NODES; both document rows conditional tests/sections_check.py +22 checks (53 -> 75) Done when [x] neither field appears in the form, detail view or PDF export when off [x] existing records still hold their values - a package EDITED while both are off comes back through collectPackage() with both intact [x] the fields can be re-enabled for another SOP without a code change [x] no schema migration drops data - checked against every migration in the tree, not just the ones this wave added The whole .field wrapper is hidden, not the input: a bare label over nothing is worse than either state. Raised, not fixed BL-019 A cost code that has left COST_CODES is silently blanked on edit. wp_cost is a ` built from the hardcoded `COST_CODES` array, and + `loadPackageIntoForm` sets `.value` from the saved package. Setting `.value` to something + with no matching `