Commit 0fc2b184 authored by 前端-黄佳鑫's avatar 前端-黄佳鑫

🐞 fix(): 修改新增采购物料编辑id和品类没传的问题

parent 1e9d7809
......@@ -157,11 +157,11 @@ const AnchorModal: React.FC<AnchorModalProps> = (props: any) => {
const handleSubmit = () => {
form.validateFields().then((res: any) => {
const data = {
goodsId: Object.keys(product).length > 0 && product.id,
goodsId: Object.keys(product).length > 0 ? product.id : edit.goodsId,
itemNo: Object.keys(product).length > 0 ? product.code : res.number,
number: Object.keys(product).length > 0 ? product.code : res.number,
name: Object.keys(product).length > 0 ? product.name : res.name,
category: Object.keys(product).length > 0 && product.customerCategory.name,
category: Object.keys(product).length > 0 ? product.customerCategory.name : edit.category,
ids: res.ids,
brand: res.brand,
model: res.model,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment