diff --git a/frontend/src/api/plan/interface/index.ts b/frontend/src/api/plan/interface/index.ts index 0eaf987..a8bf0f1 100644 --- a/frontend/src/api/plan/interface/index.ts +++ b/frontend/src/api/plan/interface/index.ts @@ -23,6 +23,11 @@ export namespace Plan { export interface ReqPlanParams extends ReqPage,PlanBO { } + + // 检测计划 + 检测源 + export interface PlanAndSourceBO extends PlanBO { + testSourceName: string;//计划所属检测源 + } // // 检测计划列表 // export interface PlanList { // id: string; //检测计划ID diff --git a/frontend/src/api/plan/planData.ts b/frontend/src/api/plan/planData.ts index 36f0909..630be73 100644 --- a/frontend/src/api/plan/planData.ts +++ b/frontend/src/api/plan/planData.ts @@ -165,44 +165,84 @@ const testFatherPlanList: Dict[] = [ label: '检测子计划1-2', }, ] - -const planData = ref([ + +const planData = ref([ { - 'id': '1', - 'name': '检测计划1', - 'pattern':'1', - 'dataSource_Id':'1', - 'script_Id':'1', - 'error_Sys_Id':'1', - 'test_State':'1', - 'report_State':'1', - 'result':'1', - }, - { - 'id': '2', - 'name': '检测子计划2', - 'pattern':'1', - 'father_Plan_Id':'1', - 'dataSource_Id':'2', - 'script_Id':'2', - 'error_Sys_Id':'2', - 'test_State':'2', - 'report_State':'2', - 'result':'0', - }, - { - 'id': '3', - 'name': '检测子计划1-2', - 'pattern':'1', - 'father_Plan_Id':'1', - 'dataSource_Id':'3', - 'script_Id':'3', - 'error_Sys_Id':'3', - 'test_State':'1', - 'report_State':'1', - 'result':'1', - }, + 'id': '1', + 'name': '检测计划1', + 'pattern':'1', + "testSourceName":'标准源-福禄克-6100A', + 'dataSource_Id':'1', + 'script_Id':'1', + 'error_Sys_Id':'1', + 'test_State':'1', + 'report_State':'1', + 'result':'1', + }, + { + 'id': '2', + 'name': '检测计划2', + 'pattern':'1', + "testSourceName":'高精度设备-PQV520-1,高精度设备-PQV520-2', + 'father_Plan_Id':'1', + 'dataSource_Id':'2', + 'script_Id':'2', + 'error_Sys_Id':'2', + 'test_State':'2', + 'report_State':'2', + 'result':'0', + }, + { + 'id': '3', + 'name': '检测子计划3', + 'pattern':'1', + "testSourceName":'标准源-丹迪克-DKLN1', + 'father_Plan_Id':'1', + 'dataSource_Id':'3', + 'script_Id':'3', + 'error_Sys_Id':'3', + 'test_State':'1', + 'report_State':'1', + 'result':'1', + }, ]) +// const planData = ref([ +// { +// 'id': '1', +// 'name': '检测计划1', +// 'pattern':'1', +// 'dataSource_Id':'1', +// 'script_Id':'1', +// 'error_Sys_Id':'1', +// 'test_State':'1', +// 'report_State':'1', +// 'result':'1', +// }, +// { +// 'id': '2', +// 'name': '检测子计划2', +// 'pattern':'1', +// 'father_Plan_Id':'1', +// 'dataSource_Id':'2', +// 'script_Id':'2', +// 'error_Sys_Id':'2', +// 'test_State':'2', +// 'report_State':'2', +// 'result':'0', +// }, +// { +// 'id': '3', +// 'name': '检测子计划1-2', +// 'pattern':'1', +// 'father_Plan_Id':'1', +// 'dataSource_Id':'3', +// 'script_Id':'3', +// 'error_Sys_Id':'3', +// 'test_State':'1', +// 'report_State':'1', +// 'result':'1', +// }, +// ]) // const plandata = ref([ // { diff --git a/frontend/src/views/authority/role/components/permissionUnit.vue b/frontend/src/views/authority/role/components/permissionUnit.vue index 206c44c..c5ac26d 100644 --- a/frontend/src/views/authority/role/components/permissionUnit.vue +++ b/frontend/src/views/authority/role/components/permissionUnit.vue @@ -18,12 +18,16 @@ \ No newline at end of file diff --git a/frontend/src/views/plan/planList/index.vue b/frontend/src/views/plan/planList/index.vue index b7340a3..a518017 100644 --- a/frontend/src/views/plan/planList/index.vue +++ b/frontend/src/views/plan/planList/index.vue @@ -36,6 +36,10 @@ /> + @@ -51,6 +55,7 @@ import type { Plan } from '@/api/plan/interface' import planPopup from "@/views/plan/planList/components/planPopup.vue"; // 导入子组件 import DeviceOpen from '@/views/plan/planList/components/devPopup.vue' import SourceOpen from '@/views/plan/planList/components/sourcePopup.vue' +import devTransfer from './components/devTransfer.vue' import { useViewSize } from '@/hooks/useViewSize' import { useRouter } from "vue-router"; import { useDictStore } from '@/stores/modules/dict' @@ -65,6 +70,8 @@ const defaultUnits = '日'; // 默认的单位 const { popupBaseView, viewWidth, viewHeight } = useViewSize() const openDeviceView = ref() const openSourceView = ref() +const devTransferVisible = ref(false) + // ProTable 实例 const proTable = ref() // const planData = planData @@ -91,17 +98,17 @@ const dialogForm = ref({ // 表格配置项 const columns = reactive[]>([ { type: 'selection', fixed: 'left', width: 70 }, + { type: 'index', fixed: 'left', width: 70, label: '序号' }, { prop: 'name', label: '检测计划名称', width: 200, + search: { el: 'input' }, }, { - prop: 'dataSource_Id', - label: '数据源名称', + prop: 'testSourceName', + label: '检测源名称', width: 200, - enum: testSoureDataList, - fieldNames: { label: 'label', value: 'id' }, }, { prop: 'script_Id', @@ -117,6 +124,13 @@ const columns = reactive[]>([ enum: testErrSystDataList, fieldNames: { label: 'label', value: 'id' }, }, + { + prop: 'dataSource_Id', + label: '数据源名称', + width: 200, + enum: testSoureDataList, + fieldNames: { label: 'label', value: 'id' }, + }, { prop: 'test_State', label: '检测状态', @@ -270,7 +284,8 @@ const handleRowClick = (planSystem: Plan.PlanBO) =>{ } const showDeviceOpen = (planSystem: Plan.PlanBO) => { - openDeviceView.value.open('计划设备列表') + devTransferVisible.value = true; + //openDeviceView.value.open('计划设备列表') } const showtestSourceOpen=(planSystem: Plan.PlanBO)=>{