Commit graph

843 commits

Author SHA1 Message Date
DEls
29135bdc57 fix(mcp): post_delivery refreshes a stale preview after other receipts on the PO
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 12:45:24 +02:00
DEls
35c18c32a3 docs: Stage 3a plan (stale preview refresh, MCP job drain, site question through regroup)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 12:42:40 +02:00
DEls
7b23d23ed7 feat(dn): Waiting for site column on the delivery-note inbox
Documents with an open site question move out of Identify/Match into
their own column, and each card shows the question itself in an amber
box instead of a generic badge, so the site sees what it has to answer
without opening the slip.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 12:07:49 +02:00
DEls
e97bf93c7d chore: add foreman scheduler mod; keep it out of the app type-check
foreman/ is a Claude Code mod (job runner + hooks) that imports the
claude-code runtime types, so tsc over the app failed on it. Excluding
it from tsconfig keeps the Next build green.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 12:05:50 +02:00
DEls
3cd4101ca6 fix(dn): show an open site question as the headline in Needs attention
The inbox list took its reason from documentProgress, which listed the
model's old identity doubts ("Is MEGCPO9376 correct?", "No matching PO
found") ahead of the question an agent asked the site. While a site
question is open it is now the only reason, labelled 'Waiting for site'
with the action 'Answer the site question'; once answered the normal
reasons return.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 11:54:54 +02:00
DEls
9a6aed50a4 feat(management): add admin planning dashboards
Add turnover, project, retention, and year comparison pages from the supplied workbook, protected by named admin access. Include the local chart gallery, grouped monthly hover, smooth comparison toggle, and monthly income minus cost series.

