feat: 添加路径搜索节点
This commit is contained in:
parent
39460cb74c
commit
7034b0af1b
@ -48,4 +48,21 @@ export function updateIndicator(data) {
|
|||||||
method: "put",
|
method: "put",
|
||||||
data
|
data
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取指定层级的指标
|
||||||
|
* @param {*} id
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
|
export function getChildrenByParentIdWithLevelLimitApi(parentId, maxLevel, type) {
|
||||||
|
return request({
|
||||||
|
url: `/evaluate/indicator/getChildrenByParentIdWithLevelLimit`,
|
||||||
|
method: "get",
|
||||||
|
params: {
|
||||||
|
parentId,
|
||||||
|
maxLevel,
|
||||||
|
type
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
@ -506,6 +506,22 @@ export const collapseList = [
|
|||||||
],
|
],
|
||||||
outputType: 'json',
|
outputType: 'json',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
icon: touchSvg,
|
||||||
|
name: "路径搜索",
|
||||||
|
type: "serviceNode",
|
||||||
|
desc: "路径搜索",
|
||||||
|
action: 'TI_PATH_SEARCH',
|
||||||
|
nodeType: "AE",
|
||||||
|
nodeParams: [
|
||||||
|
{ name: "currentLocation", type: "input", input: "", disabled: true }
|
||||||
|
],
|
||||||
|
outputType: 'json',
|
||||||
|
outputParams: [
|
||||||
|
{ name: 'nextLocation', type: 'string', desc: '下一路径位置', disabled: true},
|
||||||
|
{ name: 'isEnd', type: 'string', desc: '是否结束', disabled: true}
|
||||||
|
]
|
||||||
|
}
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@ -211,7 +211,17 @@
|
|||||||
<el-input-number v-model="form.sort" placeholder="排序" />
|
<el-input-number v-model="form.sort" placeholder="排序" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="24">
|
<el-col :span="12">
|
||||||
|
<el-form-item label="评价指标" prop="indicatorId">
|
||||||
|
<el-tree-select
|
||||||
|
v-model="form.indicatorId"
|
||||||
|
:data="indicatorData"
|
||||||
|
:props="{ label: 'name', value: 'id', children: 'children' }"
|
||||||
|
:render-after-expand="false"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
<el-form-item label="项目描述" prop="remark">
|
<el-form-item label="项目描述" prop="remark">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.remark"
|
v-model="form.remark"
|
||||||
@ -237,6 +247,7 @@ import TableSearch from "@/components/TableSearch/index.vue";
|
|||||||
import { useContainerHeight } from "@/hooks/tableHeight";
|
import { useContainerHeight } from "@/hooks/tableHeight";
|
||||||
import { ElMessageBox } from "element-plus";
|
import { ElMessageBox } from "element-plus";
|
||||||
import { getTreeDataApi } from '@/api/is/func/index'
|
import { getTreeDataApi } from '@/api/is/func/index'
|
||||||
|
import { getChildrenByParentIdWithLevelLimitApi } from "@/api/evaluate/indicator.js";
|
||||||
|
|
||||||
const topContainerRef = ref();
|
const topContainerRef = ref();
|
||||||
const containerHeight = useContainerHeight(topContainerRef);
|
const containerHeight = useContainerHeight(topContainerRef);
|
||||||
@ -422,9 +433,19 @@ const handleDelete = (row) => {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const indicatorData = ref([]);
|
||||||
|
const getIndicatorData = () => {
|
||||||
|
getChildrenByParentIdWithLevelLimitApi(0,2, 1).then((res) => {
|
||||||
|
if (res.code === 200) {
|
||||||
|
indicatorData.value = res.data || []
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
getList();
|
getList();
|
||||||
getTreeData()
|
getTreeData();
|
||||||
|
getIndicatorData();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@ -281,6 +281,16 @@
|
|||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="评价指标" prop="indicatorId">
|
||||||
|
<el-tree-select
|
||||||
|
v-model="form.indicatorId"
|
||||||
|
:data="indicatorData"
|
||||||
|
:props="{ label: 'name', value: 'id', children: 'children' }"
|
||||||
|
:render-after-expand="false"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
<el-col :span="24">
|
<el-col :span="24">
|
||||||
<el-form-item label="项目描述" prop="description">
|
<el-form-item label="项目描述" prop="description">
|
||||||
<el-input
|
<el-input
|
||||||
@ -322,12 +332,12 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="委托单位" prop="entrustUnit">
|
<el-form-item label="委托单位" prop="entrustUnit">
|
||||||
<el-input v-model="form.entrustUnit" placeholder="请输入项目描述" />
|
<el-input v-model="form.entrustUnit" placeholder="请输入委托单位" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="生产单位" prop="productionUnit">
|
<el-form-item label="生产单位" prop="productionUnit">
|
||||||
<el-input v-model="form.productionUnit" placeholder="请输入项目描述" />
|
<el-input v-model="form.productionUnit" placeholder="请输入生产单位" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
@ -407,6 +417,7 @@ import { useContainerHeight } from "@/hooks/tableHeight";
|
|||||||
|
|
||||||
import { getExecuteRunParams, queryExecuteInstId } from "@/api/vi/project.js"
|
import { getExecuteRunParams, queryExecuteInstId } from "@/api/vi/project.js"
|
||||||
import { appendParamsToPath } from "@/utils/fn.js";
|
import { appendParamsToPath } from "@/utils/fn.js";
|
||||||
|
import { getChildrenByParentIdWithLevelLimitApi } from "@/api/evaluate/indicator.js";
|
||||||
|
|
||||||
const topContainerRef = ref();
|
const topContainerRef = ref();
|
||||||
const containerHeight = useContainerHeight(topContainerRef);
|
const containerHeight = useContainerHeight(topContainerRef);
|
||||||
@ -648,8 +659,19 @@ const handleLogicFlow = (item) => {
|
|||||||
const fullPath = appendParamsToPath("/flow", params);
|
const fullPath = appendParamsToPath("/flow", params);
|
||||||
window.open(fullPath, "_blank");
|
window.open(fullPath, "_blank");
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const indicatorData = ref([]);
|
||||||
|
const getIndicatorData = () => {
|
||||||
|
getChildrenByParentIdWithLevelLimitApi(0,2, 0).then((res) => {
|
||||||
|
if (res.code === 200) {
|
||||||
|
indicatorData.value = res.data || []
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
getList();
|
getList();
|
||||||
|
getIndicatorData();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@ -36,7 +36,7 @@ export default defineConfig(({mode, command}) => {
|
|||||||
//赵 http://10.148.108.58:13080
|
//赵 http://10.148.108.58:13080
|
||||||
// dev http://10.148.20.34:13080
|
// dev http://10.148.20.34:13080
|
||||||
// target: VITE_API_URL,
|
// target: VITE_API_URL,
|
||||||
target: command === 'build' ? VITE_API_URL : 'http://192.168.0.10:13080',
|
target: command === 'build' ? VITE_API_URL : 'http://192.168.0.21:13081',
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
rewrite: (p) => p.replace(/^\/dev-api/, '')
|
rewrite: (p) => p.replace(/^\/dev-api/, '')
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user