Commit Graph
229 Commits
Author SHA1 Message Date
ajandClaude Sonnet 5 ec16dd2c9b fix: polish unified add-stock modal (Edit.razor)
Build CutList image / build-and-push (push) Successful in 24s
Apply four low-risk fixes from final code review of the consolidated
add-stock modal: reset newStock on modal close, dedupe stock-item
loading through the existing helper, correct stale empty-state copy
about inventory fallback, and remove a stray blank line left from the
old form deletion.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-01 19:32:51 -04:00
ajandClaude Sonnet 5 0c5ecf716a fix: prefill Stock Length dropdown when editing inventory-sourced stock
Editing an inventory-sourced job stock row opened the Edit Stock modal
with the Stock Length dropdown blank instead of showing the row's
current length. EditStock() correctly set newStock.StockItemId from
the row, but then called the fire-and-forget OnStockMaterialChanged(),
which (a) unconditionally reset StockItemId to null, and (b) never
triggered a re-render since its Task wasn't awaited by the event
handler pipeline. Made EditStock async and await a dedicated loader
that populates availableStockItems without touching StockItemId, so
Blazor re-renders once the candidate lengths arrive.

Found during Task 2 manual verification of the unified Add Stock
modal (Step 6).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-01 19:23:49 -04:00
aj c66099481b docs: add implementation plan for unified add/edit stock modal 2026-08-01 19:08:28 -04:00
aj 9020ba80c1 feat: unify add/edit stock UI into a single modal on Job Edit page
Replaces the three separate surfaces (bulk import modal, inline custom-length
form, inline edit forms) with one "Add Stock" button and modal that handles
both add and edit, for both inventory-sourced and custom-length stock.
2026-08-01 19:02:27 -04:00
aj 2cb9c5ec8d docs: add design spec for unified add/edit stock modal
Job Edit page's Stock tab currently has three inconsistent entry points
(bulk import modal, inline custom-length form, inline edit forms) for
what should be a single add/edit stock flow.
2026-08-01 17:52:49 -04:00
ajandClaude Sonnet 5 232b86f15b docs: add implementation plan for removing inventory quantity tracking
Companion to the design spec, kept for reference alongside the executed work.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-01 11:44:50 -04:00
aj ec52834cd4 fix: correct stale min attribute and MCP wording from inventory removal
Build CutList image / build-and-push (push) Successful in 23s
Three small leftovers from Task 7 / the inventory-quantity-tracking
removal that a final review caught:

- Edit.razor's custom-stock quantity input still had min="1" even
  though its own helper text says "Use -1 for unlimited", validation
  already accepts -1, and the add-form defaults Quantity to -1 - so
  the field rendered pre-populated with a value the browser's native
  min validation flagged as invalid. Matches the min="-1" fix already
  applied to the catalog-stock input in Task 7.
- optimize_job's MCP tool description still claimed the optimizer
  falls back to "available inventory" when no stock is configured -
  that auto-discovery fallback was removed in Task 3. An LLM reads
  this description as ground truth, so stale wording here actively
  misleads tool use. Also tightened add_job_stock's stockItemId/
  isCustomLength wording, which still said "inventory" for what is
  now just the stock catalog.
- CLAUDE.md's CutListPackingService summary said InStockBins comes
  "from inventory", nudging future readers back toward the
  auto-discovery mental model this plan removed.
2026-08-01 11:39:35 -04:00
aj d8656cc454 fix: classify unlimited catalog-sourced job stock as in-stock
Task 7 extended JobStock.Quantity = -1 (unlimited) to catalog-sourced
rows, but the post-pack classification step in CutListPackingService
only ever treated a catalog-sourced bin as "in stock" when its tracked
quantity was a positive finite number. An unlimited catalog row fell
through to "to be purchased" even though IsInStock=true just means the
bin is catalog-sourced, not a quantity check.

This made the classification effectively unreachable for the most
common path users take to stock a job: the "Import from Inventory"
modal defaults every candidate's quantity to -1, so every resulting
bin was mislabeled "to be purchased" on the Results tab, and the
"everything is available in stock" message could never appear for
jobs stocked that way.