Require named PocketBase sign-in in every environment and remove the shared PIN bypass. Update access documentation and business-route test fixtures.
2026-10-09 10:16:50 +02:00
DEls
46452ce48f fix(mcp): include payload_hash in post_delivery's journal row
PocketBase requires it on mcp_operations; the in-memory test database
did not, so post_delivery failed on live data with 'Failed to create record'.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 07:37:29 +02:00
DEls
6999c0a6dc fix(mcp): load page collection fields so move_to_purchase_orders can fetch the photo
The page was read with a fields list that dropped collectionId and
collectionName, so the PocketBase file URL came back empty on live data
(tests stubbed the URL helper). Found in the acceptance run on PO 9412.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 07:36:06 +02:00
DEls
f0101cf736 feat(dn): answer site-decision questions on the slip page
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 07:06:09 +02:00
DEls
2f45986fbb fix(dn): keep an open site question through a pipeline re-run
A re-run replaced the candidate's checks wholesale, which would drop the
agent's question and could mark the slip ready to post unanswered.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 07:02:48 +02:00
DEls
9a6db8049f feat(dn): agents can ask the site a question about a delivery document
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 07:00:02 +02:00
DEls
4a8edf1f7e docs(dn): site-decision implementation plan
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 06:57:29 +02:00
DEls
01239c6633 fix(dn): drag to pan a zoomed page in Check page grouping
The grouping preview zoomed by widening the image inside a scroll box with
no way to move it on a Mac (hidden horizontal scrollbar). Adds a shared
mouse drag-to-pan hook, a grab cursor and a one-line hint.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 06:40:49 +02:00
DEls
1ef172c98a feat(mcp): address delivery lines by source line, not index
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:41:35 +02:00
DEls
b77aa7c6f8 perf(mcp): fetch only open delivery documents for the inbox board
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:40:22 +02:00
DEls
b0ecfbca10 feat(mcp): compact delivery inbox board for agents
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 02:39:38 +02:00
DEls
1da203553c fix(mcp): validate move_to_purchase_orders dates like create_purchase_order
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:38:10 +02:00
DEls
acf7260b0d feat(mcp): move misfiled PO photos into purchase orders
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 02:37:14 +02:00
DEls
a2a7e0fd0d fix(mcp): keep edit_document corrections across pipeline re-runs
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 02:35:00 +02:00
DEls
d681cfbe68 feat(mcp): edit delivery document identity, supplier and site
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 02:32:48 +02:00
DEls
6e5aa8cf10 feat(mcp): set delivery documents aside and restore them
Co-Authored-By: MiniMax Code <noreply@minimax.io>
2026-10-09 02:28:05 +02:00
DEls
e3b285cd17 feat(mcp): post a whole delivery slip in one call
Agents plan slip lines (not shifting indexes), may group lines into one
kit allocation, and NIL lines close automatically. Commits line by line
under the inbox's PO and batch leases; journaled and resumable.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:25:06 +02:00
DEls
86abe6b1db docs(dn): stage 2 implementation plan
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:21:41 +02:00
DEls
62bd5af576 docs(dn): stage 1 implementation plan
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:01:47 +02:00
DEls
6c6f767cfb fix(dn): stop blocking second deliveries that share a supplier order number
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 02:01:36 +02:00
DEls
8e01f0172c feat(dn): decide receipt identity by primary document numbers
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 01:59:52 +02:00
DEls
db75a8fe0b fix(mcp): return and journal the real purchasing error with a hint
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 01:59:21 +02:00
DEls
ab61182ced docs(dn): Avidan matching study and agent tools design
Study of 18 Avidan delivery documents matched by hand against their POs,
with root causes for why nearly every slip is flagged. Design for giving
agents full delivery-note tooling (everything except delete), staged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 01:55:21 +02:00
DEls
cb463c0faa feat(workforce): add timesheet exports and duplicate protection
Add per-site CSV and PDF matrix reports, editable sick-note date ranges, and weekend calendar styling. Preserve verified duplicate uploads for audit while excluding their entries from hours and costs, and prevent repeat files and overlapping daily imports.
2026-10-07 23:53:47 +02:00
DEls
a21c728d61 feat(workforce): add calendar and sick notes 2026-10-07 14:27:44 +02:00
DEls
f72397259c feat(auth): add Office access and restrict Clock users 2026-10-07 14:22:57 +02:00
DEls
8d53e3688c feat(workforce): add active and inactive workers 2026-10-07 13:41:05 +02:00
DEls
0df711875c feat(workforce): add rate history and missing-rate editor 2026-10-07 13:19:50 +02:00
DEls
5b141db5dd Merge remote purchasing MCP into main
# Conflicts:
#	docs/setup/api-and-mcp-connections.md
#	docs/setup/env-and-mcp.md
#	scripts/check-connections.mjs
2026-10-05 07:13:36 +02:00
DEls
29e20f3caf docs: record API and MCP connection audit 2026-10-05 07:13:23 +02:00
DEls
4922d649ae feat: add remote purchasing MCP to existing app 2026-10-05 02:46:36 +02:00
DEls
9f0698f1d1 feat: run durable MCP processing jobs in the existing app 2026-10-05 02:04:15 +02:00
DEls
4be0b2fa4e feat: expose matching and fenced receipt posting through MCP 2026-10-05 02:00:37 +02:00
DEls
f9a5ca80a7 feat: add immutable purchasing uploads and candidate edits 2026-10-05 01:55:31 +02:00
DEls
68e1c223a3 feat: share validated purchasing writes with MCP 2026-10-05 01:48:49 +02:00
DEls
cc8e2c8f01 feat: expose purchasing details and protected source documents 2026-10-05 01:42:27 +02:00
DEls
08becc6270 feat: journal MCP operations and fence purchasing writes 2026-10-05 01:38:15 +02:00
DEls
f9d3427767 feat: enforce MCP capabilities and no-delete policy 2026-10-05 01:33:37 +02:00
DEls
96da8ac4e8 feat: add authenticated same-app MCP transport 2026-10-05 01:31:17 +02:00
DEls
9c9a9d1866 docs: plan same-app remote purchasing MCP implementation 2026-10-05 01:22:08 +02:00
DEls
7ffe4eb94d docs: use existing app URL for remote MCP design 2026-10-05 01:16:34 +02:00
DEls
4970e61e70 docs: specify remote purchasing MCP service 2026-10-05 00:51:44 +02:00
DEls
6824d2c62e Add Workforce attention alerts and 24-hour correction times 2026-10-04 23:38:43 +02:00
DEls
ed69b517e8 Integrate agent work and add dashboard attention indicators
Remove repeated Plant, Financial and Workforce shortcut cards. Add site-scoped Plant and Financial sidebar attention status with automatic refresh.

Include accumulated delivery processing, purchase order recovery, supplier reconciliation, plant data and user management changes and audit records.
2026-10-04 21:53:32 +02:00
DEls
bcbd3167e4 feat(clock): unify scanners and document capture 2026-09-30 06:44:36 +02:00