Quellcode durchsuchen

Merge branch 'master' of http://120.26.64.82:3000/BFFE/SZYGM1.0

zhongxiaoyu vor 2 Jahren
Ursprung
Commit
e17aa3dd0c

+ 0 - 1
src/views/BasicsData/airportCompany/index.vue

@@ -178,7 +178,6 @@ const btnClick = (row, index, param) => {
         tableOptionser.value.push(element);
       }
     });
-    console.log(tableOptionser);
   } else if (param === 3) {
     msgTitle.value = "删除机场公司维护";
     flag.value = true;

+ 19 - 1
src/views/systemSettings/datastructure/index.vue

@@ -121,7 +121,8 @@ const flag = ref<Boolean>(false); //弹窗开关
 const type = ref<String>(""); //判断是否删除
 const msgTitle = ref<String>("新增数据结构"); //弹窗标题
 const tableColsCopys = reactive<Object>({}); //弹窗\
-const tableOptionser = ref<Array>([]); //弹窗下拉
+const tableOptionser = ref([]); //弹窗下拉
+const tableOptionCopys = ref([]); //弹窗下拉
 const tableForm = reactive({
   dataStructureID: "",
   structureName: "",
@@ -235,6 +236,18 @@ const delRemove = () => {
 const delRest = () => {
   flag.value = false;
 };
+//获取弹框-下拉数据
+const getSelectData = async (id, name) => {
+  const { code, returnData } = await Query({
+    id,
+    dataContent: name ? [name] : name === null ? [null] : [],
+  });
+  if (code == 0) {
+    tableOptionser.value = returnData.listValues;
+  } else {
+    tableOptionser.value = [];
+  }
+};
 //获取表格数据
 const getQuery = async () => {
   try {
@@ -256,6 +269,11 @@ const getQuery = async () => {
       }
       tableData.value.push(...returnData.listValues);
       tableCols.value = returnData.columnSet;
+      returnData.columnSet.forEach((item) => {
+        if (item.listqueryTemplateID && item.columnName === "datatype") {
+          getSelectData(item.listqueryTemplateID);
+        }
+      });
       tableCols.value.forEach((element) => {
         element.label = element.columnLabel;
         element.key = element.columnName;

+ 18 - 0
src/views/systemSettings/sourceTube/index.vue

@@ -209,6 +209,19 @@ const delRemove = () => {
 const delRest = () => {
   flag.value = false;
 };
+//获取弹框-下拉数据
+const getSelectData = async (id, name) => {
+  const { code, returnData } = await Query({
+    id,
+    dataContent: name ? [name] : name === null ? [null] : [],
+  });
+  if (code == 0) {
+    tableOptionser.value = returnData.listValues;
+    tableOptionCopys.value = _.cloneDeep(returnData.listValues);
+  } else {
+    tableOptionser.value = [];
+  }
+};
 //获取表格数据
 const getQuery = async () => {
   try {
@@ -230,6 +243,11 @@ const getQuery = async () => {
       }
       tableData.value.push(...returnData.listValues);
       tableCols.value = returnData.columnSet;
+      returnData.columnSet.forEach((item) => {
+        if (item.listqueryTemplateID && item.columnName === "protocolName") {
+          getSelectData(item.listqueryTemplateID);
+        }
+      });
       tableCols.value.forEach((element) => {
         element.label = element.columnLabel;
         element.key = element.columnName;

+ 57 - 3
src/views/systemSettings/warningEdit/index.vue

@@ -235,6 +235,7 @@
                   default-first-option
                   clearable
                   placeholder="请选择开始节点"
+                  @change="changeSelect"
                 >
                   <el-option
                     v-for="item in tableOptionser"
@@ -256,9 +257,10 @@
                   default-first-option
                   clearable
                   placeholder="请选择开始位置"
+                  @change="changebegin"
                 >
                   <el-option
-                    v-for="item in tableOptionser"
+                    v-for="item in tableOptionbegin"
                     :key="item.v ? item.v : item.planDepartureApt"
                     :label="item.k ? item.k : item.planDepartureApt"
                     :value="item.v ? item.v : item.planDepartureApt"
@@ -277,9 +279,10 @@
                   default-first-option
                   clearable
                   placeholder="请选择结束节点"
+                  @change="changeSelected"
                 >
                   <el-option
-                    v-for="item in tableOptionser"
+                    v-for="item in tableOptionend"
                     :key="item.v ? item.v : item.planDepartureApt"
                     :label="item.k ? item.k : item.planDepartureApt"
                     :value="item.v ? item.v : item.planDepartureApt"
@@ -298,9 +301,10 @@
                   default-first-option
                   clearable
                   placeholder="请选择结束位置"
+                  @change="changeEndPos"
                 >
                   <el-option
-                    v-for="item in tableOptionser"
+                    v-for="item in tableOptionendPos"
                     :key="item.v ? item.v : item.planDepartureApt"
                     :label="item.k ? item.k : item.planDepartureApt"
                     :value="item.v ? item.v : item.planDepartureApt"
@@ -331,6 +335,8 @@ const noMore = ref<Boolean>(false);
 const rowTitle = ref<String>("");
 const tableCols = ref([]); //表头数据
 const serviceId = ref<String>("");
+const beginPositionId = ref<String>("");
+const endPositionId = ref<String>("");
 const tableObj = ref({}); //增删改数据缓存
 const tableForm = reactive({
   alarmSceneId: "",
@@ -356,6 +362,9 @@ const tableForms = reactive({
   event: "",
 }); //弹窗内容
 const tableOptionser = ref<Array>([]); //下拉
+const tableOptionbegin = ref<Array>([]); //下拉
+const tableOptionend = ref<Array>([]); //下拉
+const tableOptionendPos = ref<Array>([]); //下拉
 const flag = ref<Boolean>(false); //弹窗开关
 const type = ref<String>(""); //判断是否删除
 const msgTitle = ref<String>("新增报警预警策略"); //弹窗标题
@@ -491,6 +500,18 @@ const sysServiceWarn = async () => {
     // this.loading = false;
   }
 };
+//获取弹框-下拉数据
+const getSelectData = async (id, name) => {
+  const { code, returnData } = await Query({
+    id,
+    dataContent: name ? [name] : name === null ? [null] : [],
+  });
+  if (code == 0) {
+    return returnData.listValues;
+  } else {
+    return [];
+  }
+};
 //获取表格数据
 const getQuery = async () => {
   try {
@@ -512,6 +533,25 @@ const getQuery = async () => {
       }
       tableData.value.push(...returnData.listValues);
       tableCols.value = returnData.columnSet;
+      returnData.columnSet.forEach((item) => {
+        if (item.listqueryTemplateID && item.columnName === "beginNode") {
+          tableOptionser.value = getSelectData(item.listqueryTemplateID);
+        } else if (
+          item.listqueryTemplateID &&
+          item.columnName === "beginPosition"
+        ) {
+          tableOptionbegin.value = getSelectData(item.listqueryTemplateID);
+          beginPositionId.value = item.listqueryTemplateID;
+        } else if (item.listqueryTemplateID && item.columnName === "endNode") {
+          tableOptionend.value = getSelectData(item.listqueryTemplateID);
+        } else if (
+          item.listqueryTemplateID &&
+          item.columnName === "endPosition"
+        ) {
+          tableOptionendPos.value = getSelectData(item.listqueryTemplateID);
+          endPositionId.value = item.listqueryTemplateID;
+        }
+      });
       tableCols.value.forEach((element) => {
         element.label = element.columnLabel;
         element.key = element.columnName;
@@ -524,6 +564,20 @@ const getQuery = async () => {
     page.value--;
   }
 };
+//开始节点
+const changeSelect = (value) => {
+  tableOptionbegin.value = getSelectData(beginPositionId, value);
+  tableForms.beginPosition = "";
+};
+//开始位置
+const changebegin = (value) => {};
+//结束节点
+const changeSelected = (value) => {
+  tableOptionendPos.value = getSelectData(endPositionId, value);
+  tableForms.endPosition = "";
+};
+//结束位置
+const changeEndPos = (value) => {};
 //确认提交
 const warningEditForm: any = ref(null);
 const submitForm = () => {