Initial PrintOps branding#1
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 686a4e16c0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| const { data: spools = [] } = useQuery({ | ||
| queryKey: ['warehouse', 'spools', false], | ||
| queryFn: () => api.getSpools(false), |
There was a problem hiding this comment.
Honor Spoolman inventory in warehouse metrics
When Spoolman is enabled, the inventory route switches to api.getSpoolmanInventorySpools(...) (checked frontend/src/pages/InventoryPage.tsx around InventoryPageRouter and the spools query), but this new warehouse overview always calls the local /inventory/spools API. In Spoolman-backed installs the active/low-stock/remaining cards will show the local shadow data or zeroes instead of the inventory users see under /warehouse/filament, so the overview can be materially wrong until it uses the same Spoolman mode selection.
Useful? React with 👍 / 👎.
| const activeSpools = spools.filter((spool) => !spool.archived_at); | ||
| const lowStockSpools = activeSpools.filter((spool) => { | ||
| const remaining = Math.max(0, spool.label_weight - spool.weight_used); | ||
| return spool.label_weight > 0 && remaining / spool.label_weight <= 0.2; |
There was a problem hiding this comment.
Use configured low-stock thresholds
For local-inventory installs that have changed the global low-stock threshold or set low_stock_threshold_pct on individual spools, this hard-coded 20% test makes the Warehouse card disagree with the Inventory page, which computes low stock from settings.low_stock_threshold plus the per-spool override. The overview can therefore under- or over-report low stock until it reuses the same threshold logic.
Useful? React with 👍 / 👎.
Summary
Validation
npm.cmd run buildnpm.cmd run test -- --run src/__tests__/components/Layout.test.tsx src/__tests__/pages/LoginPage.test.tsx src/__tests__/pages/StreamOverlayPage.test.tsxnpm.cmd run check:i18npython -m py_compile backend\app\core\config.py backend\app\main.py backend\app\services\bug_report.pyNotes
The local
gh auth statusstill reports an invalid token forichwars, but the Git push succeeded through Windows credentials outside the sandbox.