seimin 2 years ago
parent
commit
a832171ab0
5 changed files with 21 additions and 18 deletions
  1. 1 1
      src/router/index.js
  2. 1 1
      src/views/Main.vue
  3. 3 0
      src/views/incidentList.vue
  4. 15 15
      src/views/indes.vue
  5. 1 1
      src/views/my.vue

+ 1 - 1
src/router/index.js

@@ -53,7 +53,7 @@ export default new Router({
53
       },
53
       },
54
     },
54
     },
55
     {
55
     {
56
-      path: '/main/incidentList/:type/:isToday?',
56
+      path: '/main/incidentList/:type/:status/:isToday?',
57
       name: 'IncidentList',
57
       name: 'IncidentList',
58
       component: IncidentList,
58
       component: IncidentList,
59
       meta: {
59
       meta: {

+ 1 - 1
src/views/Main.vue

@@ -8,7 +8,7 @@
8
                 <i class="iconfont icon-shouyexian"></i>
8
                 <i class="iconfont icon-shouyexian"></i>
9
                 <span>首页</span>
9
                 <span>首页</span>
10
             </router-link>
10
             </router-link>
11
-            <router-link to="/main/incidentList/todo/" class="link" active-class="active">
11
+            <router-link to="/main/incidentList/todo/0" class="link" active-class="active">
12
                 <i class="iconfont icon-baoxiuxian"></i>
12
                 <i class="iconfont icon-baoxiuxian"></i>
13
                 <span>事件</span>
13
                 <span>事件</span>
14
             </router-link>
14
             </router-link>

+ 3 - 0
src/views/incidentList.vue

@@ -422,6 +422,9 @@ export default {
422
           this.searchType = "all";
422
           this.searchType = "all";
423
         }
423
         }
424
       }
424
       }
425
+      if(this.$route.params.status){
426
+        this.searchState = this.$route.params.status ? Number(this.$route.params.status) : 0;
427
+      }
425
     },
428
     },
426
     typeChange() {
429
     typeChange() {
427
       this.loadShow = true;
430
       this.loadShow = true;

+ 15 - 15
src/views/indes.vue

@@ -39,22 +39,24 @@
39
       <!-- 统计信息 -->
39
       <!-- 统计信息 -->
40
       <div
40
       <div
41
         class="newStatistics"
41
         class="newStatistics"
42
-        v-if="!newStatisticsLoading && isShowNewStatistics"
42
+        v-if="!newStatisticsLoading && isShowNewStatistics && isAll"
43
       >
43
       >
44
         <div class="buildOrder">
44
         <div class="buildOrder">
45
           <div
45
           <div
46
             class="buildOrderItem" 
46
             class="buildOrderItem" 
47
-            @click="goTo('/main/incidentList/all/today')"
47
+            @click="goTo('/main/incidentList/all/0/today')"
48
           >
48
           >
49
             <div class="s_num">{{ newStatistics.createOrders }}</div>
49
             <div class="s_num">{{ newStatistics.createOrders }}</div>
50
             <div>今日建单</div>
50
             <div>今日建单</div>
51
           </div>
51
           </div>
52
           <div
52
           <div
53
             class="buildOrderItem" 
53
             class="buildOrderItem" 
54
-            @click="goTo('/main/incidentList/todo/')"
54
+            @click="goTo('/main/incidentList/all/1544')"
55
           >
55
           >
56
-            <div class="s_num">{{ newStatistics.todoOrders }}</div>
57
-            <div>待处理</div>
56
+            <!-- <div class="s_num">{{ newStatistics.todoOrders }}</div> -->
57
+            <div class="s_num">{{ newStatistics.doingOrders }}</div>
58
+            <!-- <div>待处理</div> -->
59
+            <div>所有处理中</div>
58
           </div>
60
           </div>
59
         </div>
61
         </div>
60
         <div class="attendance" v-if="ifWorking == 1">
62
         <div class="attendance" v-if="ifWorking == 1">
@@ -267,14 +269,12 @@ export default {
267
         errorCount: 0 //今日迟到
269
         errorCount: 0 //今日迟到
268
       }, //统计数据
270
       }, //统计数据
269
       newStatisticsLoading: false, //统计数据Loading
271
       newStatisticsLoading: false, //统计数据Loading
270
-      isShowNewStatistics: false
272
+      isShowNewStatistics: true
271
     };
273
     };
272
   },
274
   },
273
   methods: {
275
   methods: {
274
     goTo(url){
276
     goTo(url){
275
-      if(this.isAll){
276
-        this.$router.push(url);
277
-      }
277
+      this.$router.push(url);
278
     },
278
     },
279
     scan() {
279
     scan() {
280
       // this.$router.push({name:'ScanResult',params:{data:'[{"name":"资产名称","value":"哈哈哈"},{"name":"数量","value":"12"}]'}});
280
       // this.$router.push({name:'ScanResult',params:{data:'[{"name":"资产名称","value":"哈哈哈"},{"name":"数量","value":"12"}]'}});
@@ -357,7 +357,7 @@ export default {
357
       this.$router.push({ path: "/noticeList" });
357
       this.$router.push({ path: "/noticeList" });
358
     },
358
     },
359
     toIncidentList(searchType) {
359
     toIncidentList(searchType) {
360
-      this.$router.push({ path: "/main/incidentList/" + searchType + '/' });
360
+      this.$router.push({ path: "/main/incidentList/" + searchType + '/0' });
361
     },
361
     },
362
     // toKnowList() {
362
     // toKnowList() {
363
     //   this.$router.push({ path: "/knowList" });
363
     //   this.$router.push({ path: "/knowList" });
@@ -401,11 +401,11 @@ export default {
401
     if (menu) {
401
     if (menu) {
402
       this.isAll = menu.some(v => v.link == "shijianliebiao_all");
402
       this.isAll = menu.some(v => v.link == "shijianliebiao_all");
403
     }
403
     }
404
-    this.isShowNewStatistics = this.loginUser.role.some(
405
-      v =>
406
-        v.rolecode == "incident-category-manager" ||
407
-        v.rolecode == "incident manager"
408
-    );
404
+    // this.isShowNewStatistics = this.loginUser.role.some(
405
+    //   v =>
406
+    //     v.rolecode == "incident-category-manager" ||
407
+    //     v.rolecode == "incident manager"
408
+    // );
409
     var that = this;
409
     var that = this;
410
     that.valConfig = JSON.parse(localStorage.getItem("valConfig")) - 0;
410
     that.valConfig = JSON.parse(localStorage.getItem("valConfig")) - 0;
411
     that.loginUser.group.forEach(element => {
411
     that.loginUser.group.forEach(element => {

+ 1 - 1
src/views/my.vue

@@ -286,7 +286,7 @@ export default {
286
     // 跳转到事件列表
286
     // 跳转到事件列表
287
     toIncidentList(searchType) {
287
     toIncidentList(searchType) {
288
       if(!(searchType === 'all' && !this.isAll)){
288
       if(!(searchType === 'all' && !this.isAll)){
289
-        this.$router.push({ path: "/main/incidentList/" + searchType + '/' });
289
+        this.$router.push({ path: "/main/incidentList/" + searchType + '/0' });
290
       }
290
       }
291
     },
291
     },
292
     // 巡检列表
292
     // 巡检列表