Merge branch 'dev'
All checks were successful
Koori-ERP-Deploy-System / deploy-demo (push) Has been skipped
Koori-ERP-Deploy-System / deploy-production (push) Successful in 50s

This commit is contained in:
2026-02-12 16:41:08 +08:00
2 changed files with 3 additions and 7 deletions

View File

@@ -180,4 +180,4 @@ docker compose down
- **樣式**: 全面使用 Tailwind CSS避免手寫 CSS。 - **樣式**: 全面使用 Tailwind CSS避免手寫 CSS。
- **多租戶**: - **多租戶**:
- 中央邏輯 (Landlord) 與租戶邏輯 (Tenant) 分離。 - 中央邏輯 (Landlord) 與租戶邏輯 (Tenant) 分離。
- 租戶路由定義於 `routes/tenant.php` (但在本專案架構中,大部分路由在 `web.php` 並透過 Middleware 判斷環境)。 - 租戶路由定義於 `routes/tenant.php` (但在本專案架構中,大部分路由在 `web.php` 並透過 Middleware 判斷環境)。

View File

@@ -29,10 +29,7 @@ interface Warehouse {
name: string; name: string;
} }
interface Unit {
id: number;
name: string;
}
interface InventoryOption { interface InventoryOption {
id: number; id: number;
@@ -81,10 +78,9 @@ interface BomItem {
interface Props { interface Props {
products: Product[]; products: Product[];
warehouses: Warehouse[]; warehouses: Warehouse[];
units: Unit[];
} }
export default function Create({ products, warehouses, units }: Props) { export default function Create({ products, warehouses }: Props) {
const [selectedWarehouse, setSelectedWarehouse] = useState<string>(""); // 產出倉庫 const [selectedWarehouse, setSelectedWarehouse] = useState<string>(""); // 產出倉庫
// 快取對照表product_id -> inventories across warehouses // 快取對照表product_id -> inventories across warehouses
const [productInventoryMap, setProductInventoryMap] = useState<Record<string, InventoryOption[]>>({}); const [productInventoryMap, setProductInventoryMap] = useState<Record<string, InventoryOption[]>>({});