Track unlimited catalog-sourced lengths in a separate set and check it
first; finite catalog quantities keep the existing decrementing-counter
behavior, and custom-length stock (any quantity) is unaffected.
2026-08-01 11:39:28 -04:00
aj 0333942cb3 docs: update CLAUDE.md for inventory quantity tracking removal 2026-08-01 11:26:04 -04:00
aj 49a539d7e5 feat: allow unlimited quantity for catalog-sourced job stock
Custom-length job stock already supported -1 (unlimited); catalog-
sourced stock only allowed >= 1. Closes that inconsistency per
docs/superpowers/specs/2026-08-01-remove-inventory-quantity-tracking-design.md.
Also updates the Results tab's unplaced-items message now that
insufficient configured quantity is a normal cause, not an edge case.
2026-08-01 11:12:12 -04:00
aj 6bdbdf4969 feat: drop QuantityOnHand column and StockTransactions table
Final step of removing inventory quantity tracking - see
docs/superpowers/specs/2026-08-01-remove-inventory-quantity-tracking-design.md.
Destructive to any existing on-hand/transaction data; confirmed
acceptable since nothing read it automatically.
2026-08-01 11:04:11 -04:00
aj 383fa19cf2 refactor: drop QuantityOnHand from CutList.Mcp inventory tools
Matches the REST API's StockItemDto/CreateStockItemDto shape after
inventory quantity tracking removal. Republished to
~/.claude/mcp/CutList.Mcp/.
2026-08-01 10:56:17 -04:00
aj 843ba24788 refactor: drop QuantityOnHand from catalog import/export
Part of removing inventory quantity tracking; existing seed JSON keeps
the field on disk but it's now ignored on import.
2026-08-01 10:53:09 -04:00
aj 41283987b9 refactor: remove packing auto-discovery fallback
The fallback silently pulled from StockItem.QuantityOnHand and always
added an extra unlimited bin on top when a job had no stock configured
- i.e. it assumed unlimited purchasing. Per
docs/superpowers/specs/2026-08-01-remove-inventory-quantity-tracking-design.md,
a job's available stock must now be exactly what's explicitly entered.
2026-08-01 10:48:56 -04:00
aj 41dda11062 refactor: remove stock-transaction service methods, endpoints, and DTOs
No job workflow ever called these (receive/use/adjust/scrap/recalculate)
- inventory quantity tracking is being removed per
docs/superpowers/specs/2026-08-01-remove-inventory-quantity-tracking-design.md.
2026-08-01 10:43:01 -04:00
aj f71cf8ab0a fix: remove debug TEST123 text from Stock Items heading 2026-08-01 10:37:00 -04:00
aj fd6e8d632c refactor: remove QuantityOnHand display from stock and job UI
First step of removing inventory quantity tracking (see
docs/superpowers/specs/2026-08-01-remove-inventory-quantity-tracking-design.md).
UI no longer shows on-hand counts or offers transaction entry; the
underlying field/service methods are removed in follow-up commits.
2026-08-01 10:32:12 -04:00
ajandClaude Sonnet 5 69c993fcb2 docs: add design spec for removing inventory quantity tracking
Users need to enter parts/stock and get results without a disconnected
inventory system to manage; StockItem.QuantityOnHand and StockTransaction
today aren't read or written by the job workflow anywhere except an
auto-discovery fallback that silently assumes unlimited purchasing.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-01 10:12:56 -04:00
aj 7b210f518b docs: remove last stale StockItemService pricing reference; ignore playwright-mcp logs
Build CutList image / build-and-push (push) Successful in 1m11s
CLAUDE.md still listed GetAverageCostAsync/GetLastPurchasePriceAsync, which
Task 1 of the vendor-data removal already deleted. Also stop tracking the
Playwright MCP browser session logs left behind by Task 10's smoke test.
2026-08-01 09:33:53 -04:00
aj 3244e15593 fix: address final review findings in vendor-data removal (catalog save, job locking, DB collision, docs) 2026-08-01 09:32:16 -04:00
aj b77d0d971d feat: remove supplier MCP tools, add plain add_stock convenience tool 2026-08-01 08:55:49 -04:00
aj f75c205bc5 chore: strip vendor data from oneals-catalog.json seed file 2026-08-01 08:52:25 -04:00
aj 1b4d5f76a8 feat: remove Supplier/SupplierOffering/PurchaseItem entities and migrate schema 2026-08-01 08:49:05 -04:00
ajandClaude Sonnet 5 41944638c6 feat: drop supplier import/export from the catalog format
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-01 08:45:21 -04:00
aj 063c844310 feat: delete SupplierService, PurchaseItemService, and their API surface 2026-08-01 08:41:28 -04:00
aj 597181bd78 feat: replace Add to Order List with a direct Lock Job action 2026-08-01 08:38:20 -04:00
aj 8d6ada35e5 feat: remove Suppliers and Orders pages and nav entries 2026-08-01 08:34:47 -04:00
aj b51d936b78 fix: make stock item length editable and drop vendor UI from Stock Edit page 2026-08-01 08:31:40 -04:00
aj e7248be9a4 refactor: strip supplier/pricing from StockItemService and stock-items API 2026-08-01 08:27:55 -04:00
aj 06f0c2032d chore: ignore .superpowers/ SDD scratch workspace directory
Keeps subagent-driven-development's per-plan ledger/briefs/reports out
of version control.
2026-08-01 08:24:47 -04:00
aj 9296bea0bc docs: add implementation plan for removing vendor/supplier data
Ten-task plan ordered so the build stays green at each step: strip
consumers first (StockItemService/DTOs/Controller, Stock/Edit.razor,
Suppliers/Orders pages, Jobs/Edit.razor, CatalogService), delete the
now-unused services, then remove the entities and migrate the schema
last. Closes with CutList.Mcp cleanup and a manual smoke test.
2026-07-31 22:56:41 -04:00
aj 4e874df22f docs: add design spec for removing vendor/supplier data from CutList
Scopes out Supplier, SupplierOffering, PurchaseItem, and cost tracking
as out-of-scope for a 1D nesting optimizer, while fixing the actual
reported bug (read-only stock length field) and keeping a stripped
quantity-only transaction log.
2026-07-31 22:44:13 -04:00
ajandClaude Sonnet 5 7574476d7f feat: add Docker deployment for CutList.Web and update CLAUDE.md docs
Adds a Dockerfile and Gitea Actions workflow to build/push the
CutList.Web image to the registry on push to master, enabling
containerized deployment to forge. Also updates CLAUDE.md to reflect
the CutList.Mcp project, REST API surface, and CatalogService, and
tweaks the cut-length badge styling in the job editor.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-31 18:50:06 -04:00
ajandClaude Opus 4.6 48b8936266 feat: remove source column from cut list and increase cut length text size
Drop the Stock/Purchase source badge column from the results cut list
table (purchase list card remains). Bump cut length badges to fs-6 for
better readability.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 14:08:26 -04:00
ajandClaude Opus 4.6 700aa726fc fix: update MCP server base URL to port 5270 and suppress logging
Point API client at the deployed service port and clear logging
providers to prevent interference with MCP stdio transport.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 14:04:32 -04:00
ajandClaude Opus 4.6 2f2b9f71e1 feat: show inches value alongside formatted length in job editor
Display raw inches in parentheses next to the architectural format
in both Parts and Stock tables for easier reference.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 14:04:31 -04:00
ajandClaude Opus 4.6 65e0247a7d chore: default OpenFirewall to true in deploy script
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 13:48:41 -04:00
ajandClaude Opus 4.6 545678c30f feat: add error handling to job editor and Error page
Wrap job editor initialization in try/catch to display errors instead of
crashing the circuit. Make LoadSavedResults async. Add a simple Error
page for the production exception handler.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 13:48:36 -04:00
ajandClaude Opus 4.6 b5bef23c1d refactor: migrate to IDbContextFactory and Windows Service hosting
Replace AddDbContext with AddDbContextFactory for Blazor Server circuit
safety — each service method now creates a short-lived DbContext via the
factory. Configure Windows Service hosting with ContentRootPath and
remove HSTS/HTTPS redirect for reverse-proxy deployment.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 13:48:30 -04:00
ajandClaude Opus 4.6 f66fd3eaa7 chore: upgrade solution from .NET 8 to .NET 10
Update all project TFMs to net10.0, EF Core to 10.0.4, add
Microsoft.Extensions.Hosting.WindowsServices, and suppress WFO1000
warning for WinForms project.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 13:48:23 -04:00
ajandClaude Opus 4.6 7d3c92226c refactor: replace generic catalog DTOs with shape-typed DTOs for type safety
Replace the single CatalogMaterialDto + CatalogDimensionsDto (bag of nullable
fields) with per-shape DTOs that have strongly-typed dimension properties.
Catalog JSON now groups materials by shape key instead of a flat array.
Delete the old SeedController/SeedDataDtos (superseded by CatalogService).
Scraper updated to emit the new grouped format, resume by default, and
save items incrementally.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-25 15:48:35 -05:00
ajandClaude Opus 4.6 c31769a746 chore: standardize deploy script to match template
Remove unused $PublishTimeoutSeconds param. Add sc.exe description for
service metadata.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-23 08:14:29 -05:00
ajandClaude Opus 4.6 f04bf02c42 feat: Migrate MaterialDimensions from TPH to TPC and add Alro catalog seeding
Switch MaterialDimensions inheritance from TPH (single table with discriminator)
to TPC (table per concrete type) with individual tables per shape. Add Swagger
for dev API exploration, expand SeedController with export/import endpoints and
Alro catalog JSON dataset, and include Python scraper for Alro catalog PDFs.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 14:23:01 -05:00
ajandClaude Opus 4.6 dac2833dd1 chore: Remove ExportData script
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 01:01:22 -05:00
ajandClaude Opus 4.6 a226a1f652 feat: Redesign job editor with multi-row parts and unified cut list results
- Part form now supports adding multiple parts at once via a table with
  add/remove row controls; edit mode stays single-row
