提交 feae27bb 作者: ZhangLingKun

功能:服务地区,场景标签回显

上级 10f0afe1
...@@ -184,6 +184,7 @@ function ServiceDetailView() { ...@@ -184,6 +184,7 @@ function ServiceDetailView() {
}); });
if (res && res.code === '200') { if (res && res.code === '200') {
setServiceDetail(res.result); setServiceDetail(res.result);
setInspectionId(res.result.inspectionId);
form.setFieldsValue({ form.setFieldsValue({
...res.result, ...res.result,
companyInspectionFiles1: res.result.inspectionFileDTOS.filter((i) => i.first === 1), companyInspectionFiles1: res.result.inspectionFileDTOS.filter((i) => i.first === 1),
...@@ -191,6 +192,7 @@ function ServiceDetailView() { ...@@ -191,6 +192,7 @@ function ServiceDetailView() {
(i) => i.first === 0 && i.fileType === 0, (i) => i.first === 0 && i.fileType === 0,
), ),
companyInspectionFiles3: res.result.inspectionFileDTOS.filter((i) => i.fileType === 1), companyInspectionFiles3: res.result.inspectionFileDTOS.filter((i) => i.fileType === 1),
serviceArea: res.result.serviceArea?.split(','),
}); });
} }
}; };
...@@ -213,6 +215,7 @@ function ServiceDetailView() { ...@@ -213,6 +215,7 @@ function ServiceDetailView() {
// 监听服务id // 监听服务id
useEffect(() => { useEffect(() => {
if (!inspectionId) return; if (!inspectionId) return;
console.log('执行到此处 --->', inspectionId);
getInspectionTagList().then(); getInspectionTagList().then();
}, [inspectionId]); }, [inspectionId]);
// 监听行业列表 // 监听行业列表
...@@ -328,6 +331,7 @@ function ServiceDetailView() { ...@@ -328,6 +331,7 @@ function ServiceDetailView() {
<Form.Item <Form.Item
label='所属服务' label='所属服务'
name='inspectionId' name='inspectionId'
required
rules={[ rules={[
// { required: true, message: '请选择所属服务' }, // { required: true, message: '请选择所属服务' },
() => ({ () => ({
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论