소스 검색

可视化任务列表

彭宇 2 년 전
부모
커밋
d15fb0381b
2개의 변경된 파일6개의 추가작업 그리고 8개의 파일을 삭제
  1. 1 8
      src/components/vBottomMenu.vue
  2. 5 0
      src/views/forest.vue

+ 1 - 8
src/components/vBottomMenu.vue

@@ -505,12 +505,6 @@
 			deptTreeselect().then(response => {
 				this.deptOptionsLiandong = response.data
 			})
-      /** 获取任务 */
-      this.selectTaskList()
-      /** 获取消息个数 */
-      this.selectMessageCount();
-      /** 获取消息列表 */
-      this.selectMessageList();
 		},
 		methods: {
 			filterbanNode(value, data) {
@@ -709,8 +703,6 @@
 			},
       selectMessageById(id) {
         selectMessageById(id).then(response => {
-          /** 获取消息个数 */
-          this.selectMessageCount();
           /** 获取消息列表 */
           this.selectMessageList();
         });
@@ -725,6 +717,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

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