萤石摄像头

This commit is contained in:
Teo
2025-06-17 09:49:15 +08:00
parent f122dc30d2
commit 0ff1e74157
17 changed files with 1614 additions and 85 deletions

View File

@ -10,7 +10,8 @@
:options="matrixOptions"
placeholder="请选择"
@change="handleChange"
:props="{ value: 'id', label: 'matrixName' }"
:props="{ value: 'matrixId', label: 'name' }"
v-model="queryParams.matrixId"
clearable
/>
<!-- <el-select v-model="matrixValue" placeholder="请选择" @change="handleChange" clearable>
@ -272,15 +273,23 @@ const { queryParams, form, rules } = toRefs(data);
const getList = async () => {
if (!queryParams.value.matrixId) {
const res = await getProjectSquare(currentProject.value.id);
if (res.rows.length === 0) {
if (res.data.length === 0) {
proxy?.$modal.msgWarning('当前项目下没有方阵,请先创建方阵');
} else {
if (!matrixValue.value) matrixValue.value = res.rows[0].id;
matrixOptions.value = res.rows;
queryParams.value.matrixId = res.rows[0].id;
let matrixList = res.data.map((item) => {
return {
...item,
matrixId: item.projectId
};
});
if (!matrixValue.value) matrixValue.value = matrixList[0].id;
matrixOptions.value = matrixList;
queryParams.value.matrixId = matrixList[0].children[0].matrixId;
}
}
loading.value = true;
console.log(queryParams.value);
const res = await listProgressCategory(queryParams.value);
const data = proxy?.handleTree<ProgressCategoryVO>(res.data, 'id', 'pid');
if (data) {
@ -324,7 +333,7 @@ const handleQuery = () => {
/** 级联选择器改变事件 */
const handleChange = (value: number) => {
queryParams.value.matrixId = value;
queryParams.value.matrixId = value[1];
getList();
};