Ver código fonte

Merge branch 'master' of http://101.36.160.140:21044/csc/csc-szls-vue

GaoYuPeng 3 anos atrás
pai
commit
3f1ad2ed92

+ 16 - 0
shanXiPlatform/src/api/branchoff/index.js

@@ -56,3 +56,19 @@ export function  getjfqk( depotId , homeType) {
56 56
     method: 'get'
57 57
   })
58 58
 }
59
+
60
+export function  getmorehyd( data  ) {
61
+  return request({              
62
+    url: `/csc-szls-business/sysUserActivity/getByPage`,
63
+    method: 'post',
64
+    data : data
65
+  })
66
+}
67
+export function  gethyd( depotId , homeType) {
68
+  return request({
69
+    url: `/csc-szls-business/sysUserActivity/getGroupByDepotId?depotId=${depotId}&homeType=${homeType} `,
70
+    method: 'get'
71
+  })
72
+}
73
+
74
+

+ 65 - 3
shanXiPlatform/src/router/index.js

@@ -232,6 +232,14 @@ export const constantRoutes = [
232 232
                   hidden: true,
233 233
                   meta: { title: '详情', icon: 'dashboard', affix: false }
234 234
                 },
235
+                { // 针对熏蒸
236
+                  path: 'inixunzengDetails',
237
+                  component: () => import('@/views/home/daiBan/initiated/xunzengDetails'),
238
+                  name: 'IniXunzengDetails',
239
+
240
+                  hidden: true,
241
+                  meta: { title: '详情', icon: 'dashboard', affix: false }
242
+                },
235 243
               ]
236 244
 
237 245
           },
@@ -254,6 +262,14 @@ export const constantRoutes = [
254 262
                   hidden: true,
255 263
                   meta: { title: '详情', icon: 'dashboard', affix: false }
256 264
                 },
265
+                { // 针对熏蒸
266
+                  path: 'xunzengDetails',
267
+                  component: () => import('@/views/home/daiBan/pending/xunzengDetails'),
268
+                  name: 'XunzengDetails',
269
+
270
+                  hidden: true,
271
+                  meta: { title: '详情', icon: 'dashboard', affix: false }
272
+                },
257 273
               ]
258 274
           },
259 275
           {
@@ -275,6 +291,14 @@ export const constantRoutes = [
275 291
                   hidden: true,
276 292
                   meta: { title: '详情', icon: 'dashboard', affix: false }
277 293
                 },
294
+                { // 针对熏蒸
295
+                  path: 'xunzengDetails',
296
+                  component: () => import('@/views/home/daiBan/processed/xunzengDetails'),
297
+                  name: 'proXunzengDetails',
298
+
299
+                  hidden: true,
300
+                  meta: { title: '详情', icon: 'dashboard', affix: false }
301
+                },
278 302
               ]
279 303
           },
280 304
 
@@ -361,6 +385,20 @@ export const constantRoutes = [
361 385
         hidden: true,
362 386
         meta: { title: '工作完成情况', icon: 'dashboard',isshowLibrary:true, affix: true },
363 387
       },
388
+      {
389
+        path: 'hydtable',
390
+        component: () => import('@/views/home/hydtable'),
391
+        name: 'hydtable',
392
+        hidden: true,
393
+        meta: { title: '在线活跃度详情', icon: 'dashboard',isshowLibrary:true, affix: true },
394
+      },
395
+      {
396
+        path: 'hydmoretable',
397
+        component: () => import('@/views/home/hydmoretable'),
398
+        name: 'hydmoretable',
399
+        hidden: true,
400
+        meta: { title: '在线活跃度', icon: 'dashboard',isshowLibrary:true, affix: true },
401
+      },
364 402
     ]
365 403
 
366 404
   },
@@ -465,6 +503,14 @@ export const constantRoutes = [
465 503
                   hidden: true,
466 504
                   meta: { title: '详情', icon: 'dashboard', affix: false, navigation: true }
467 505
                 },
506
+                { // 针对熏蒸
507
+                  path: 'inixunzengDetails',
508
+                  component: () => import('@/views/home/daiBan/initiated/xunzengDetails'),
509
+                  name: 'IniXunzengDetails',
510
+
511
+                  hidden: true,
512
+                  meta: { title: '详情', icon: 'dashboard', affix: false }
513
+                },
468 514
               ]
469 515
 
470 516
           },
@@ -489,6 +535,14 @@ export const constantRoutes = [
489 535
                   hidden: true,
490 536
                   meta: { title: '详情', icon: 'dashboard', affix: false, navigation: true }
491 537
                 },
538
+                { // 针对熏蒸
539
+                  path: 'xunzengDetails',
540
+                  component: () => import('@/views/home/daiBan/pending/xunzengDetails'),
541
+                  name: 'XunzengDetails',
542
+
543
+                  hidden: true,
544
+                  meta: { title: '详情', icon: 'dashboard', affix: false }
545
+                },
492 546
               ]
493 547
           },
494 548
           {
@@ -510,6 +564,14 @@ export const constantRoutes = [
510 564
                   hidden: true,
511 565
                   meta: { title: '详情', icon: 'dashboard', affix: false, navigation: true }
512 566
                 },
567
+                { // 针对熏蒸
568
+                  path: 'xunzengDetails',
569
+                  component: () => import('@/views/home/daiBan/processed/xunzengDetails'),
570
+                  name: 'proXunzengDetails',
571
+
572
+                  hidden: true,
573
+                  meta: { title: '详情', icon: 'dashboard', affix: false }
574
+                },
513 575
               ]
514 576
           },
515 577
 
@@ -707,7 +769,7 @@ export const constantRoutes = [
707 769
             name: 'AllGrain',
708 770
 
709 771
             hidden: true,
710
-            meta: { title: '最新粮情检查记录', icon: 'dashboard', affix: false, relation: 'house', istable: true },
772
+            meta: { title: '全部粮情检查记录', icon: 'dashboard', affix: false, relation: 'house', istable: true },
711 773
           },
712 774
 
713 775
 
@@ -765,7 +827,7 @@ export const constantRoutes = [
765 827
         component: () => import('@/views/reservesManagement/fumigationManagement/index'),
766 828
         name: 'FumigationManagement',
767 829
         meta: { title: '熏蒸管理', icon: 'tongfeng', affix: false, relation: 'house', istable: true },
768
-        resourceCode: 169
830
+        resourceCode: 337
769 831
       },
770 832
       //  储量管理/熏蒸管理/新增
