diff --git a/src/pages/supplier/admission/SupplierCategoryEntry/components/CreateModal.tsx b/src/pages/supplier/admission/SupplierCategoryEntry/components/CreateModal.tsx index 12a3376..97b0bd0 100644 --- a/src/pages/supplier/admission/SupplierCategoryEntry/components/CreateModal.tsx +++ b/src/pages/supplier/admission/SupplierCategoryEntry/components/CreateModal.tsx @@ -109,13 +109,17 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi form.setFieldsValue({ accessWorkName: autoTitle }); } }; - + //获取 cuCompanyNumber + const onChangeDepartmentSelect = (value: any, label: any, extra: any) => { + form.setFieldsValue({ orgId: extra?.triggerNode?.props.cuCompanyNumber }); + } // 提交 const onFinish = async (values: any) => { const finalPayload: { coscoAccessWork: { accessWorkName: string; deptId: string; + orgId: string; }; categoryIds: string[]; supplierIds: string[]; @@ -123,6 +127,7 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi coscoAccessWork: { accessWorkName: '', deptId: '', + orgId: '', }, categoryIds: [], supplierIds: [], @@ -131,6 +136,8 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi finalPayload.coscoAccessWork.accessWorkName = values.accessWorkName; //准入部门 finalPayload.coscoAccessWork.deptId = values.deptId; + //准入单位 + finalPayload.coscoAccessWork.orgId = values.orgId; //品类选择 finalPayload.categoryIds = values.categoryIds; //选择供应商 @@ -207,9 +214,11 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi name="deptId" rules={[{ required: true, message: '请选择准入部门' }]} > - + + + + - void; }> = ({ vi -