- Shape and size dropdowns lock when editing an existing part
- Results tab replaces split in-stock/purchase cards with a unified table
  per material showing source badges (Stock/Purchase) for each bar
- New Purchase List card summarizes materials to order with quantities
- Print styles use repeating thead headers per material for multi-page
  cut lists; large cards can now break across pages

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 01:01:01 -05:00
ajandClaude Opus 4.6 5000021193 feat: Add catalog import/export API endpoints
Replace the standalone ExportData console app and hardcoded SeedController
with generic GET /api/catalog/export and POST /api/catalog/import endpoints.
Import uses upsert semantics with per-item error handling, preserving
existing inventory quantities.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 00:09:53 -05:00
ajandClaude Opus 4.6 02e936febb feat: Add database export script and O'Neal Steel catalog dataset
Export tool queries all active materials, stock items, suppliers, and
offerings from the database and writes a clean JSON file for version
control. Includes 616 materials and 810 stock items with part numbers.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 22:34:35 -05:00
ajandClaude Opus 4.6 e13f876da6 feat: Add MCP tools for job management and optimization
Add JobTools class exposing MCP tools for:
- Job CRUD (list, get, create, update, delete)
- Part management (add single, batch add, delete)
- Stock assignments (add, delete)
- Bin packing optimization with kerf override
- Cutting tool listing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 22:20:59 -05:00
ajandClaude Opus 4.6 1f3eb67eb7 feat: Add job and cutting tool API client methods
Add HTTP client methods for job CRUD, parts, stock, packing, and
cutting tool endpoints. Includes response DTOs for all job-related
API responses.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 22:20:53 -05:00
ajandClaude Opus 4.6 2fdf006a8e docs: Update CLAUDE.md with optimization persistence and Results tab
Document new Job entity fields, serialization DTOs, JobService
optimization methods, and merged Results tab in Edit page.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 22:13:12 -05:00