feat(inventory): 商品管理新增儲位欄位
This commit is contained in:
@@ -95,6 +95,7 @@ class ProductController extends Controller
|
||||
'name' => $product->purchaseUnit->name,
|
||||
] : null,
|
||||
'conversionRate' => (float) $product->conversion_rate,
|
||||
'location' => $product->location,
|
||||
];
|
||||
});
|
||||
|
||||
@@ -125,6 +126,7 @@ class ProductController extends Controller
|
||||
'large_unit_id' => 'nullable|exists:units,id',
|
||||
'conversion_rate' => 'required_with:large_unit_id|nullable|numeric|min:0.0001',
|
||||
'purchase_unit_id' => 'nullable|exists:units,id',
|
||||
'location' => 'nullable|string|max:255',
|
||||
], [
|
||||
'code.required' => '商品代號為必填',
|
||||
'code.max' => '商品代號最多 8 碼',
|
||||
@@ -163,6 +165,7 @@ class ProductController extends Controller
|
||||
'large_unit_id' => 'nullable|exists:units,id',
|
||||
'conversion_rate' => 'required_with:large_unit_id|nullable|numeric|min:0.0001',
|
||||
'purchase_unit_id' => 'nullable|exists:units,id',
|
||||
'location' => 'nullable|string|max:255',
|
||||
], [
|
||||
'code.required' => '商品代號為必填',
|
||||
'code.max' => '商品代號最多 8 碼',
|
||||
|
||||
Reference in New Issue
Block a user