771 833
       {
@@ -1536,7 +1598,7 @@ export const constantRoutes = [
1536 1598
         path: 'treeStructure',
1537 1599
         component: () => import('@/views/systemManagement/tree/treeStructure'),
1538 1600
         name: 'TreeStructure',
1539
-        hidden: true,
1601
+        // hidden: true,
1540 1602
         meta: { title: '组织树', icon: 'zuzhishu', affix: false, noCache: true, navigation: true },
1541 1603
         resourceCode:5,
1542 1604
         children: []

+ 200 - 151
shanXiPlatform/src/views/home/branchOffice.vue

@@ -229,7 +229,7 @@
229 229
                                 <p class="lsp">
230 230
                                     <img src="../../assets/images/rightarrow.png" alt />
231 231
                                     上月在线活跃度排名
232
-                                    <span v-if="crumbs.length != 2" class="echartSpan" @click="yclq()">更多>></span>
232
+                                    <span v-if="crumbs.length != 2" class="echartSpan" @click="hyd()">更多>></span>
233 233
                                 </p>
234 234
                                 <div id="myChartrt" class="rtoprto"></div>
235 235
                                 <!-- <img src="../../assets/images/huoyue.png" alt /> -->
@@ -270,7 +270,9 @@ import {
270 270
     getpointll,
271 271
     getzxt,
272 272
     getmorejfqk,
273
-    getjfqk
273
+    getjfqk,
274
+    // ,
275
+    gethyd
274 276
 } from "@/api/branchoff/index.js"
275 277
 import { getUser } from "@/utils/auth"
276 278
 export default {
@@ -996,171 +998,208 @@ export default {
996 998
             this.$router.push({ path: "/countQuality/warehouseInformation" })
997 999
         },
998 1000
         drawtrt() {
999
-            var chartData = [6, 7, 8, 9, 10, 10, 9, 8, 7, 6] // 数据
1000
-            var chartDataone = [10, 10, 10, 10, 10, 10, 10, 10, 10, 10] // 数据
1001
-            var chartName = [
1002
-                "中央储备大同直属库有限公司",
1003
-                "中央储备太原直属库有限公司",
1004
-                "中央储备太原直属库有限公司",
1005
-                "中央储备太原直属库有限公司",
1006
-                "中央储备太原直属库有限公司",
1007
-                "中央储备太原直属库有限公司",
1008
-                "中央储备太原直属库有限公司",
1009
-                "中央储备太原直属库有限公司",
1010
-                "中央储备太原直属库有限公司",
1011
-                "中央储备长治直属库有限公司"
1012
-            ]
1013
-            const myChartrt = this.$echarts.init(
1014
-                document.getElementById("myChartrt")
1015
-            )
1016
-            // 绘制图表
1017
-            myChartrt.setOption({
1018
-                grid: {
1019
-                    top: "3%",
1020
-                    left: "3%",
1021
-                    bottom: "3%",
1022
-                    right: "3%",
1023
-                    containLabel: true
1024
-                },
1025
-                xAxis: {
1026
-                    type: "value",
1027
-                    axisLine: {
1028
-                        lineStyle: {
1029
-                            color: "#ccc"
1030
-                        }
1001
+            gethyd(this.midprovinceid, this.homeType).then(res => {
1002
+                var chartDataone = [
1003
+                    100,
1004
+                    100,
1005
+                    100,
1006
+                    100,
1007
+                    100,
1008
+                    100,
1009
+                    100,
1010
+                    100,
1011
+                    100,
1012
+                    100,
1013
+                    100,
1014
+                    100,
1015
+                    100,
1016
+                    100,
1017
+                    100,
1018
+                    100,
1019
+                    100,
1020
+                    100,
1021
+                    100,
1022
+                    100,
1023
+                    100,
1024
+                    100,
1025
+                    100,
1026
+                    100,
1027
+                    100,
1028
+                    100,
1029
+                    100,
1030
+                    100,
1031
+                    100,
1032
+                    100,
1033
+                    100,
1034
+                    100,
1035
+                    100,
1036
+                    100,
1037
+                    100,
1038
+                    100,
1039
+                    100,
1040
+                    100,
1041
+                    100,
1042
+                    100,
1043
+                    100,
1044
+                    100,
1045
+                    100,
1046
+                    100,
1047
+                    100,
1048
+                    100
1049
+                ] // 数据
1050
+                var chartName = res.data.depotName
1051
+                var chartData = res.data.series
1052
+                const myChartrt = this.$echarts.init(
1053
+                    document.getElementById("myChartrt")
1054
+                )
1055
+                // 绘制图表
1056
+                myChartrt.setOption({
1057
+                    grid: {
1058
+                        top: "3%",
1059
+                        left: "3%",
1060
+                        bottom: "3%",
1061
+                        right: "3%",
1062
+                        containLabel: true
1031 1063
                     },
1032
-                    show: false,
1033
-                    splitLine: {
1034
-                        show: false
1035
-                    }
1036
-                },
1037
-                yAxis: [
1038
-                    {
1039
-                        type: "category",
1040
-                        data: chartName,
1041
-                        splitLine: {
1042
-                            show: false
1043
-                        },
1044
-                        show: false,
1064
+                    xAxis: {
1065
+                        type: "value",
1045 1066
                         axisLine: {
1046 1067
                             lineStyle: {
1047 1068
                                 color: "#ccc"
1048 1069
                             }
1049
-                        }
1050
-                    },
1051
-                    {
1052
-                        // 第二个y轴 为了让数据在右侧末尾显示
1053
-                        show: true,
1054
-                        inverse: true,
1055
-                        data: chartData,
1056
-                        nameTextStyle: {}, // 坐标轴名称的文字样式。 官网上是这样的解释, 但是 我试了这个并不能改变坐标轴的文字样式
1057
-                        axisLabel: {
1058
-                            textStyle: {
1059
-                                fontSize: 12, // 坐标轴名称的大小
1060
-                                color: "#333", // 坐标轴名称的颜色
1061
-                                fontWeight: 700
1062
-                            }
1063
-                        },
1064
-                        axisLine: {
1065
-                            show: false,
1066
-                            lineStyle: {
1067
-                                color: "#8CC4A1"
1068
-                            }
1069 1070
                         },
1071
+                        show: false,
1070 1072
                         splitLine: {
1071
-                            show: true
1072
-                        },
1073
-                        axisTick: {
1074
-                            show: true
1075
-                        },
1076
-                        data: chartData
1077
-                    }
1078
-                ],
1079
-                series: [
1080
-                    {
1081
-                        name: "我是打底",
1082
-                        type: "pictorialBar",
1083
-                        symbol: "rect", // 类型
1084
-                        yAxisIndex: 0,
1085
-                        barWidth: 10,
1086
-                        itemStyle: {
1087
-                            normal: {
1088
-                                // barBorderRadius: 5,
1089
-                                color: "#ccc"
1090
-                            }
1091
-                        },
1092
-                        label: {
1093
-                            normal: {
1094
-                                position: "right"
1095
-                            }
1096
-                        },
1097
-                        symbolRepeat: true,
1098
-                        // symbolRotate: '45',
1099
-                        symbolSize: [10, 16],
1100
-                        // symbolMargin: 2,
1101
-                        data: chartDataone
1102
-                    },
1103
-                    {
1104
-                        name: "我是上层方块",
1105
-                        type: "pictorialBar",
1106
-                        symbol: "rect",
1107
-                        itemStyle: {
1108
-                            normal: {
1109
-                                color: "green"
1110
-                            }
1111
-                        },
1112
-                        label: {
1113
-                            normal: {
1114
-                                // show: true, // 数据大小的显示, 100 200 300
1115
-                                textStyle: {
1116
-                                    color: "#000000" // 颜色
1117
-                                },
1118
-                                position: "right"
1119
-                            }
1120
-                        },
1121
-                        barWidth: 10,
1122
-                        symbolRepeat: true,
1123
-                        // symbolRotate: '45',
1124
-                        symbolSize: [10, 16],
1125
-                        // symbolMargin: 2,
1126
-                        data: chartData
1073
+                            show: false
1074
+                        }
1127 1075
                     },
1128
-                    // 数据条--------------------我是分割线君------------------------------//
1129
-                    {
1130
-                        show: true,
1131
-                        type: "bar",
1132
-                        // xAxisIndex: 1, //代表使用第二个X轴刻度
1133
-                        barGap: "-150%",
1134
-                        barWidth: "25%",
1135
-                        itemStyle: {
1136
-                            normal: {
1137
-                                barBorderRadius: 50,
1138
-                                // color: 'yellow',
1139
-                                color: "transparent" // rgba(22,203,115,0.05) 数据条柱状图的填充颜色,, 一开始我的有一点点背景颜色
1076
+                    yAxis: [
1077
+                        {
1078
+                            type: "category",
1079
+                            data: chartName,
1080
+                            splitLine: {
1081
+                                show: false
1082
+                            },
1083
+                            show: false,
1084
+                            axisLine: {
1085
+                                lineStyle: {
1086
+                                    color: "#ccc"
1087
+                                }
1140 1088
                             }
1141 1089
                         },
1142
-                        label: {
1143
-                            normal: {
1144
-                                show: true,
1145
-                                position: [-160, 0],
1090
+                        {
1091
+                            // 第二个y轴 为了让数据在右侧末尾显示
1092
+                            show: true,
1093
+                            inverse: true,
1094
+                            data: chartData,
1095
+                            nameTextStyle: {}, // 坐标轴名称的文字样式。 官网上是这样的解释, 但是 我试了这个并不能改变坐标轴的文字样式
1096
+                            axisLabel: {
1146 1097
                                 textStyle: {
1147
-                                    fontSize: 12,
1148
-                                    color: "#666",
1098
+                                    fontSize: 12, // 坐标轴名称的大小
1099
+                                    color: "#333", // 坐标轴名称的颜色
1149 1100
                                     fontWeight: 700
1150
-                                },
1151
-                                formatter: function(data) {
1152
-                                    return chartName[data.dataIndex]
1153 1101
                                 }
1154
-                            }
1102
+                            },
1103
+                            axisLine: {
1104
+                                show: false,
1105
+                                lineStyle: {
1106
+                                    color: "#8CC4A1"
1107
+                                }
1108
+                            },
1109
+                            splitLine: {
1110
+                                show: true
1111
+                            },
1112
+                            axisTick: {
1113
+                                show: true
1114
+                            },
1115
+                            data: chartData
1116
+                        }
1117
+                    ],
1118
+                    series: [
1119
+                        {
1120
+                            name: "我是打底",
1121
+                            type: "pictorialBar",
1122
+                            symbol: "rect", // 类型
1123
+                            yAxisIndex: 0,
1124
+                            barWidth: 10,
1125
+                            itemStyle: {
1126
+                                normal: {
1127
+                                    // barBorderRadius: 5,
1128
+                                    color: "#ccc"
1129
+                                }
1130
+                            },
1131
+                            label: {
1132
+                                normal: {
1133
+                                    position: "right"
1134
+                                }
1135
+                            },
1136
+                            symbolRepeat: true,
1137
+                            // symbolRotate: '45',
1138
+                            symbolSize: [10, 16],
1139
+                            // symbolMargin: 2,
1140
+                            data: chartDataone
1155 1141
                         },
1156
-                        data: chartDataone
1157
-                    }
1158
-                ]
1142
+                        {
1143
+                            name: "我是上层方块",
1144
+                            type: "pictorialBar",
1145
+                            symbol: "rect",
1146
+                            itemStyle: {
1147
+                                normal: {
1148
+                                    color: "green"
1149
+                                }
1150
+                            },
1151
+                            label: {
1152
+                                normal: {
1153
+                                    // show: true, // 数据大小的显示, 100 200 300
1154
+                                    textStyle: {
1155
+                                        color: "#000000" // 颜色
1156
+                                    },
1157
+                                    position: "right"
1158
+                                }
1159
+                            },
1160
+                            barWidth: 10,
1161
+                            symbolRepeat: true,
1162
+                            // symbolRotate: '45',
1163
+                            symbolSize: [10, 16],
1164
+                            // symbolMargin: 2,
1165
+                            data: chartData
1166
+                        },
1167
+                        // 数据条--------------------我是分割线君------------------------------//
1168
+                        {
1169
+                            show: true,
1170
+                            type: "bar",
1171
+                            // xAxisIndex: 1, //代表使用第二个X轴刻度
1172
+                            barGap: "-150%",
1173
+                            barWidth: "25%",
1174
+                            itemStyle: {
1175
+                                normal: {
1176
+                                    barBorderRadius: 50,
1177
+                                    // color: 'yellow',
1178
+                                    color: "transparent" // rgba(22,203,115,0.05) 数据条柱状图的填充颜色,, 一开始我的有一点点背景颜色
1179
+                                }
1180
+                            },
1181
+                            label: {
1182
+                                normal: {
1183
+                                    show: true,
1184
+                                    position: [-240, 0],
1185
+                                    textStyle: {
1186
+                                        fontSize: 12,
1187
+                                        color: "#666",
1188
+                                        fontWeight: 700
1189
+                                    },
1190
+                                    formatter: function(data) {
1191
+                                        return chartName[data.dataIndex]
1192
+                                    }
1193
+                                }
1194
+                            },
1195
+                            data: chartDataone
1196
+                        }
1197
+                    ]
1198
+                })
1159 1199
             })
1160 1200
         },
1161 1201
         drawtrb() {
1162
-            getjfqk(this.midprovinceid , this.homeType ).then(res => {
1163
-                console.log( res.data , '777777777777777777777777777777777777777777777777777777777777777777777777' )
1202
+            getjfqk(this.midprovinceid, this.homeType).then(res => {
1164 1203
                 const myChartrb = this.$echarts.init(
1165 1204
                     document.getElementById("myChartrb")
1166 1205
                 )
@@ -1260,7 +1299,8 @@ export default {
1260 1299
                 name: "yclqTable",
1261 1300
                 query: {
1262 1301
                     depotId: this.midprovinceid,
1263
-                    midprovinceName: this.midprovinceName
1302
+                    midprovinceName: this.midprovinceName,
1303
+                    isshow: this.isxian
1264 1304
                 }
1265 1305
             })
1266 1306
         },
@@ -1273,6 +1313,15 @@ export default {
1273 1313
                 }
1274 1314
             })
1275 1315
         },
1316
+        hyd() {
1317
+            this.$router.push({
1318
+                name: "hydtable",
1319
+                query: {
1320
+                    depotId: this.midprovinceid,
1321
+                    midprovinceName: this.midprovinceName
1322
+                }
1323
+            })
1324
+        },
1276 1325
     }
1277 1326
 }
1278 1327
 </script>

+ 519 - 0
shanXiPlatform/src/views/home/daiBan/initiated/xunzengDetails.vue

@@ -0,0 +1,519 @@
1
+<template>
2
+  <div id="penmainDetail">
3
+    <div class="pencontainDetail">
4
+      <div class="lc_top">
5
+        <div class="header" style="font-weight: 500">
6
+          <i class="iconfont iconshu"></i>
7
+          {{workName }}
8
+        </div>
9
+        <div class="middle">
10
+          <div class="middle_flex"  v-if="workName.indexOf('药剂') == -1">
11
+            <div>仓号:</div>
12
+            <div>{{houseName }}</div>
13
+          </div>
14
+          <div class="middle_flex">
15
+            <div>申请人:</div>
16
+            <div>{{applyName }}</div>
17
+          </div>
18
+          <div class="middle_flex">
19
+            <div>申请部门:</div>
20
+            <div>{{departmentName }}</div>
21
+          </div>
22
+          <div class="middle_flex">
23
+            <div>公司:</div>
24
+            <div>{{companyName }}</div>
25
+          </div>
26
+        </div>
27
+      </div>
28
+      <div class="table_middle">
29
+        <div style="margin-left: 20px">
30
+          <span v-if="type == 'tf'">1.制定通风方案:</span>
31
+          <span v-if="type == 'xzjh'">1.制定熏蒸计划:</span>
32
+          <span v-if="this.subData == 1">否</span>
33
+          <span v-if="this.subData == 0">是</span>
34
+        </div>
35
+      </div>
36
+      <div id="process">
37
+        <div class="process_title" style="font-weight: 500">
38
+          <i class="iconfont iconshu"></i>
39
+          流程({{workName}}审批)
40
+        </div>
41
+        <div class="process_step" style="margin-left: 20px">
42
+          <el-steps direction="vertical" :active="processActive">
43
+            <el-step
44
+              v-for="(item, index) in process"
45
+              :key="index"
46
+              icon="el-icon-edit"
47
+            >
48
+              <template>
49
+                <div slot="title" class="stepTitle">
50
+                  <div class="stepTitleFont">
51
+                    {{ item.title }}
52
+                  </div>
53
+
54
+                  <div style="width: 200px">
55
+                    <div
56
+                      style="font-weight: 500"
57
+                      :class="{
58
+                        active:
59
+                          index == 0 ||
60
+                          (item.auditState != null && item.auditState == 1),
61
+                        noActive: item.auditState == 2,
62
+                      }"
63
+                    >
64
+                      {{ perList[item.content] }}
65
+                    </div>
66
+                    <div v-if="item.auditState == 0">待审批</div>
67
+                    <div v-if="item.auditState == 1" class="stepTitleFont">
68
+                      审批通过
69
+                    </div>
70
+                    <div v-if="item.auditState == 2">审批不通过</div>
71
+                    <div class="stepTitleFont">{{ item.auditTime }}</div>
72
+
73
+                    <div style="width: 200px; display: flex">
74
+                      <!-- 状态为0且为当前登录人时按钮显示 -->
75
+                      <el-button
76
+                        type="danger"
77
+                        size="mini"
78
+                        v-if="
79
+                          item.content == userInfo.uid && item.auditState == 0
80
+                        "
81
+                        @click="noAgree(item, index)"
82
+                        >审批不通过</el-button
83
+                      >
84
+                      <el-button
85
+                        type="success"
86
+                        size="mini"
87
+                        v-if="
88
+                          item.content == userInfo.uid && item.auditState == 0
89
+                        "
90
+                        @click="agree(item, index)"
91
+                        >审批通过</el-button
92
+                      >
93
+                    </div>
94
+                  </div>
95
+                </div>
96
+              </template>
97
+            
98
+              <template>
99
+                <i
100
+                  slot="icon"
101
+                  class="iconfont iconstep_current"
102
+                  v-if="
103
+                    index != 0 &&
104
+                    (item.auditState == null || item.auditState == 0)
105
+                  "
106
+                >
107
+                </i>
108
+                <i
109
+                  slot="icon"
110
+                  style="color: red"
111
+                  class="iconfont iconstep_err"
112
+                  v-if="item.auditState == 2"
113
+                ></i>
114
+                <i
115
+                  slot="icon"
116
+                  style="color: green"
117
+                  class="iconfont iconstep_complete"
118
+                  v-if="item.auditState == 1 || index == 0"
119
+                ></i>
120
+              </template>
121
+            </el-step>
122
+          </el-steps>
123
+        </div>
124
+      </div>
125
+      <div class="btns">
126
+        <el-button class="backBtn" type="success" plain @click="goBack()"
127
+          >返回</el-button
128
+        >
129
+      </div>
130
+    </div>
131
+  </div>
132
+</template>
133
+<script>
134
+import { checkList } from "@/api/reservesManagement/mechanicalVentilation"
135
+import { Approval, yjcgApproval } from "@/api/daiBan/index"
136
+import { getNowFormatDate } from "@/utils"
137
+import { getUser } from "@/utils/auth"
138
+import { pending } from "@/api/daiBan/index"
139
+import { processed } from "@/api/daiBan/index"
140
+export default {
141
+  name: "Details",
142
+  data() {
143
+    return {
144
+      //类型
145
+      workName: "",
146
+      //仓房编码
147
+      houseName: null,
148
+      //申请人
149
+      applyName: null,
150
+      //部门
151
+      departmentName: null,
152
+      //公司
153
+      companyName: null,
154
+      //库字典数据
155
+      deportDic: {},
156
+      //仓房字典数据
157
+      hourseDic: {},
158
+      //部门字典数据
159
+      departDic: {},
160
+      //每条数据
161
+      row: {},
162
+
163
+      //当前登录人信息
164
+      userInfo: {},
165
+
166
+      //审批状态
167
+      auditState: null,
168
+      //审批流程高亮显示
169
+      processActive: 0,
170
+      //审批流程
171
+      process: [],
172
+      //用户字典列表
173
+      perList: {},
174
+      //
175
+      tableData: [],
176
+      //头部数据
177
+      headData: [],
178
+      //方案状态
179
+      subData: null,
180
+      //审批数据
181
+      applyData: [],
182
+      type: null
183
+    }
184
+  },
185
+  methods: {
186
+    //流程查看
187
+    getCheckList() {
188
+      var processId = this.row.processId
189
+      checkList(processId)
190
+        .then((res) => {
191
+          console.log(res.data, "......")
192
+          if (res.code == 200) {
193
+            
194
+
195
+            let ongoingStep = this.ongoingStep
196
+            this.subData = res.data.process[ongoingStep].list[0].subData  //方案状态
197
+            this.tableData = res.data.process[ongoingStep]
198
+
199
+            for (let i = 0; i < res.data.process[ongoingStep].audit.length; i++) {
200
+              var ele = res.data.process[ongoingStep].audit[i]
201
+              if (ele.auditState != null) {
202
+                this.processActive = i
203
+              }
204
+              this.process.push(ele)
205
+              if (this.process[0].content == 0) {
206
+                this.process[0].content = this.userInfo.uid
207
+              } else {
208
+                this.process[0].content = res.data.process[ongoingStep].audit[0].content
209
+              }
210
+            }
211
+            this.getProcessed()
212
+          }
213
+        })
214
+        .catch((err) => {
215
+          console.log(err)
216
+        })
217
+    },
218
+
219
+    //机械通风审批通过接口
220
+    getApproval() {
221
+      var data = {
222
+        id: this.row.id,
223
+        auditState: this.auditState,
224
+        // 进行到哪一步的主流程id
225
+        ongoingStep: this.ongoingStep,
226
+        auditTime: getNowFormatDate(),
227
+      }
228
+      Approval(data)
229
+        .then((res) => {
230
+          sessionStorage.setItem("store", JSON.stringify(this.$store.state))
231
+          // location.reload();
232
+
233
+          this.$store.commit({
234
+            type: "changependingCount",
235
+            pendingCount: this.$store.state.pendingCount,
236
+          })
237
+
238
+          this.getCheckList()
239
+          this.getPending()
240
+          this.$router.push({
241
+            path: "/dashboard/daiban/initiated/xunzengDetails",
242
+            item: this.$route.query,
243
+          })
244
+        })
245
+        .catch((err) => {
246
+          console.log(err)
247
+        })
248
+    },
249
+
250
+    //药剂采购审批通过接口
251
+    getyjcgApproval() {
252
+      var data = {
253
+        id: this.row.id,
254
+        auditState: this.auditState,
255
+        ongoingStep: this.ongoingStep,
256
+        auditTime: getNowFormatDate(),
257
+      }
258
+      yjcgApproval(data)
259
+        .then((res) => {
260
+          sessionStorage.setItem("store", JSON.stringify(this.$store.state))
261
+          // location.reload();
262
+
263
+          this.$store.commit({
264
+            type: "changependingCount",
265
+            pendingCount: this.$store.state.pendingCount,
266
+          })
267
+
268
+          this.getCheckList()
269
+          this.getPending()
270
+          this.$router.push({
271
+            path: "/dashboard/daiban/initiated/xunzengDetails",
272
+            item: this.$route.query,
273
+          })
274
+        }) 
275
+        .catch((err) => {
276
+          console.log(err)
277
+        })
278
+    },
279
+    //审批不通过
280
+
281
+    noAgree(item, index) {
282
+      this.$confirm("确定审批不通过?", "提示", {
283
+        confirmButtonText: "确定",
284
+        cancelButtonText: "返回",
285
+        type: "warning",
286
+      })
287
+        .then(() => {
288
+          this.auditState = 2
289
+
290
+          // this.ongoingStep = 0
291
+           this.ongoingStep=this.ongoingStep
292
+          this.process = []
293
+          //this.getApproval()
294
+          if (item.type == "yjcg" || item.type == "xzjh") {
295
+            this.getyjcgApproval()
296
+          } else {
297
+            this.getApproval()
298
+          }
299
+          item.auditState = 2
300
+        })
301
+        .catch(() => {})
302
+    },
303
+
304
+    //审批通过
305
+    agree(item, index) {
306
+      console.log(item, "??????????")
307
+      console.log(index, "index......")
308
+      //最后一个人通过
309
+      if (index == this.process.length - 1) {
310
+        if(item.type == "yjcg"){
311
+          this.auditState = 4
312
+        }else{
313
+           this.auditState = 3
314
+        }
315
+       
316
+      
317
+        // this.ongoingStep = 1
318
+        this.ongoingStep=this.ongoingStep+1
319
+        console.log('审批后的ongoingStep'+this.ongoingStep)
320
+      } else {
321
+        this.auditState = 1
322
+     
323
+
324
+        // this.ongoingStep = 0
325
+         this.ongoingStep=this.ongoingStep
326
+         console.log('审批前的ongoingStep'+this.ongoingStep)
327
+      }
328
+
329
+      this.process = []
330
+      this.$message(
331
+        {
332
+          message:"审批通过",
333
+          type: 'success'
334
+        })
335
+      if (item.type == "yjcg" || item.type == "xzjh") {
336
+        this.getyjcgApproval()
337
+      } else {
338
+        this.getApproval()
339
+      }
340
+    },
341
+    //点击返回按钮
342
+    goBack() {
343
+      this.$router.push({ path: "/home/daiban/initiated" })
344
+    },
345
+
346
+    //已处理列表数据
347
+    getProcessed() {
348
+      var condition = {
349
+        userId: this.userInfo.uid,
350
+      }
351
+      // console.log(condition, "condition.....")
352
+      condition = JSON.stringify(condition)
353
+      var data = {
354
+        pageIndex: 1,
355
+        pageSize: 10,
356
+        condition: condition,
357
+      }
358
+      processed(data).then((res) => {
359
+        if (res.code == 200) {
360
+          console.log(res)
361
+          this.processedList = res.data.records
362
+
363
+          this.$store.commit({
364
+            type: "changeproCount",
365
+            proCount: res.data.total,
366
+          })
367
+          console.log(this.$store.state.proCount, "aaaaaa.")
368
+          console.log(res.data.total, "res.data.total....")
369
+          // sessionStorage.setItem("store", JSON.stringify(this.$store.state))
370
+          // this.pagination.total = res.data.total
371
+        }
372
+      })
373
+    },
374
+
375
+    //待处理列表数据
376
+    getPending() {
377
+      var condition = {
378
+        userId: JSON.parse(getUser()).uid,
379
+      }
380
+      condition = JSON.stringify(condition)
381
+      var data = {
382
+        pageIndex: 1,
383
+        pageSize: 10,
384
+        condition: condition,
385
+      }
386
+
387
+      pending(data).then((res) => {
388
+        if (res.code == 200) {
389
+          this.$store.commit({
390
+            type: "changependingCount",
391
+            pendingCount: res.data.total,
392
+          })
393
+        }
394
+      })
395
+    },
396
+  },
397
+  mounted() {
398
+    //库字典数据
399
+    this.deportDic = JSON.parse(localStorage.getItem("deportDic"))
400
+    console.log(this.deportDic, " this.deportDic...")
401
+
402
+    //部门字典数据
403
+    this.departDic = JSON.parse(localStorage.getItem("departDic"))
404
+    console.log(this.departDic, " this.departDic...")
405
+
406
+    //仓房字典数据
407
+    this.hourseDic = JSON.parse(localStorage.getItem("hourseDic"))
408
+    console.log(this.hourseDic, " this.hourseDic...")
409
+    //获取当前缓存的用户信息
410
+    // this.userInfo = JSON.parse(localStorage.getItem("userInfo"))
411
+    // console.log(this.userInfo, "this.userInfo.....")
412
+    this.userInfo = JSON.parse(getUser())
413
+    console.log(this.userInfo, "this.userInfo.....?????")
414
+    //用户字典
415
+    this.perList = JSON.parse(localStorage.getItem("perList"))
416
+    console.log(this.perList, "this.perList...")
417
+    //流程id
418
+    this.row = this.$route.query
419
+    console.log(this.row, "??????")
420
+
421
+    this.getCheckList()
422
+
423
+    this.houseName = this.$route.query.houseName
424
+    this.applyName = this.$route.query.applyName
425
+    this.departmentName = this.$route.query.departmentName
426
+    this.companyName = this.$route.query.companyName
427
+    this.workName = this.$route.query.workName
428
+    this.ongoingStep=parseInt(this.$route.query.ongoingStep)
429
+    this.type = this.$route.query.type
430
+  },
431
+}
432
+</script>
433
+
434
+<style lang="scss" scoped>
435
+.global {
436
+  padding-top: 0;
437
+}
438
+#penmainDetail {
439
+  height: 100%;
440
+  .pencontainDetail {
441
+    .lc_top {
442
+      height: 100px;
443
+      background: #fff;
444
+      border-radius: 6px;
445
+      padding: 10px;
446
+      .header {
447
+        font-size: 18px;
448
+        font-weight: 500;
449
+        height: 20%;
450
+        margin-bottom: 20px;
451
+        color: #037d41;
452
+      }
453
+      .middle {
454
+        margin-bottom: 20px;
455
+        width: 80%;
456
+        display: flex;
457
+        justify-content: space-between;
458
+        margin-left: 20px;
459
+        .middle_flex {
460
+          display: flex;
461
+          margin-bottom: 10px;
462
+        }
463
+      }
464
+    }
465
+
466
+    #process {
467
+      background: #fff;
468
+      border-radius: 6px;
469
+      margin-top: 10px;
470
+      padding: 10px;
471
+
472
+      border-radius: 4px;
473
+      .process_title {
474
+        color: #037d41;
475
+        font-size: 18px;
476
+        margin-bottom: 10px;
477
+      }
478
+      .process_step {
479
+        height: 400px;
480
+      }
481
+      .stepTitle {
482
+        display: flex;
483
+        justify-content: space-between;
484
+      }
485
+    }
486
+    .table_middle {
487
+      height: 70px;
488
+      line-height: 70px;
489
+      padding-left: 10px;
490
+      background: #fff;
491
+      border-radius: 6px;
492
+      margin-top: 10px;
493
+    }
494
+
495
+    .active {
496
+      color: #037d41;
497
+      // width: 500px;
498
+      // height: 40px;
499
+      // margin-top: 10px;
500
+    }
501
+    .noActive {
502
+      color: red;
503
+      // width: 500px;
504
+      // height: 40px;
505
+      // margin-top: 10px;
506
+    }
507
+  }
508
+
509
+  .stepTitle {
510
+    .stepTitleFont {
511
+      color: black;
512
+    }
513
+  }
514
+  .btns {
515
+    text-align: right;
516
+    margin-top: 20px;
517
+  }
518
+}
519
+</style>

+ 517 - 0
shanXiPlatform/src/views/home/daiBan/pending/xunzengDetails.vue

@@ -0,0 +1,517 @@
1
+<template>
2
+  <div id="penmainDetail">
3
+    <div class="pencontainDetail">
4
+      <div class="lc_top">
5
+        <div class="header" style="font-weight: 500">
6
+          <i class="iconfont iconshu"></i>
7
+          {{workName }}
8
+        </div>
9
+        <div class="middle">
10
+          <div class="middle_flex"  v-if="workName.indexOf('药剂') == -1">
11
+            <div>仓号:</div>
12
+            <div>{{houseName }}</div>
13
+          </div>
14
+          <div class="middle_flex">
15
+            <div>申请人:</div>
16
+            <div>{{applyName }}</div>
17
+          </div>
18
+          <div class="middle_flex">
19
+            <div>申请部门:</div>
20
+            <div>{{departmentName }}</div>
21
+          </div>
22
+          <div class="middle_flex">
23
+            <div>公司:</div>
24
+            <div>{{companyName }}</div>
25
+          </div>
26
+        </div>
27
+      </div>
28
+      <div class="table_middle">
29
+        <div style="margin-left: 20px">
30
+          <span v-if="type == 'tf'">1.制定通风方案:</span>
31
+          <span v-if="type == 'xzjh'">1.制定熏蒸计划:</span>
32
+          <span v-if="this.subData == 1">否</span>
33
+          <span v-if="this.subData == 0">是</span>
34
+        </div>
35
+      </div>
36
+      <div id="process">
37
+        <div class="process_title" style="font-weight: 500">
38
+          <i class="iconfont iconshu"></i>
39
+          流程({{workName}}审批)
40
+        </div>
41
+        <div class="process_step" style="margin-left: 20px">
42
+          <el-steps direction="vertical" :active="processActive">
43
+            <el-step
44
+              v-for="(item, index) in process"
45
+              :key="index"
46
+              icon="el-icon-edit"
47
+            >
48
+              <template>
49
+                <div slot="title" class="stepTitle">
50
+                  <div class="stepTitleFont">
51
+                    {{ item.title }}
52
+                  </div>
53
+
54
+                  <div style="width: 200px">
55
+                    <div
56
+                      style="font-weight: 500"
57
+                      :class="{
58
+                        active:
59
+                          index == 0 ||
60
+                          (item.auditState != null && item.auditState == 1),
61
+                        noActive: item.auditState == 2,
62
+                      }"
63
+                    >
64
+                      {{ perList[item.content] }}
65
+                    </div>
66
+                    <div v-if="item.auditState == 0">待审批</div>
67
+                    <div v-if="item.auditState == 1" class="stepTitleFont">
68
+                      审批通过
69
+                    </div>
70
+                    <div v-if="item.auditState == 2">审批不通过</div>
71
+                    <div class="stepTitleFont">{{ item.auditTime }}</div>
72
+
73
+                    <div style="width: 200px; display: flex">
74
+                      <!-- 状态为0且为当前登录人时按钮显示 -->
75
+                      <el-button
76
+                        type="danger"
77
+                        size="mini"
78
+                        v-if="
79
+                          item.content == userInfo.uid && item.auditState == 0
80
+                        "
81
+                        @click="noAgree(item, index)"
82
+                        >审批不通过</el-button
83
+                      >
84
+                      <el-button
85
+                        type="success"
86
+                        size="mini"
87
+                        v-if="
88
+                          item.content == userInfo.uid && item.auditState == 0
89
+                        "
90
+                        @click="agree(item, index)"
91
+                        >审批通过</el-button
92
+                      >
93
+                    </div>
94
+                  </div>
95
+                </div>
96
+              </template>
97
+            
98
+              <template>
99
+                <i
100
+                  slot="icon"
101
+                  class="iconfont iconstep_current"
102
+                  v-if="
103
+                    index != 0 &&
104
+                    (item.auditState == null || item.auditState == 0)
105
+                  "
106
+                >
107
+                </i>
108
+                <i
109
+                  slot="icon"
110
+                  style="color: red"
111
+                  class="iconfont iconstep_err"
112
+                  v-if="item.auditState == 2"
113
+                ></i>
114
+                <i
115
+                  slot="icon"
116
+                  style="color: green"
117
+                  class="iconfont iconstep_complete"
118
+                  v-if="item.auditState == 1 || index == 0"
119
+                ></i>
120
+              </template>
121
+            </el-step>
122
+          </el-steps>
123
+        </div>
124
+      </div>
125
+      <div class="btns">
126
+        <el-button class="backBtn" type="success" plain @click="goBack()"
127
+          >返回</el-button
128
+        >
129
+      </div>
130
+    </div>
131
+  </div>
132
+</template>
133
+<script>
134
+import { checkList } from "@/api/reservesManagement/mechanicalVentilation"
135
+import { Approval, yjcgApproval } from "@/api/daiBan/index"
136
+import { getNowFormatDate } from "@/utils"
137
+import { getUser } from "@/utils/auth"
138
+import { pending } from "@/api/daiBan/index"
139
+import { processed } from "@/api/daiBan/index"
140
+export default {
141
+  name: "Details",
142
+  data() {
143
+    return {
144
+      //类型
145
+      workName: "",
146
+      //仓房编码
147
+      houseName: null,
148
+      //申请人
149
+      applyName: null,
150
+      //部门
151
+      departmentName: null,
152
+      //公司
153
+      companyName: null,
154
+      //库字典数据
155
+      deportDic: {},
156
+      //仓房字典数据
157
+      hourseDic: {},
158
+      //部门字典数据
159
+      departDic: {},
160
+      //每条数据
161
+      row: {},
162
+
163
+      //当前登录人信息
164
+      userInfo: {},
165
+
166
+      //审批状态
167
+      auditState: null,
168
+      //审批流程高亮显示
169
+      processActive: 0,
170
+      //审批流程
171
+      process: [],
172
+      //用户字典列表
173
+      perList: {},
174
+      //
175
+      tableData: [],
176
+      //头部数据
177
+      headData: [],
178
+      //方案状态
179
+      subData: null,
180
+      //审批数据
181
+      applyData: [],
182
+      type: null
183
+    }
184
+  },
185
+  methods: {
186
+    //流程查看
187
+    getCheckList() {
188
+      var processId = this.row.processId
189
+      checkList(processId)
190
+        .then((res) => {
191
+          console.log(res.data, "......")
192
+          if (res.code == 200) {
193
+            
194
+
195
+            let ongoingStep = this.ongoingStep
196
+            this.subData = res.data.process[ongoingStep].list[0].subData  //方案状态
197
+            this.tableData = res.data.process[ongoingStep]
198
+
199
+            for (let i = 0; i < res.data.process[ongoingStep].audit.length; i++) {
200
+              var ele = res.data.process[ongoingStep].audit[i]
201
+              if (ele.auditState != null) {
202
+                this.processActive = i
203
+              }
204
+              this.process.push(ele)
205
+              if (this.process[0].content == 0) {
206
+                this.process[0].content = this.userInfo.uid
207
+              } else {
208
+                this.process[0].content = res.data.process[ongoingStep].audit[0].content
209
+              }
210
+            }
211
+            this.getProcessed()
212
+          }
213
+        })
214
+        .catch((err) => {
215
+          console.log(err)
216
+        })
217
+    },
218
+
219
+    //机械通风审批通过接口
220
+    getApproval() {
221
+      var data = {
222
+        id: this.row.id,
223
+        auditState: this.auditState,
224
+        // 进行到哪一步的主流程id
225
+        ongoingStep: this.ongoingStep,
226
+        auditTime: getNowFormatDate(),
227
+      }
228
+      Approval(data)
229
+        .then((res) => {
230
+          sessionStorage.setItem("store", JSON.stringify(this.$store.state))
231
+          // location.reload();
232
+
233
+          this.$store.commit({
234
+            type: "changependingCount",
235
+            pendingCount: this.$store.state.pendingCount,
236
+          })
237
+
238
+          this.getCheckList()
239
+          this.getPending()
240
+          this.$router.push({
241
+            path: "/dashboard/daiban/pending/xunzengDetails",
242
+            item: this.$route.query,
243
+          })
244
+        })
245
+        .catch((err) => {
246
+          console.log(err)
247
+        })
248
+    },
249
+
250
+    //药剂采购审批通过接口
251
+    getyjcgApproval() {
252
+      var data = {
253
+        id: this.row.id,
254
+        auditState: this.auditState,
255
+        ongoingStep: this.ongoingStep,
256
+        auditTime: getNowFormatDate(),
257
+      }
258
+      yjcgApproval(data)
259
+        .then((res) => {
260
+          sessionStorage.setItem("store", JSON.stringify(this.$store.state))
261
+          // location.reload();
262
+
263
+          this.$store.commit({
264
+            type: "changependingCount",
265
+            pendingCount: this.$store.state.pendingCount,
266
+          })
267
+
268
+          this.getCheckList()
269
+          this.getPending()
270
+          this.$router.push({
271
+            path: "/dashboard/daiban/pending/xunzengDetails",
272
+            item: this.$route.query,
273
+          })
274
+        }) 
275
+        .catch((err) => {
276
+          console.log(err)
277
+        })
278
+    },
279
+    //审批不通过
280
+
281
+    noAgree(item, index) {
282
+      this.$confirm("确定审批不通过?", "提示", {
283
+        confirmButtonText: "确定",
284
+        cancelButtonText: "返回",
285
+        type: "warning",
286
+      })
287
+        .then(() => {
288
+          this.auditState = 2
289
+
290
+          // this.ongoingStep = 0
291
+           this.ongoingStep=this.ongoingStep
292
+          this.process = []
293
+          //this.getApproval()
294
+          if (item.type == "yjcg" || item.type == "xzjh") {
295
+            this.getyjcgApproval()
296
+          } else {
297
+            this.getApproval()
298
+          }
299
+          item.auditState = 2
300
+        })
301
+        .catch(() => {})
302
+    },
303
+
304
+    //审批通过
305
+    agree(item, index) {
306
+      console.log(item, "??????????")
307
+      console.log(index, "index......")
308
+      //最后一个人通过
309
+      if (index == this.process.length - 1) {
310
+        if(item.type == "yjcg"){
311
+          this.auditState = 4
312
+        }else{
313
+           this.auditState = 3
314
+        }
315
+       
316
+      
317
+        // this.ongoingStep = 1
318
+        this.ongoingStep=this.ongoingStep+1
319
+        console.log('审批后的ongoingStep'+this.ongoingStep)
320
+      } else {
321
+        this.auditState = 1
322
+        // this.ongoingStep = 0
323
+         this.ongoingStep=this.ongoingStep
324
+         console.log('审批前的ongoingStep'+this.ongoingStep)
325
+      }
326
+
327
+      this.process = []
328
+      this.$message(
329
+        {
330
+          message:"审批通过",
331
+          type: 'success'
332
+        })
333
+      if (item.type == "yjcg" || item.type == "xzjh") {
334
+        this.getyjcgApproval()
335
+      } else {
336
+        this.getApproval()
337
+      }
338
+    },
339
+    //点击返回按钮
340
+    goBack() {
341
+      this.$router.push({ path: "/home/daiban/pending" })
342
+    },
343
+
344
+    //已处理列表数据
345
+    getProcessed() {
346
+      var condition = {
347
+        userId: this.userInfo.uid,
348
+      }
349
+      // console.log(condition, "condition.....")
350
+      condition = JSON.stringify(condition)
351
+      var data = {
352
+        pageIndex: 1,
353
+        pageSize: 10,
354
+        condition: condition,
355
+      }
356
+      processed(data).then((res) => {
357
+        if (res.code == 200) {
358
+          console.log(res)
359
+          this.processedList = res.data.records
360
+
361
+          this.$store.commit({
362
+            type: "changeproCount",
363
+            proCount: res.data.total,
364
+          })
365
+          console.log(this.$store.state.proCount, "aaaaaa.")
366
+          console.log(res.data.total, "res.data.total....")
367
+          // sessionStorage.setItem("store", JSON.stringify(this.$store.state))
368
+          // this.pagination.total = res.data.total
369
+        }
370
+      })
371
+    },
372
+
373
+    //待处理列表数据
374
+    getPending() {
375
+      var condition = {
376
+        userId: JSON.parse(getUser()).uid,
377
+      }
378
+      condition = JSON.stringify(condition)
379
+      var data = {
380
+        pageIndex: 1,
381
+        pageSize: 10,
382
+        condition: condition,
383
+      }
384
+
385
+      pending(data).then((res) => {
386
+        if (res.code == 200) {
387
+          this.$store.commit({
388
+            type: "changependingCount",
389
+            pendingCount: res.data.total,
390
+          })
391
+        }
392
+      })
393
+    },
394
+  },
395
+  mounted() {
396
+    //库字典数据
397
+    this.deportDic = JSON.parse(localStorage.getItem("deportDic"))
398
+    console.log(this.deportDic, " this.deportDic...")
399
+
400
+    //部门字典数据
401
+    this.departDic = JSON.parse(localStorage.getItem("departDic"))
402
+    console.log(this.departDic, " this.departDic...")
403
+
404
+    //仓房字典数据
405
+    this.hourseDic = JSON.parse(localStorage.getItem("hourseDic"))
406
+    console.log(this.hourseDic, " this.hourseDic...")
407
+    //获取当前缓存的用户信息
408
+    // this.userInfo = JSON.parse(localStorage.getItem("userInfo"))
409
+    // console.log(this.userInfo, "this.userInfo.....")
410
+    this.userInfo = JSON.parse(getUser())
411
+    console.log(this.userInfo, "this.userInfo.....?????")
412
+    //用户字典
413
+    this.perList = JSON.parse(localStorage.getItem("perList"))
414
+    console.log(this.perList, "this.perList...")
415
+    //流程id
416
+    this.row = this.$route.query
417
+    console.log(this.row, "??????")
418
+
419
+    this.getCheckList()
420
+
421
+    this.houseName = this.$route.query.houseName
422
+    this.applyName = this.$route.query.applyName
423
+    this.departmentName = this.$route.query.departmentName
424
+    this.companyName = this.$route.query.companyName
425
+    this.workName = this.$route.query.workName
426
+    this.ongoingStep=parseInt(this.$route.query.ongoingStep)
427
+    this.type = this.$route.query.type
428
+  },
429
+}
430
+</script>
431
+
432
+<style lang="scss" scoped>
433
+.global {
434
+  padding-top: 0;
435
+}
436
+#penmainDetail {
437
+  height: 100%;
438
+  .pencontainDetail {
439
+    .lc_top {
440
+      height: 100px;
441
+      background: #fff;
442
+      border-radius: 6px;
443
+      padding: 10px;
444
+      .header {
445
+        font-size: 18px;
446
+        font-weight: 500;
447
+        height: 20%;
448
+        margin-bottom: 20px;
449
+        color: #037d41;
450
+      }
451
+      .middle {
452
+        margin-bottom: 20px;
453
+        width: 80%;
454
+        display: flex;
455
+        justify-content: space-between;
456
+        margin-left: 20px;
457
+        .middle_flex {
458
+          display: flex;
459
+          margin-bottom: 10px;
460
+        }
461
+      }
462
+    }
463
+
464
+    #process {
465
+      background: #fff;
466
+      border-radius: 6px;
467
+      margin-top: 10px;
468
+      padding: 10px;
469
+
470
+      border-radius: 4px;
471
+      .process_title {
472
+        color: #037d41;
473
+        font-size: 18px;
474
+        margin-bottom: 10px;
475
+      }
476
+      .process_step {
477
+        height: 400px;
478
+      }
479
+      .stepTitle {
480
+        display: flex;
481
+        justify-content: space-between;
482
+      }
483
+    }
484
+    .table_middle {
485
+      height: 70px;
486
+      line-height: 70px;
487
+      padding-left: 10px;
488
+      background: #fff;
489
+      border-radius: 6px;
490
+      margin-top: 10px;
491
+    }
492
+
493
+    .active {
494
+      color: #037d41;
495
+      // width: 500px;
496
+      // height: 40px;
497
+      // margin-top: 10px;
498
+    }
499
+    .noActive {
500
+      color: red;
501
+      // width: 500px;
502
+      // height: 40px;
503
+      // margin-top: 10px;
504
+    }
505
+  }
506
+
507
+  .stepTitle {
508
+    .stepTitleFont {
509
+      color: black;
510
+    }
511
+  }
512
+  .btns {
513
+    text-align: right;
514
+    margin-top: 20px;
515
+  }
516
+}
517
+</style>

+ 517 - 0
shanXiPlatform/src/views/home/daiBan/processed/xunzengDetails.vue

@@ -0,0 +1,517 @@
1
+<template>
2
+  <div id="penmainDetail">
3
+    <div class="pencontainDetail">
4
+      <div class="lc_top">
5
+        <div class="header" style="font-weight: 500">
6
+          <i class="iconfont iconshu"></i>
7
+          {{workName }}
8
+        </div>
9
+        <div class="middle">
10
+          <div class="middle_flex"  v-if="workName.indexOf('药剂') == -1">
11
+            <div>仓号:</div>
12
+            <div>{{houseName }}</div>
13
+          </div>
14
+          <div class="middle_flex">
15
+            <div>申请人:</div>
16
+            <div>{{applyName }}</div>
17
+          </div>
18
+          <div class="middle_flex">
19
+            <div>申请部门:</div>
20
+            <div>{{departmentName }}</div>
21
+          </div>
22
+          <div class="middle_flex">
23
+            <div>公司:</div>
24
+            <div>{{companyName }}</div>
25
+          </div>
26
+        </div>
27
+      </div>
28
+      <div class="table_middle">
29
+        <div style="margin-left: 20px">
30
+          <span v-if="type == 'tf'">1.制定通风方案:</span>
31
+          <span v-if="type == 'xzjh'">1.制定熏蒸计划:</span>
32
+          <span v-if="this.subData == 1">否</span>
33
+          <span v-if="this.subData == 0">是</span>
34
+        </div>
35
+      </div>
36
+      <div id="process">
37
+        <div class="process_title" style="font-weight: 500">
38
+          <i class="iconfont iconshu"></i>
39
+          流程({{workName}}审批)
40
+        </div>
41
+        <div class="process_step" style="margin-left: 20px">
42
+          <el-steps direction="vertical" :active="processActive">
43
+            <el-step
44
+              v-for="(item, index) in process"
45
+              :key="index"
46
+              icon="el-icon-edit"
47
+            >
48
+              <template>
49
+                <div slot="title" class="stepTitle">
50
+                  <div class="stepTitleFont">
51
+                    {{ item.title }}
52
+                  </div>
53
+
54
+                  <div style="width: 200px">
55
+                    <div
56
+                      style="font-weight: 500"
57
+                      :class="{
58
+                        active:
59
+                          index == 0 ||
60
+                          (item.auditState != null && item.auditState == 1),
61
+                        noActive: item.auditState == 2,
62
+                      }"
63
+                    >
64
+                      {{ perList[item.content] }}
65
+                    </div>
66
+                    <div v-if="item.auditState == 0">待审批</div>
67
+                    <div v-if="item.auditState == 1" class="stepTitleFont">
68
+                      审批通过
69
+                    </div>
70
+                    <div v-if="item.auditState == 2">审批不通过</div>
71
+                    <div class="stepTitleFont">{{ item.auditTime }}</div>
72
+
73
+                    <div style="width: 200px; display: flex">
74
+                      <!-- 状态为0且为当前登录人时按钮显示 -->
75
+                      <el-button
76
+                        type="danger"
77
+                        size="mini"
78
+                        v-if="
79
+                          item.content == userInfo.uid && item.auditState == 0
80
+                        "
81
+                        @click="noAgree(item, index)"
82
+                        >审批不通过</el-button
83
+                      >
84
+                      <el-button
85
+                        type="success"
86
+                        size="mini"
87
+                        v-if="
88
+                          item.content == userInfo.uid && item.auditState == 0
89
+                        "
90
+                        @click="agree(item, index)"
91
+                        >审批通过</el-button
92
+                      >
93
+                    </div>
94
+                  </div>
95
+                </div>
96
+              </template>
97
+            
98
+              <template>
99
+                <i
100
+                  slot="icon"
101
+                  class="iconfont iconstep_current"
102
+                  v-if="
103
+                    index != 0 &&
104
+                    (item.auditState == null || item.auditState == 0)
105
+                  "
106
+                >
107
+                </i>
108
+                <i
109
+                  slot="icon"
110
+                  style="color: red"
111
+                  class="iconfont iconstep_err"
112
+                  v-if="item.auditState == 2"
113
+                ></i>
114
+                <i
115
+                  slot="icon"
116
+                  style="color: green"
117
+                  class="iconfont iconstep_complete"
118
+                  v-if="item.auditState == 1 || index == 0"
119
+                ></i>
120
+              </template>
121
+            </el-step>
122
+          </el-steps>
123
+        </div>
124
+      </div>
125
+      <div class="btns">
126
+        <el-button class="backBtn" type="success" plain @click="goBack()"
127
+          >返回</el-button
128
+        >
129
+      </div>
130
+    </div>
131
+  </div>
132
+</template>
133
+<script>
134
+import { checkList } from "@/api/reservesManagement/mechanicalVentilation"
135
+import { Approval, yjcgApproval } from "@/api/daiBan/index"
136
+import { getNowFormatDate } from "@/utils"
137
+import { getUser } from "@/utils/auth"
138
+import { pending } from "@/api/daiBan/index"
139
+import { processed } from "@/api/daiBan/index"
140
+export default {
141
+  name: "Details",
142
+  data() {
143
+    return {
144
+      //类型
145
+      workName: "",
146
+      //仓房编码
147
+      houseName: null,
148
+      //申请人
149
+      applyName: null,
150
+      //部门
151
+      departmentName: null,
152
+      //公司
153
+      companyName: null,
154
+      //库字典数据
155
+      deportDic: {},
156
+      //仓房字典数据
157
+      hourseDic: {},
158
+      //部门字典数据
159
+      departDic: {},
160
+      //每条数据
161
+      row: {},
162
+
163
+      //当前登录人信息
164
+      userInfo: {},
165
+
166
+      //审批状态
167
+      auditState: null,
168
+      //审批流程高亮显示
169
+      processActive: 0,
170
+      //审批流程
171
+      process: [],
172
+      //用户字典列表
173
+      perList: {},
174
+      //
175
+      tableData: [],
176
+      //头部数据
177
+      headData: [],
178
+      //方案状态
179
+      subData: null,
180
+      //审批数据
181
+      applyData: [],
182
+      type: null
183
+    }
184
+  },
185
+  methods: {
186
+    //流程查看
187
+    getCheckList() {
188
+      var processId = this.row.processId
189
+      checkList(processId)
190
+        .then((res) => {
191
+          console.log(res.data, "......")
192
+          if (res.code == 200) {
193
+            let ongoingStep = this.ongoingStep
194
+            this.subData = res.data.process[ongoingStep].list[0].subData  //方案状态
195
+            this.tableData = res.data.process[ongoingStep]
196
+
197
+            for (let i = 0; i < res.data.process[ongoingStep].audit.length; i++) {
198
+              var ele = res.data.process[ongoingStep].audit[i]
199
+              if (ele.auditState != null) {
200
+                this.processActive = i
201
+              }
202
+              this.process.push(ele)
203
+              if (this.process[0].content == 0) {
204
+                this.process[0].content = this.userInfo.uid
205
+              } else {
206
+                this.process[0].content = res.data.process[ongoingStep].audit[0].content
207
+              }
208
+            }
209
+            this.getProcessed()
210
+          }
211
+        })
212
+        .catch((err) => {
213
+          console.log(err)
214
+        })
215
+    },
216
+
217
+    //机械通风审批通过接口
218
+    getApproval() {
219
+      var data = {
220
+        id: this.row.id,
221
+        auditState: this.auditState,
222
+        // 进行到哪一步的主流程id
223
+        ongoingStep: this.ongoingStep,
224
+        auditTime: getNowFormatDate(),
225
+      }
226
+      Approval(data)
227
+        .then((res) => {
228
+          sessionStorage.setItem("store", JSON.stringify(this.$store.state))
229
+          // location.reload();
230
+
231
+          this.$store.commit({
232
+            type: "changependingCount",
233
+            pendingCount: this.$store.state.pendingCount,
234
+          })
235
+
236
+          this.getCheckList()
237
+          this.getPending()
238
+          this.$router.push({
239
+            path: "/dashboard/daiban/processed/xunzengDetails",
240
+            item: this.$route.query,
241
+          })
242
+        })
243
+        .catch((err) => {
244
+          console.log(err)
245
+        })
246
+    },
247
+
248
+    //药剂采购审批通过接口
249
+    getyjcgApproval() {
250
+      var data = {
251
+        id: this.row.id,
252
+        auditState: this.auditState,
253
+        ongoingStep: this.ongoingStep,
254
+        auditTime: getNowFormatDate(),
255
+      }
256
+      yjcgApproval(data)
257
+        .then((res) => {
258
+          sessionStorage.setItem("store", JSON.stringify(this.$store.state))
259
+          // location.reload();
260
+
261
+          this.$store.commit({
262
+            type: "changependingCount",
263
+            pendingCount: this.$store.state.pendingCount,
264
+          })
265
+
266
+          this.getCheckList()
267
+          this.getPending()
268
+          this.$router.push({
269
+            path: "/dashboard/daiban/processed/xunzengDetails",
270
+            item: this.$route.query,
271
+          })
272
+        }) 
273
+        .catch((err) => {
274
+          console.log(err)
275
+        })
276
+    },
277
+    //审批不通过
278
+
279
+    noAgree(item, index) {
280
+      this.$confirm("确定审批不通过?", "提示", {
281
+        confirmButtonText: "确定",
282
+        cancelButtonText: "返回",
283
+        type: "warning",
284
+      })
285
+        .then(() => {
286
+          this.auditState = 2
287
+
288
+          // this.ongoingStep = 0
289
+           this.ongoingStep=this.ongoingStep
290
+          this.process = []
291
+          //this.getApproval()
292
+          if (item.type == "yjcg" || item.type == "xzjh") {
293
+            this.getyjcgApproval()
294
+          } else {
295
+            this.getApproval()
296
+          }
297
+          item.auditState = 2
298
+        })
299
+        .catch(() => {})
300
+    },
301
+
302
+    //审批通过
303
+    agree(item, index) {
304
+      console.log(item, "??????????")
305
+      console.log(index, "index......")
306
+      //最后一个人通过
307
+      if (index == this.process.length - 1) {
308
+        if(item.type == "yjcg"){
309
+          this.auditState = 4
310
+        }else{
311
+           this.auditState = 3
312
+        }
313
+       
314
+      
315
+        // this.ongoingStep = 1
316
+        this.ongoingStep=this.ongoingStep+1
317
+        console.log('审批后的ongoingStep'+this.ongoingStep)
318
+      } else {
319
+        this.auditState = 1
320
+     
321
+
322
+        // this.ongoingStep = 0
323
+         this.ongoingStep=this.ongoingStep
324
+         console.log('审批前的ongoingStep'+this.ongoingStep)
325
+      }
326
+
327
+      this.process = []
328
+      this.$message(
329
+        {
330
+          message:"审批通过",
331
+          type: 'success'
332
+        })
333
+      if (item.type == "yjcg" || item.type == "xzjh") {
334
+        this.getyjcgApproval()
335
+      } else {
336
+        this.getApproval()
337
+      }
338
+    },
339
+    //点击返回按钮
340
+    goBack() {
341
+      this.$router.push({ path: "/home/daiban/processed" })
342
+    },
343
+
344
+    //已处理列表数据
345
+    getProcessed() {
346
+      var condition = {
347
+        userId: this.userInfo.uid,
348
+      }
349
+      // console.log(condition, "condition.....")
350
+      condition = JSON.stringify(condition)
351
+      var data = {
352
+        pageIndex: 1,
353
+        pageSize: 10,
354
+        condition: condition,
355
+      }
356
+      processed(data).then((res) => {
357
+        if (res.code == 200) {
358
+          console.log(res)
359
+          this.processedList = res.data.records
360
+
361
+          this.$store.commit({
362
+            type: "changeproCount",
363
+            proCount: res.data.total,
364
+          })
365
+          console.log(this.$store.state.proCount, "aaaaaa.")
366
+          console.log(res.data.total, "res.data.total....")
367
+          // sessionStorage.setItem("store", JSON.stringify(this.$store.state))
368
+          // this.pagination.total = res.data.total
369
+        }
370
+      })
371
+    },
372
+
373
+    //待处理列表数据
374
+    getPending() {
375
+      var condition = {
376
+        userId: JSON.parse(getUser()).uid,
377
+      }
378
+      condition = JSON.stringify(condition)
379
+      var data = {
380
+        pageIndex: 1,
381
+        pageSize: 10,
382
+        condition: condition,
383
+      }
384
+
385
+      pending(data).then((res) => {
386
+        if (res.code == 200) {
387
+          this.$store.commit({
388
+            type: "changependingCount",
389
+            pendingCount: res.data.total,
390
+          })
391
+        }
392
+      })
393
+    },
394
+  },
395
+  mounted() {
396
+    //库字典数据
397
+    this.deportDic = JSON.parse(localStorage.getItem("deportDic"))
398
+    console.log(this.deportDic, " this.deportDic...")
399
+
400
+    //部门字典数据
401
+    this.departDic = JSON.parse(localStorage.getItem("departDic"))
402
+    console.log(this.departDic, " this.departDic...")
403
+
404
+    //仓房字典数据
405
+    this.hourseDic = JSON.parse(localStorage.getItem("hourseDic"))
406
+    console.log(this.hourseDic, " this.hourseDic...")
407
+    //获取当前缓存的用户信息
408
+    // this.userInfo = JSON.parse(localStorage.getItem("userInfo"))
409
+    // console.log(this.userInfo, "this.userInfo.....")
410
+    this.userInfo = JSON.parse(getUser())
411
+    console.log(this.userInfo, "this.userInfo.....?????")
412
+    //用户字典
413
+    this.perList = JSON.parse(localStorage.getItem("perList"))
414
+    console.log(this.perList, "this.perList...")
415
+    //流程id
416
+    this.row = this.$route.query
417
+    console.log(this.row, "??????")
418
+
419
+    this.getCheckList()
420
+
421
+    this.houseName = this.$route.query.houseName
422
+    this.applyName = this.$route.query.applyName
423
+    this.departmentName = this.$route.query.departmentName
424
+    this.companyName = this.$route.query.companyName
425
+    this.workName = this.$route.query.workName
426
+    this.ongoingStep = parseInt(this.$route.query.ongoingStep)
427
+    this.type = this.$route.query.type
428
+  },
429
+}
430
+</script>
431
+
432
+<style lang="scss" scoped>
433
+.global {
434
+  padding-top: 0;
435
+}
436
+#penmainDetail {
437
+  height: 100%;
438
+  .pencontainDetail {
439
+    .lc_top {
440
+      height: 100px;
441
+      background: #fff;
442
+      border-radius: 6px;
443
+      padding: 10px;
444
+      .header {
445
+        font-size: 18px;
446
+        font-weight: 500;
447
+        height: 20%;
448
+        margin-bottom: 20px;
449
+        color: #037d41;
450
+      }
451
+      .middle {
452
+        margin-bottom: 20px;
453
+        width: 80%;
454
+        display: flex;
455
+        justify-content: space-between;
456
+        margin-left: 20px;
457
+        .middle_flex {
458
+          display: flex;
459
+          margin-bottom: 10px;
460
+        }
461
+      }
462
+    }
463
+
464
+    #process {
465
+      background: #fff;
466
+      border-radius: 6px;
467
+      margin-top: 10px;
468
+      padding: 10px;
469
+
470
+      border-radius: 4px;
471
+      .process_title {
472
+        color: #037d41;
473
+        font-size: 18px;
474
+        margin-bottom: 10px;
475
+      }
476
+      .process_step {
477
+        height: 400px;
478
+      }
479
+      .stepTitle {
480
+        display: flex;
481
+        justify-content: space-between;
482
+      }
483
+    }
484
+    .table_middle {
485
+      height: 70px;
486
+      line-height: 70px;
487
+      padding-left: 10px;
488
+      background: #fff;
489
+      border-radius: 6px;
490
+      margin-top: 10px;
491
+    }
492
+
493
+    .active {
494
+      color: #037d41;
495
+      // width: 500px;
496
+      // height: 40px;
497
+      // margin-top: 10px;
498
+    }
499
+    .noActive {
500
+      color: red;
501
+      // width: 500px;
502
+      // height: 40px;
503
+      // margin-top: 10px;
504
+    }
505
+  }
506
+
507
+  .stepTitle {
508
+    .stepTitleFont {
509
+      color: black;
510
+    }
511
+  }
512
+  .btns {
513
+    text-align: right;
514
+    margin-top: 20px;
515
+  }
516
+}
517
+</style>

