Stock is scoped to a catalog + cost centers only, per direction that physical GRV/stock-take/recipe transactions belong in an external system (Matrix), not this accounting app. Stock Control/GRN/Variance/ PPV GL accounts are now plain postable accounts rather than locked control accounts. Also fixes session loss on page refresh: auth stores now persist to localStorage, and ProtectedRoute waits for rehydration before deciding to redirect to login. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JWqiUSojMLUoN7mrJqdEbN
2.6 KiB
2.6 KiB
Phase 4 — Stock Simplification + Session Persistence: Manual Test Checklist
This replaces the earlier version of this checklist. On review, the full transactional Stock module (GRV, Stock Takes, Recipe production) was removed — this is accounting software, not a stock/warehouse system, and those physical stock transactions belong in an external system (Matrix) instead. What remains: a Stock Item catalog, Warehouses as cost centers, and a Stock-on-Hand view that a future external feed will populate (currently empty — nothing in this app writes to it). This checklist also covers the session-persistence fix.
1. Session persistence (the "logged out on refresh" fix)
- Sign in through the Manager, land in the company app
- Refresh the browser tab (F5) — you should stay logged in, not bounce back to the Manager
- Close the browser tab entirely and reopen
http://localhost:5173— you should still be signed in - Sign out — refreshing afterward should correctly show you signed out (not silently restore the old session)
- Same checks on the Manager itself (
http://localhost:5174): refresh keeps you logged in, sign out actually signs out
2. Simplified Stock module
- Sidebar's Stock section now shows only Stock Items (Recipes, Goods Received, Stock Takes are gone)
- Administration still has Warehouses
- "New Stock Item" only asks for code, name, and unit of measure — no costing method
- "New Warehouse" is unchanged (code, name, branch)
- Stock Items page still has an "Items" tab and a "Stock Levels" tab; the Stock Levels tab shows a note that quantities come from an external system, and the grid is empty (that's expected — nothing populates it yet)
- No "Match to GRV" button appears anywhere on a supplier's page
- AP invoice lines only ever offer a plain expense account — no GRV-matching option
GET /api/stock/grv,/api/stock/adjustments,/api/stock/recipesall now 404 (removed)
3. Regression: everything else unaffected
- GL, AR, and AP all work exactly as before — Stock Control, Stock Variance, and the account previously called "Goods Received Not Invoiced" / "Purchase Price Variance" are now plain, normal GL accounts (no longer locked as control accounts), so they can be posted to like any other account via a manual journal entry if you want to record a stock-value adjustment by hand
- The manual-journal control-account lockout still correctly blocks direct postings to AR Control, AP Control, Tax accounts, and Bank accounts