From fc6cd6f04290c0382cb047d9fee8ab98f9a08aff Mon Sep 17 00:00:00 2001 From: "Aaron K. Clark" Date: Tue, 19 May 2026 07:31:19 -0500 Subject: [PATCH] =?UTF-8?q?docs(=5Fbulk-helpers):=20customer/bulk=20now=20?= =?UTF-8?q?uses=20the=20factory=20=E2=80=94=20drop=20stale=20"predates"=20?= =?UTF-8?q?callout?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The header JSDoc on \`_bulk-helpers.js\` said: "Customer's bulkCreate predates this helper and has the same shape baked in; we don't migrate it here to keep the diff focused on the new endpoints (P3-H), but a follow-up should consolidate them." That follow-up landed; \`customercontroller.js\` now exports \`bulkCreate = makeBulkCreate({ ... })\` like every other bulk-direct endpoint, and Customer is among the 6 entities the factory serves. The "5 near-identical controllers it replaces" line was also off by one for the same reason. Update both lines to match reality: 6 entities use the factory, Customer was migrated in a follow-up after the original P3-H rollout. Co-Authored-By: Claude Opus 4.7 (1M context) --- app/controllers/_bulk-helpers.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/app/controllers/_bulk-helpers.js b/app/controllers/_bulk-helpers.js index d6db1cd..9ede750 100644 --- a/app/controllers/_bulk-helpers.js +++ b/app/controllers/_bulk-helpers.js @@ -4,15 +4,15 @@ /** * Shared factory for bulk-create controllers on entities that scope - * directly to a single company via a *CompId column. Customer's - * bulkCreate predates this helper and has the same shape baked in; - * we don't migrate it here to keep the diff focused on the new - * endpoints (P3-H), but a follow-up should consolidate them. + * directly to a single company via a *CompId column. * - * What this factory replaces: 5 near-identical controllers - * (worker/billingtype/inventoryitem/inventorytransaction/ + * What this factory replaces: 6 near-identical controllers + * (customer/worker/billingtype/inventoryitem/inventorytransaction/ * purchaseordervendor) each repeating the same auth-scope-loop- - * transaction-bulkCreate-handle-error scaffold. + * transaction-bulkCreate-handle-error scaffold. Customer was the + * original hand-rolled implementation; the factory replaced 5 + * later-added clones in P3-H and Customer was migrated to use the + * factory in a follow-up. * * What varies between entities — passed as config: * - Model the sequelize model (db.Worker etc.)