diff --git a/src/views/business/measure/classification/detail.vue b/src/views/business/measure/classification/detail.vue index cc6fba4..bddea4e 100644 --- a/src/views/business/measure/classification/detail.vue +++ b/src/views/business/measure/classification/detail.vue @@ -8,6 +8,7 @@ import type { dictType } from '@/global' import { UploadFile } from '@/api/file' import showPhoto from '@/components/showPhoto/index.vue' +import { getLocationList } from '@/api/business/taskMeasure/measureData' import { addClassification, updateClassification } from '@/api/business/measure/classification' const user = useUserStore() // 用户信息 const textMap: { [key: string]: string } = { @@ -49,8 +50,8 @@ const deviceTypeList = ref([])// 设备分类 const standardList = ref([])// 检校标准装置 const measureCategoryList = ref([])// 检校类别 -const labXList = ref([])// 西昌实验室 -const labHList = ref([])// 海口实验室 +const labXList = ref([]) as any// 西昌实验室 +const labHList = ref([]) as any// 海口实验室 function getDict() { // 检校类别 @@ -65,35 +66,16 @@ getDictByCode('bizStandardEquipmentType').then((response) => { standardList.value = response.data }) - // 西昌实验室 - labXList.value = [{ - id: '1', - value: '1', - name: '电力实验室', - }, - { - id: '2', - value: '2', - name: '无线电实验室', - }, - { - id: '3', - value: '4', - name: '机关', - }, - ] - // 海口实验室 - labHList.value = [{ - id: '1', - value: '电学实验室', - name: '电学实验室', - }, - { - id: '2', - value: '2', - name: '压力检测实验室', - }, - ] + // 测试、校准或检定地点 + getLocationList({ + locationName: '', // 地点名称 + locationNo: '', // 地点编号 + limit: 999999, + offset: 1, + }).then((res) => { + labXList.value = res.data.rows.filter((item: { locationLab: string }) => item.locationLab === '西昌实验室') + labHList.value = res.data.rows.filter((item: { locationLab: string }) => item.locationLab === '海口实验室') + }) } // ----------------------------------路由参数------------------------------------------------ if ($route.params && $route.params.type) { @@ -323,7 +305,7 @@ filterable :disabled="pageType === 'detail'" > - + @@ -335,7 +317,7 @@ filterable :disabled="pageType === 'detail'" > - +