+ 2 - 1
shanXiPlatform/src/views/home/gzjftable.vue

@@ -76,7 +76,8 @@ export default {
76 76
             var condition = {
77 77
                 // depotId: this.$store.state.depotId,
78 78
                 depotId: this.$route.query.depotId,
79
-                sTime: this.checkYear
79
+                sTime: this.checkYear,
80
+                type:''
80 81
             }
81 82
             condition = JSON.stringify(condition)
82 83
             let data = {

+ 122 - 0
shanXiPlatform/src/views/home/hydmoretable.vue

@@ -0,0 +1,122 @@
1
+<template>
2
+    <div class="global">
3
+        <div class="contentContainerGg">
4
+            <div class="container">
5
+                <el-form :inline="true">
6
+                    <el-form-item label="时间:">
7
+                        <el-date-picker @change="timechange" id="getWeek" v-model="datetime" type="month" format="yyyy-MM" placeholder="选择月">
8
+                        </el-date-picker>
9
+                    </el-form-item>
10
+                    <el-form-item>
11
+                        <el-button icon="el-icon-search" type="success" plain @click="getList()">
12
+                            查询</el-button>
13
+                    </el-form-item>
14
+                </el-form>
15
+                <el-table border :data="tableList" highlight-current-row style="width:100%" :header-cell-style="{background:'#f8f8f8'}">
16
+                    <el-table-column property="sTime" label="时间" align="center" >
17
+                        <template slot-scope="scope">
18
+                            {{ scope.row.actTime.slice(0,7) }}
19
+                        </template>
20
+                    </el-table-column>
21
+                    <el-table-column prop="personnelName" label="人员" align="center" />
22
+                    <el-table-column prop="sposition" label="职位" align="center" />
23
+                    <el-table-column prop="depotName" label="所属粮库" align="center" />
24
+                    <el-table-column prop="depotRanking" label="活跃度所在粮库排名" align="center" />
25
+                    <el-table-column prop="provinceRanking" label="活跃度全省排名" align="center" />
26
+                    <el-table-column prop="usActivity" label="得分" align="center" />
27
+                </el-table>
28
+                <div class="pagination-container">
29
+                    <el-pagination class="right" background :current-page.sync="listQuery.page" :page-size="listQuery.limit" :page-sizes="[10,20,30,40]" :total="total" @size-change="sizeChange" @current-change="pageChange" layout="total, sizes, prev, pager, next, jumper"></el-pagination>
30
+                </div>
31
+            </div>
32
+        </div>
33
+    </div>
34
+</template>
35
+<script>
36
+import { getcf } from "@/api/organizationalStructureManagement/index.js"
37
+import { getmorehyd } from "@/api/branchoff/index.js"
38
+export default {
39
+    data() {
40
+        return {
41
+            datetime: "",
42
+            // 列表数据
43
+            tableList: [],
44
+            // 分页
45
+            total: 0,
46
+            listLoading: true,
47
+            listQuery: {
48
+                page: 1,
49
+                limit: 10
50
+            },
51
+            roleList: [],
52
+            depotDic: []
53
+        }
54
+    },
55
+    created() {
56
+        this.getList()
57
+        this.depotDic = JSON.parse(localStorage.getItem("deportDic"))
58
+    },
59
+    methods: {
60
+        timechange() {
61
+            this.$nextTick(() => {
62
+                let week = document.querySelector("#getWeek").value
63
+                this.checkYear = week
64
+            })
65
+        },
66
+        getList() {
67
+            var condition = {
68
+                // depotId: this.$store.state.depotId,
69
+                depotId: this.$route.query.depotId,
70
+                sTime: this.checkYear,
71
+                type:'1'
72
+            }
73
+            condition = JSON.stringify(condition)
74
+            let data = {
75
+                condition: condition,
76
+                pageIndex: this.listQuery.page,
77
+                pageSize: this.listQuery.limit
78
+            }
79
+            getmorehyd(data)
80
+                .then(res => {
81
+                    if (res.code == 200) {
82
+                        this.tableList = res.data.records
83
+                        this.listQuery.limit = res.data.size
84
+                        this.total = res.data.total
85
+                    } else {
86
+                        this.$message({
87
+                            type: "error",
88
+                            message: res.msg
89
+                        })
90
+                    }
91
+                })
92
+                .catch(err => {
93
+                    console.log(err)
94
+                })
95
+        },
96
+        sizeChange(v) {
97
+            this.listQuery.limit = v
98
+            this.getList()
99
+        },
100
+        pageChange(v) {
101
+            this.listQuery.page = v
102
+            this.getList()
103
+        },
104
+     
105
+    }
106
+}
107
+</script>
108
+<style lang="scss" scoped>
109
+.top {
110
+    height: 40px;
111
+    line-height: 40px;
112
+    border-bottom: 1px solid #ccc;
113
+}
114
+.container {
115
+    padding: 10px;
116
+}
117
+.pagination-container {
118
+    margin-top: 10px;
119
+    margin-right: 20px;
120
+    text-align: right;
121
+}
122
+</style>

+ 132 - 0
shanXiPlatform/src/views/home/hydtable.vue

@@ -0,0 +1,132 @@
1
+<template>
2
+    <div class="global">
3
+        <div class="contentContainerGg">
4
+            <div class="container">
5
+                <el-form :inline="true">
6
+                    <el-form-item label="时间:">
7
+                        <el-date-picker @change="timechange" id="getWeek" v-model="datetime" type="month" format="yyyy-MM" placeholder="选择月">
8
+                        </el-date-picker>
9
+                    </el-form-item>
10
+                    <el-form-item>
11
+                        <el-button icon="el-icon-search" type="success" plain @click="getList()">
12
+                            查询</el-button>
13
+                    </el-form-item>
14
+                </el-form>
15
+                <el-table border :data="tableList" highlight-current-row style="width:100%" :header-cell-style="{background:'#f8f8f8'}">
16
+                    <el-table-column property="sTime" label="时间" align="center">
17
+                        <template slot-scope="scope">
18
+                            {{ scope.row.actTime.slice(0,7) }}
19
+                        </template>
20
+                    </el-table-column>
21
+                    <el-table-column prop="depotName" label="公司" align="center" />
22
+                    <el-table-column prop="provinceRanking" label="活跃度全省排名" align="center" />
23
+                    <el-table-column prop="usActivity" label="得分" align="center" />
24
+                     <el-table-column property="operation" label="操作" align="center">
25
+                        <template slot-scope="scope">
26
+                            <el-button size="mini" type="detailbtn" @click="detailbtn(scope.$index, scope.row)">查看库内活跃排名</el-button>
27
+                        </template>
28
+                    </el-table-column>
29
+                </el-table>
30
+                <div class="pagination-container">
31
+                    <el-pagination class="right" background :current-page.sync="listQuery.page" :page-size="listQuery.limit" :page-sizes="[10,20,30,40]" :total="total" @size-change="sizeChange" @current-change="pageChange" layout="total, sizes, prev, pager, next, jumper"></el-pagination>
32
+                </div>
33
+            </div>
34
+        </div>
35
+    </div>
36
+</template>
37
+<script>
38
+import { getcf } from "@/api/organizationalStructureManagement/index.js"
39
+import { getmorehyd } from "@/api/branchoff/index.js"
40
+export default {
41
+    data() {
42
+        return {
43
+            datetime: "",
44
+            // 列表数据
45
+            tableList: [],
46
+            // 分页
47
+            total: 0,
48
+            listLoading: true,
49
+            listQuery: {
50
+                page: 1,
51
+                limit: 10
52
+            },
53
+            roleList: [],
54
+            depotDic: []
55
+        }
56
+    },
57
+    created() {
58
+        this.getList()
59
+        this.depotDic = JSON.parse(localStorage.getItem("deportDic"))
60
+    },
61
+    methods: {
62
+        timechange() {
63
+            this.$nextTick(() => {
64
+                let week = document.querySelector("#getWeek").value
65
+                this.checkYear = week
66
+            })
67
+        },
68
+        getList() {
69
+            var condition = {
70
+                // depotId: this.$store.state.depotId,
71
+                depotId: this.$route.query.depotId,
72
+                sTime: this.checkYear,
73
+                type: ""
74
+            }
75
+            condition = JSON.stringify(condition)
76
+            let data = {
77
+                condition: condition,
78
+                pageIndex: this.listQuery.page,
79
+                pageSize: this.listQuery.limit
80
+            }
81
+            getmorehyd(data)
82
+                .then(res => {
83
+                    if (res.code == 200) {
84
+                        this.tableList = res.data.records
85
+                        this.listQuery.limit = res.data.size
86
+                        this.total = res.data.total
87
+                    } else {
88
+                        this.$message({
89
+                            type: "error",
90
+                            message: res.msg
91
+                        })
92
+                    }
93
+                })
94
+                .catch(err => {
95
+                    console.log(err)
96
+                })
97
+        },
98
+        sizeChange(v) {
99
+            this.listQuery.limit = v
100
+            this.getList()
101
+        },
102
+        pageChange(v) {
103
+            this.listQuery.page = v
104
+            this.getList()
105
+        },
106
+         detailbtn( index, row  ) {
107
+              this.$router.push({
108
+                name: "hydmoretable",
109
+                query: {
110
+                    depotId: row.depotId,
111
+                    midprovinceName: this.$route.query.midprovinceName
112
+                }
113
+            })
114
+        }
115
+    }
116
+}
117
+</script>
118
+<style lang="scss" scoped>
119
+.top {
120
+    height: 40px;
121
+    line-height: 40px;
122
+    border-bottom: 1px solid #ccc;
123
+}
124
+.container {
125
+    padding: 10px;
126
+}
127
+.pagination-container {
128
+    margin-top: 10px;
129
+    margin-right: 20px;
130
+    text-align: right;
131
+}
132
+</style>

+ 2 - 1
shanXiPlatform/src/views/home/kngzjftable.vue

@@ -70,7 +70,8 @@ export default {
70 70
             var condition = {
71 71
                 // depotId: this.$store.state.depotId,
72 72
                 depotId: this.$route.query.depotId,
73
-                sTime: this.checkYear
73
+                sTime: this.checkYear,
74
+                type:'1'
74 75
             }
75 76
             condition = JSON.stringify(condition)
76 77
             let data = {

+ 49 - 10
shanXiPlatform/src/views/home/yclqtable.vue

@@ -2,7 +2,7 @@
2 2
     <div class="global">
3 3
         <div class="contentContainerGg">
4 4
             <div class="container">
5
-                <el-form  :inline="true">
5
+                <el-form :inline="true">
6 6
                     <el-form-item label="时间:">
7 7
                         <el-date-picker @change="timechange" id="getWeek" v-model="datetime" type="week" format="yyyy年WW周" placeholder="选择周">
8 8
                         </el-date-picker>
@@ -13,15 +13,32 @@
13 13
                     </el-form-item>
14 14
                 </el-form>
15 15
                 <el-table border :data="tableList" highlight-current-row style="width:100%" :header-cell-style="{background:'#f8f8f8'}">
16
-                    <el-table-column prop="operationTime" label="时间" align="center" />
17
-                      <el-table-column property="depotName" label="公司" align="center">
16
+                    <!-- <el-table-column prop="operationTime" label="时间" align="center" /> -->
17
+                    <el-table-column property="depotName" label="时间" align="center">
18 18
                         <template slot-scope="scope">
19
-                             {{ depotDic[scope.row.depotId] }}
19
+                            {{ scope.row.checkYear }}年 {{ scope.row.checkYearWeek}}周
20 20
                         </template>
21 21
                     </el-table-column>
22
-                    <!-- <el-table-column prop="storageStatus" label="所属市" align="center" /> -->
23
-                    <el-table-column prop="grainVarieties" label="仓房数量(个)" align="center" />
24
-                    <el-table-column prop="warehouseStatus" label="粮情异常仓房数量(个)" align="center" />
22
+                    <el-table-column v-if="this.$route.query.isshow" property="depotName" label="仓房" align="center">
23
+                        <template slot-scope="scope">
24
+                            <span style="color:green;" > {{ scope.row.depotId }}</span>
25
+                        </template>
26
+                    </el-table-column>
27
+                    <el-table-column  property="depotName" label="公司" align="center">
28
+                        <template slot-scope="scope" >
29
+                             {{ depotDic[scope.row.depotId] }} 
30
+                        </template>
31
+                    </el-table-column>
32
+                    <el-table-column v-if="this.$route.query.isshow" label="粮情异常情况" align="center">
33
+                        <template slot-scope="scope">
34
+                            <p style="height:45px;line-height:45px;margin:0;padding-top:7px;">
35
+                                <span class='colorspano' v-if="scope.row.grainError == '191'"></span>
36
+                                <span class='colorspant' v-if="scope.row.grainError != '191'"></span>
37
+                            </p>
38
+                        </template>
39
+                    </el-table-column>
40
+                    <el-table-column v-if="!this.$route.query.isshow" prop="grainVarieties" label="仓房数量(个)" align="center" />
41
+                    <el-table-column v-if="!this.$route.query.isshow" prop="warehouseStatus" label="粮情异常仓房数量(个)" align="center" />
25 42
                     <el-table-column property="operation" label="操作" align="center">
26 43
                         <template slot-scope="scope">
27 44
                             <el-button size="mini" type="detailbtn" @click="detailbtn(scope.$index, scope.row)">详情</el-button>
@@ -37,7 +54,7 @@
37 54
 </template>
38 55
 <script>
39 56
 import { getcf } from "@/api/organizationalStructureManagement/index.js"
40
-import {  getyclq } from "@/api/branchoff/index.js"
57
+import { getyclq } from "@/api/branchoff/index.js"
41 58
 export default {
42 59
     data() {
43 60
         return {
@@ -52,7 +69,7 @@ export default {
52 69
                 limit: 10
53 70
             },
54 71
             roleList: [],
55
-            depotDic: [],
72
+            depotDic: []
56 73
         }
57 74
     },
58 75
     created() {
@@ -105,7 +122,15 @@ export default {
105 122
             this.listQuery.page = v
106 123
             this.getList()
107 124
         },
108
-        detailbtn() {}
125
+        detailbtn(index, row) {
126
+            this.$router.push({
127
+                name: "AllGrain",
128
+                query: {
129
+                    // depotId: row.depotId,
130
+                    // midprovinceName: this.$route.query.midprovinceName
131
+                }
132
+            })
133
+        }
109 134
     }
110 135
 }
111 136
 </script>
@@ -123,4 +148,18 @@ export default {
123 148
     margin-right: 20px;
124 149
     text-align: right;
125 150
 }
151
+.colorspano {
152
+    width: 140px;
153
+    height: 30px;
154
+    background-color: #199856;
155
+    display: inline-block;
156
+    border-radius: 5px;
157
+}
158
+.colorspant {
159
+    width: 140px;
160
+    height: 30px;
161
+    background-color: #ffff00;
162
+    display: inline-block;
163
+    border-radius: 5px;
164
+}
126 165
 </style>

+ 5 - 5
shanXiPlatform/src/views/systemManagement/userManagement/approverManagement/index.vue

@@ -59,9 +59,9 @@ export default {
59 59
             //库id
60 60
             depotId: 1,
61 61
             roleArr: [],
62
-            //33--主管科长   35---分管副总经理   34---总经理  54--分公司主管
62
+            //33--主管科长   35---分管副总经理   34---总经理  37--分公司主管
63 63
             //角色id
64
-            rolesId: "33,34,35,54",
64
+            rolesId: "33,34,35,37",
65 65
             //初始化审批人下拉选
66 66
             approverSelect: [],
67 67
             // 表格数据初始化
@@ -539,7 +539,7 @@ export default {
539 539
                             } else if (
540 540
                                 item.title.indexOf("分公司主管处室") != -1
541 541
                             ) {
542
-                                this.$set(item, "approverSelect", res.data[54])
542
+                                this.$set(item, "approverSelect", res.data[37])
543 543
                             }
544 544
                         })
545 545
                     }
@@ -553,9 +553,9 @@ export default {
553 553
             if (this.type == "tf") {
554 554
                 this.tableData = this.meVentilation
555 555
             } else if (this.type == "xzjh") {
556
-                this.tableData = this.fumigation
556
+                // this.tableData = this.fumigation
557 557
             } else if (this.type == "xzsq") {
558
-                this.tableData = this.fumigation1
558
+                // this.tableData = this.fumigation1
559 559
             } else if (this.type == "yjcg") {
560 560
                 this.tableData = this.drugPurchase
561 561
             } else if (this.type == "yjly") {