Explorar o código

查询条件为空时 不发起请求

zhulu hai 1 ano
pai
achega
17db289830
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      src/views/system/device/index.vue

+ 2 - 1
src/views/system/device/index.vue

@@ -584,7 +584,8 @@ export default {
       this.changeSelect(data);
       this.handleQuery();
     },
-    changeSelect(val) {
+    changeSelect(val) {      
+      if(!val || !val.id) return;
       getHostByOrgId(val).then((response) => {
         this.form.hostId = null;
         this.hostList = response.data;