部门更改,生物安全模块的人员更换为下拉框
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
<!-- 查询区域 -->
|
||||
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="80px">
|
||||
|
||||
<el-form-item label="母羊耳号" prop="allEarNumbers">
|
||||
<el-form-item label="羊只耳号" prop="allEarNumbers">
|
||||
<div style="display: flex; align-items: center; gap: 10px; flex-wrap: wrap;">
|
||||
<!-- 主选择器:不显示已选标签 -->
|
||||
<el-select v-model="queryParams.allEarNumbers" multiple filterable remote reserve-keyword
|
||||
@@ -274,6 +274,33 @@ import { listSheepfold_management } from '@/api/fileManagement/sheepfold_managem
|
||||
import { listDisease } from '@/api/biosafety/disease'
|
||||
import { getCurrentInstance, onMounted, ref, watch } from 'vue'
|
||||
import { searchEarNumbers } from '@/api/common/sheep'
|
||||
import { getUserByPost } from '@/api/common/user'
|
||||
|
||||
const technicalOptions = ref([]) //自定义技术员数组变量
|
||||
|
||||
// 获取技术员列表
|
||||
const fetchTechnicalList = () => {
|
||||
getUserByPost({ postCode: "techs" })
|
||||
.then(res => {
|
||||
if (res.code === 200 && Array.isArray(res.data)) {
|
||||
technicalOptions.value = res.data.map(item => ({
|
||||
// value: item.userId,
|
||||
value: item.nickName,
|
||||
label: item.nickName,
|
||||
// postName: item.postName, // 保留用于下拉显示
|
||||
// postCode: item.postCode // 保留用于逻辑判断
|
||||
}))
|
||||
console.log(technicalOptions.value);
|
||||
|
||||
} else {
|
||||
technicalOptions.value = []
|
||||
ElMessage.warning(res.msg || '获取技术员列表失败')
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* ---------- 基础依赖 ---------- */
|
||||
const { proxy } = getCurrentInstance()
|
||||
@@ -654,6 +681,7 @@ onMounted(() => {
|
||||
label: i.sheepfoldName,
|
||||
}))
|
||||
})
|
||||
fetchTechnicalList() // 获取技术员列表
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user