3 Commits 89738759ea ... 73d8747bec

Tác giả SHA1 Thông báo Ngày
  GuoYuFu123 73d8747bec updated 5 năm trước cách đây
  GuoYuFu123 7ea5a36a4e Merge branch 'master' of http://39.106.8.246:3003/web/ibms 5 năm trước cách đây
  GuoYuFu123 b4f66ac597 updated 5 năm trước cách đây

+ 7 - 0
src/components/ledger/handsontables/assets.vue

@@ -1235,6 +1235,13 @@ export default {
         this.main[row].infos[key] = ''
       }
     }
+  },
+  watch: {      
+      projectId(){
+          this.main = []
+          this.mess.deviceId = null
+          this.page.total = 0
+      }
   }
 };
 </script>

+ 7 - 0
src/components/ledger/handsontables/device.vue

@@ -1294,6 +1294,13 @@ export default {
         this.main[row].infos[key] = ''
       }
     }
+  },
+  watch: {
+      projectId(){
+          this.main = []
+          this.mess.deviceId = null
+          this.page.total = 0
+      }
   }
 };
 </script>

+ 6 - 1
src/components/ledger/handsontables/system.vue

@@ -1049,7 +1049,12 @@ export default {
         //   this.reset()
         // }
       }
-    }
+    },
+    projectId(){
+          this.main = []
+          this.mess.deviceId = null
+          this.page.total = 0
+      }
   }
 };
 </script>

+ 11 - 1
src/components/ledger/lib/assets.vue

@@ -15,6 +15,7 @@
   </div>
 </template>
 <script>
+import {mapGetters} from 'vuex';
 import { getEquipmentFamily } from "@/api/scan/request";
 export default {
   name: "getCode",
@@ -24,6 +25,11 @@ export default {
       default: true
     }
   },
+      computed: {
+        ...mapGetters("layout", [
+            "projectId",
+        ])
+  },
   data() {
     return {
       value: [],
@@ -39,7 +45,11 @@ export default {
   created() {
     this.getData();
   },
-  mounted() { },
+    watch: {
+      projectId() {
+          this.value = ['']
+      }
+  },
   methods: {
     setValue(val) {
       this.value = val

+ 11 - 1
src/components/ledger/lib/cascader.vue

@@ -15,6 +15,7 @@
   </div>
 </template>
 <script>
+import {mapGetters} from 'vuex';
 import { getEqCode } from "@/api/scan/request";
 export default {
   name: "getCode",
@@ -28,6 +29,11 @@ export default {
       default: false,
     }
   },
+    computed: {
+        ...mapGetters("layout", [
+            "projectId",
+        ])
+  },
   data() {
     return {
       value: [""],
@@ -43,7 +49,11 @@ export default {
   created() {
     this.getData();
   },
-  mounted() { },
+  watch: {
+      projectId() {
+          this.value = ['']
+      }
+  },
   methods: {
     setValue(val) {
       this.value = val

+ 8 - 1
src/components/ledger/lib/floorCascader.vue

@@ -45,7 +45,14 @@
             this.param.secret = this.secret
             this.getData()
         },
-        mounted() {},
+        watch: {
+            projectId() {
+                this.value = ['all'];
+                this.options = [];
+                this.param.ProjId = this.projectId
+                this.getData()
+            }
+        },
         methods: {
             //获取数据
             getData() {

+ 11 - 1
src/components/ledger/lib/system.vue

@@ -15,6 +15,7 @@
   </div>
 </template>
 <script>
+import {mapGetters} from 'vuex';
 import { getEqCode } from "@/api/scan/request";
 export default {
   name: "getCode",
@@ -24,6 +25,11 @@ export default {
       default: true
     }
   },
+        computed: {
+        ...mapGetters("layout", [
+            "projectId",
+        ])
+  },
   data() {
     return {
       value: [],
@@ -39,7 +45,11 @@ export default {
   created() {
     this.getData();
   },
-  mounted() { },
+      watch: {
+      projectId() {
+          this.value = ['']
+      }
+  },
   methods: {
     setValue(val) {
       this.value = val

+ 1 - 0
src/views/data_admin/buildLog/index.vue

@@ -225,6 +225,7 @@ export default {
     },
     watch: {
         projectId() {
+            this.searchValue = '';
             this.getLogData();
         }
     }

+ 1 - 0
src/views/data_admin/buildUser/index.vue

@@ -167,6 +167,7 @@ export default {
     },
     watch: {
         projectId() {
+            this.searchValue = ''
             this.getUserList();
         }
     }

+ 6 - 0
src/views/ledger/facility/index.vue

@@ -68,6 +68,12 @@ export default {
     this.param.secret = this.secret
     this.getProjName()
   },
+  watch: {
+      projectId() {
+          this.param.ProjId = this.projectId;
+          this.getProjName()
+      }
+  },
   methods: {
     getProjName() {
       let param = {

+ 6 - 1
src/views/ledger/property/index.vue

@@ -71,7 +71,12 @@ export default {
       this.param.secret = this.secret
     this.getProjName()
   },
-  mounted() { },
+  watch: {
+    projectId() {
+        this.param.ProjId = this.projectId
+        this.getProjName()
+    }
+  },
   methods: {
     getProjName() {
       let param = {

+ 6 - 1
src/views/ledger/system/index.vue

@@ -69,7 +69,12 @@ export default {
       this.param.secret = this.secret
     this.getProjName()
   },
-  mounted() { },
+    watch: {
+    projectId() {
+        this.param.ProjId = this.projectId
+        this.getProjName()
+    }
+  },
   methods: {
     getProjName() {
       let param = {