Sfoglia il codice sorgente

可视化任务列表

彭宇 2 anni fa
parent
commit
232777a7f3
3 ha cambiato i file con 11 aggiunte e 8 eliminazioni
  1. 1 8
      src/components/vBottomMenu.vue
  2. 5 0
      src/views/forest.vue
  3. 5 0
      src/views/resources.vue

+ 1 - 8
src/components/vBottomMenu.vue

@@ -506,12 +506,6 @@
 			deptTreeselect().then(response => {
 				this.deptOptionsLiandong = response.data
 			})
-      /** 获取任务 */
-      this.selectTaskList()
-      /** 获取消息个数 */
-      this.selectMessageCount();
-      /** 获取消息列表 */
-      this.selectMessageList();
 		},
 		methods: {
 			filterbanNode(value, data) {
@@ -710,8 +704,6 @@
 			},
       selectMessageById(id) {
         selectMessageById(id).then(response => {
-          /** 获取消息个数 */
-          this.selectMessageCount();
           /** 获取消息列表 */
           this.selectMessageList();
         });
@@ -726,6 +718,7 @@
       selectMessageList(){
         selectMessageList(Cookies.get("userId")).then(response => {
           this.messageList = response.data
+          this.messageCount = response.data.length
         });
       },
 			handleCheckedCitiesChangeBan(value) {

+ 5 - 0
src/views/forest.vue

@@ -508,6 +508,7 @@
           this.getSupermap(this.getCurrentDataStr(), true);
         }
       }, 10000)
+      this.bottomMenuList() //获取底部公共组件消息和任务
     },
     data() {
       return {
@@ -1176,6 +1177,10 @@
       /** ----------------------------------weosocket结束------------------------------------- */
 
       /** ----------------------------------底部按钮公用组件开始------------------------------------- */
+      bottomMenuList() {
+        this.$refs.bottomMenu.selectTaskList()//获取任务列表
+        this.$refs.bottomMenu.selectMessageList()//获取消息列表
+      },
       showDialog(click) {
         if (click == 'eventLocation') {
           this.$refs.eventLocation.showEventLocation()

+ 5 - 0
src/views/resources.vue

@@ -84,6 +84,7 @@
     mounted() {
       this.getResourcesCount();
       this.selectResources();
+      this.bottomMenuList() //获取底部公共组件消息和任务
     },
     data() {
       return {
@@ -240,6 +241,10 @@
         }
       },
       /** ----------------------------------底部按钮公用组件开始------------------------------------- */
+      bottomMenuList() {
+        this.$refs.bottomMenu.selectTaskList()//获取任务列表
+        this.$refs.bottomMenu.selectMessageList()//获取消息列表
+      },
       showDialog(click) {
         if (click == 'eventLocation') {
           this.$refs.eventLocation.showEventLocation()