Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.
TypeScript ai-agentsbill-of-materialserpinventory-managementleanmanufacturingmanufacturing-execution-systemmcp-servermesmrpopen-source-erppostgresqlproduction-planningqmsquality-management-systemreact-routerself-hostedsupabasetraceabilitytypescript
Fixed asset cost adjustment (zero-cost capitalization)
A serialized unit made by a job with no production events or material issues, or issued into stock at no cost, carries 0 in inventory. Capitalizing it from stock is refused ("has no cost in inventory"), and Make to Asset creates the asset at 0 with nothing to correct it. Decisions (user, 2026-10-08):
- Offset account: user picks, defaults to Retained Earnings.
- Entry points: both — the capitalize form takes a cost when the unit carries none, and the asset page gets Adjust Cost.
- Direction: raise only.
- Depreciation: missed Straight Line months catch up in the next run.
Tasks
- Migration
20261008163615_fixed-asset-cost-adjustment.sql: enum valuesfixedAssetTransferType 'Cost Adjustment',fixedAssetTransferSourceType 'Manual';pnpm db:migrate+pnpm run generate:types. -
post-asset-transfer/validators.ts:capitalizegainscost?+offsetAccountId?; newadjustCostvariant; pure helpersresolveCapitalizationCost,statusAfterCostAdjustment; tests. -
post-asset-transfer/index.ts: entered cost on capitalize (only when the unit carries 0; Cr offset account);adjustCost(Active / Fully Depreciated; Dr class asset / Cr offset; Fully Depreciated → Active when NBV is above residual); DB tests. - Depreciation:
buildDepreciationLinesadds the Straight Line shortfall (book and tax) to the first month of an asset with a posted Cost Adjustment;buildDepreciationRunLinespasses the flag; utils tests. - ERP: validators, capitalize route/form (cost + offset account when cost
is 0),
$fixedAssetId.adjust-cost.tsx+FixedAssetAdjustCostForm, path, header menu item. - Docs:
.claude/rules/fixed-asset-lifecycle.md, docs reference page. - Verify: server-functions + erp typecheck, tests, Biome.