diff --git a/src/pages/Setting/AlgorithmSetting.tsx b/src/pages/Setting/AlgorithmSetting.tsx index 6d01905..131e8ec 100644 --- a/src/pages/Setting/AlgorithmSetting.tsx +++ b/src/pages/Setting/AlgorithmSetting.tsx @@ -3,7 +3,7 @@ import { postDeviceGroupGetDeviceGroupTree, } from '@/services/device/DeviceGroup'; -import { postGetProjectByGroupId } from '@/services/project/Project'; +import { postProjectGetProjectByGroupId } from '@/services/project/Project'; import { postModelVersionGetModelVersionListByIds } from '@/services/resource/ModelVersion'; import { FormattedMessage } from '@@/exports'; import { RedoOutlined } from '@ant-design/icons'; @@ -42,7 +42,7 @@ const AlgorithmSetting: React.FC = () => { const [nodeTreeData, setNodeTreeData] = React.useState([]); const [selectNodes, setSelectNodes] = React.useState([]); const [currentRow, setCurrentRow] = useState(); - const [currentCard, setCurrentCard] = useState(); + const [currentCard, setCurrentCard] = useState(); const [selectedRowsState, setSelectedRows] = useState([]); const [tabs, setTabs] = useState([]); @@ -50,11 +50,11 @@ const AlgorithmSetting: React.FC = () => { const [modelVersionData, setModelVersionData] = useState([]); const [projectData, setProjectData] = useState({}); const [targetKeys, setTargetKeys] = useState([]); - + const [projectConfigId, setProjectConfigId] = useState(0) const handleUpdateModal = () => { if (updateModalOpen) { setUpdateModalOpen(false); - setCurrentCard(undefined); + setProjectConfigId(0); } else { setUpdateModalOpen(true); } @@ -169,8 +169,9 @@ const AlgorithmSetting: React.FC = () => { // TODO 操作左侧网点数据节点, 项目列表数据变更 function fetchProjectByGroupId(record: Record) { // console.log('clickTreeNode', projectCardListRef.current) - postGetProjectByGroupId({ id: record.id }).then((resp) => { + postProjectGetProjectByGroupId({ id: record.id }).then((resp) => { let tab_data = (resp?.data?.list || []).map((v: any) => { + console.log(resp.data.list) let model_data = ([...v?.models] || []).map((item: any) => ( { @@ -182,9 +183,9 @@ const AlgorithmSetting: React.FC = () => { actions: [