浏览代码

报表代码提交

miaofuhao 2 年之前
父节点
当前提交
9cc22eeb4e

+ 94 - 73
CallCenterWeb.UI/RMYY/src/views/leadConcern/officeRepairReport/cpns/reportList.vue

26
       />
26
       />
27
 
27
 
28
       <el-table-column label="工单数量" align="center" min-width>
28
       <el-table-column label="工单数量" align="center" min-width>
29
-        <el-table-column
30
-          label="接单量"
31
-          prop="total"
32
-          align="center"
33
-          min-width
34
-        ></el-table-column>
29
+        <el-table-column label="接单量" align="center" min-width>
30
+          <template slot-scope="scope">
31
+            <el-button type="text" @click="btnClickEvents(2, '', scope.row)">
32
+              {{ scope.row.total }}
33
+            </el-button>
34
+          </template>
35
+        </el-table-column>
35
         <el-table-column label="完成情况" align="center" min-width>
36
         <el-table-column label="完成情况" align="center" min-width>
36
-          <el-table-column
37
-            prop="complete"
38
-            label="完成量"
39
-            align="center"
40
-            min-width
41
-          />
42
-          <el-table-column
43
-            prop="undone"
44
-            label="未完成量"
45
-            align="center"
46
-            min-width
47
-          />
37
+          <el-table-column label="完成量" align="center" min-width>
38
+            <template slot-scope="scope">
39
+              <el-button type="text" @click="btnClickEvents(1, '', scope.row)">
40
+                {{ scope.row.complete }}
41
+              </el-button>
42
+            </template>
43
+          </el-table-column>
44
+          <el-table-column label="未完成量" align="center" min-width>
45
+            <template slot-scope="scope">
46
+              <el-button type="text" @click="btnClickEvents(0, '', scope.row)">
47
+                {{ scope.row.undone }}
48
+              </el-button>
49
+            </template>
50
+          </el-table-column>
48
           <el-table-column
51
           <el-table-column
49
             prop="completerate"
52
             prop="completerate"
50
             label="完成率"
53
             label="完成率"
58
           min-width
61
           min-width
59
           v-if="listType === '1'"
62
           v-if="listType === '1'"
60
         >
63
         >
61
-          <el-table-column
62
-            prop="overtime"
63
-            label="数量"
64
-            align="center"
65
-            min-width
66
-          />
64
+          <el-table-column label="数量" align="center" min-width>
65
+            <template slot-scope="scope">
66
+              <el-button
67
+                type="text"
68
+                @click="btnClickEvents(2, 'overtime', scope.row)"
69
+              >
70
+                {{ scope.row.overtime }}
71
+              </el-button>
72
+            </template>
73
+          </el-table-column>
67
           <el-table-column
74
           <el-table-column
68
             prop="overtimerate"
75
             prop="overtimerate"
69
             label="超时率"
76
             label="超时率"
72
           />
79
           />
73
         </el-table-column>
80
         </el-table-column>
74
       </el-table-column>
81
       </el-table-column>
75
-      <el-table-column
76
-        label="不满意量"
77
-        align="center"
78
-        min-width
79
-        v-if="listType === '1'"
80
-      >
82
+      <el-table-column label="不满意量" align="center" min-width>
81
         <el-table-column label="质量" align="center" min-width>
83
         <el-table-column label="质量" align="center" min-width>
82
-          <el-table-column
83
-            prop="Quality"
84
-            label="数量"
85
-            align="center"
86
-            min-width
87
-          />
84
+          <el-table-column label="数量" align="center" min-width>
85
+            <template slot-scope="scope">
86
+              <el-button
87
+                type="text"
88
+                @click="btnClickEvents(2, 'Quality', scope.row)"
89
+              >
90
+                {{ scope.row.Quality }}
91
+              </el-button>
92
+            </template>
93
+          </el-table-column>
88
           <el-table-column
94
           <el-table-column
89
             prop="Qualityrate"
95
             prop="Qualityrate"
90
             label="不满意率"
96
             label="不满意率"
93
           />
99
           />
94
         </el-table-column>
100
         </el-table-column>
95
         <el-table-column label="态度" align="center" min-width>
101
         <el-table-column label="态度" align="center" min-width>
96
-          <el-table-column
97
-            prop="Attitude"
98
-            label="数量"
99
-            align="center"
100
-            min-width
101
-          />
102
+          <el-table-column label="数量" align="center" min-width>
103
+            <template slot-scope="scope">
104
+              <el-button
105
+                type="text"
106
+                @click="btnClickEvents(2, 'Attitude', scope.row)"
107
+              >
108
+                {{ scope.row.Attitude }}
109
+              </el-button>
110
+            </template>
111
+          </el-table-column>
102
           <el-table-column
112
           <el-table-column
103
             prop="Attituderate"
113
             prop="Attituderate"
104
             label="不满意率"
114
             label="不满意率"
107
           />
117
           />
108
         </el-table-column>
118
         </el-table-column>
109
         <el-table-column label="效率" align="center" min-width>
119
         <el-table-column label="效率" align="center" min-width>
110
-          <el-table-column
111
-            prop="Efficiency"
112
-            label="数量"
113
-            align="center"
114
-            min-width
115
-          />
120
+          <el-table-column label="数量" align="center" min-width>
121
+            <template slot-scope="scope">
122
+              <el-button
123
+                type="text"
124
+                @click="btnClickEvents(2, 'Efficiency', scope.row)"
125
+              >
126
+                {{ scope.row.Efficiency }}
127
+              </el-button>
128
+            </template>
129
+          </el-table-column>
116
           <el-table-column
130
           <el-table-column
117
             prop="Efficiencyrate"
131
             prop="Efficiencyrate"
118
             label="不满意率"
132
             label="不满意率"
121
           />
135
           />
122
         </el-table-column>
136
         </el-table-column>
123
       </el-table-column>
137
       </el-table-column>
124
-      <el-table-column
125
-        label="不满意量"
126
-        align="center"
127
-        min-width
128
-        v-if="listType === '2'"
129
-      >
130
-        <el-table-column label="总量" align="center" min-width>
131
-          <el-table-column prop="score" label="数量" align="center" min-width />
132
-          <el-table-column
133
-            prop="scorerate"
134
-            label="不满意率"
135
-            align="center"
136
-            min-width
137
-          />
138
-        </el-table-column>
139
-      </el-table-column>
140
     </el-table>
138
     </el-table>
141
     <!-- <pagination v-show="pageParams.total > 0" :total="pageParams.total" :pageindex.sync="pageParams.pageindex" :pagesize.sync="pageParams.pagesize" class="pagination" @pagination="getList" /> -->
139
     <!-- <pagination v-show="pageParams.total > 0" :total="pageParams.total" :pageindex.sync="pageParams.pageindex" :pagesize.sync="pageParams.pagesize" class="pagination" @pagination="getList" /> -->
142
   </div>
140
   </div>
144
 
142
 
145
 <script>
143
 <script>
146
 import Pagination from "@/components/context/Pagination"; // 对el-pagination 二次封装
144
 import Pagination from "@/components/context/Pagination"; // 对el-pagination 二次封装
145
+import reportComList from "../../cpns/reportComList";
147
 import {
146
 import {
148
   officeWorkReport,
147
   officeWorkReport,
149
   officeWorkCarReport,
148
   officeWorkCarReport,
150
 } from "@/api/leadConcern/leadConcern";
149
 } from "@/api/leadConcern/leadConcern";
151
 
150
 
152
-import { getNowDate, getPreDate, tableSpanArr } from "@/utils";
151
+import { tableSpanArr } from "@/utils";
153
 export default {
152
 export default {
154
   name: "TrafficWorkReport",
153
   name: "TrafficWorkReport",
155
   props: {
154
   props: {
167
       fieldListFlag: {},
166
       fieldListFlag: {},
168
       dataLists: [],
167
       dataLists: [],
169
       spanArr: [],
168
       spanArr: [],
170
-      ruleForm: {
171
-        startTime: [
172
-          getPreDate(3600 * 1000 * 24) + " 19:00:00",
173
-          getNowDate() + " 19:00:00",
174
-        ],
175
-        way: "",
176
-      },
169
+      timeObj: {},
170
+      ruleFormReport: {},
177
     };
171
     };
178
   },
172
   },
179
   computed: {},
173
   computed: {},
180
   mounted() {},
174
   mounted() {},
181
   methods: {
175
   methods: {
176
+    btnClickEvents(value, key, data) {
177
+      this.ruleFormReport = this.timeObj;
178
+      this.ruleFormReport.isdone = value;
179
+      if (value === 2) {
180
+        delete this.ruleFormReport.isdone;
181
+      }
182
+      if (this.listType === "2") {
183
+        this.ruleFormReport.loweltype = data.F_Type;
184
+        this.ruleFormReport.types = 1;
185
+        this.ruleFormReport.dealDept = Number(data.DeptId);
186
+      } else if (this.listType === "1") {
187
+        this.ruleFormReport.loweltype = data.F_SonType;
188
+        this.ruleFormReport.types = 0;
189
+        this.ruleFormReport.dealDept = Number(data.F_DealDept);
190
+      }
191
+      this.$layer.iframe({
192
+        content: {
193
+          content: reportComList, // 传递的组件对象
194
+          parent: this, // 当前的vue对象
195
+          data: { dataParams: this.ruleFormReport, keyValue: key },
196
+        },
197
+        area: ["80%", "90%"],
198
+        title: "工单列表",
199
+      });
200
+      this.ruleFormReport = {};
201
+    },
182
     getList(getParams) {
202
     getList(getParams) {
183
       this.LoadingFlag = true;
203
       this.LoadingFlag = true;
204
+      this.timeObj.starttime = getParams.starttime;
205
+      this.timeObj.endtime = getParams.endtime;
184
       return new Promise((resolve) => {
206
       return new Promise((resolve) => {
185
-        console.log(this.listType, this.listCar);
186
         if (this.listType === "1") {
207
         if (this.listType === "1") {
187
           officeWorkReport(getParams).then((response) => {
208
           officeWorkReport(getParams).then((response) => {
188
             if (response.state.toLowerCase() === "success") {
209
             if (response.state.toLowerCase() === "success") {

+ 105 - 50
CallCenterWeb.UI/RMYY/src/views/leadConcern/officeServiceReport/cpns/reportList.vue

26
       />
26
       />
27
 
27
 
28
       <el-table-column label="工单数量" align="center" min-width>
28
       <el-table-column label="工单数量" align="center" min-width>
29
-        <el-table-column
30
-          label="接单量"
31
-          prop="total"
32
-          align="center"
33
-          min-width
34
-        ></el-table-column>
29
+        <el-table-column label="接单量" prop="total" align="center" min-width>
30
+          <template slot-scope="scope">
31
+            <el-button type="text" @click="btnClickEvents(2, '', scope.row)">
32
+              {{ scope.row.total }}
33
+            </el-button>
34
+          </template>
35
+        </el-table-column>
35
         <el-table-column label="完成情况" align="center" min-width>
36
         <el-table-column label="完成情况" align="center" min-width>
36
-          <el-table-column
37
-            prop="complete"
38
-            label="完成量"
39
-            align="center"
40
-            min-width
41
-          />
42
-          <el-table-column
43
-            prop="undone"
44
-            label="未完成量"
45
-            align="center"
46
-            min-width
47
-          />
37
+          <el-table-column label="完成量" align="center" min-width>
38
+            <template slot-scope="scope">
39
+              <el-button type="text" @click="btnClickEvents(1, '', scope.row)">
40
+                {{ scope.row.complete }}
41
+              </el-button>
42
+            </template>
43
+          </el-table-column>
44
+          <el-table-column label="未完成量" align="center" min-width>
45
+            <template slot-scope="scope">
46
+              <el-button type="text" @click="btnClickEvents(1, '', scope.row)">
47
+                {{ scope.row.undone }}
48
+              </el-button>
49
+            </template>
50
+          </el-table-column>
48
           <el-table-column
51
           <el-table-column
49
             prop="completerate"
52
             prop="completerate"
50
             label="完成率"
53
             label="完成率"
58
           min-width
61
           min-width
59
           v-if="listType === '1'"
62
           v-if="listType === '1'"
60
         >
63
         >
61
-          <el-table-column
62
-            prop="overtime"
63
-            label="数量"
64
-            align="center"
65
-            min-width
66
-          />
64
+          <el-table-column label="数量" align="center" min-width>
65
+            <template slot-scope="scope">
66
+              <el-button
67
+                type="text"
68
+                @click="btnClickEvents(2, 'overtime', scope.row)"
69
+              >
70
+                {{ scope.row.overtime }}
71
+              </el-button>
72
+            </template>
73
+          </el-table-column>
67
           <el-table-column
74
           <el-table-column
68
             prop="overtimerate"
75
             prop="overtimerate"
69
             label="超时率"
76
             label="超时率"
79
         v-if="listType === '1'"
86
         v-if="listType === '1'"
80
       >
87
       >
81
         <el-table-column label="质量" align="center" min-width>
88
         <el-table-column label="质量" align="center" min-width>
82
-          <el-table-column
83
-            prop="Quality"
84
-            label="数量"
85
-            align="center"
86
-            min-width
87
-          />
89
+          <el-table-column label="数量" align="center" min-width>
90
+            <template slot-scope="scope">
91
+              <el-button
92
+                type="text"
93
+                @click="btnClickEvents(2, 'Quality', scope.row)"
94
+              >
95
+                {{ scope.row.Quality }}
96
+              </el-button>
97
+            </template>
98
+          </el-table-column>
88
           <el-table-column
99
           <el-table-column
89
             prop="Qualityrate"
100
             prop="Qualityrate"
90
             label="不满意率"
101
             label="不满意率"
93
           />
104
           />
94
         </el-table-column>
105
         </el-table-column>
95
         <el-table-column label="态度" align="center" min-width>
106
         <el-table-column label="态度" align="center" min-width>
96
-          <el-table-column
97
-            prop="Attitude"
98
-            label="数量"
99
-            align="center"
100
-            min-width
101
-          />
107
+          <el-table-column label="数量" align="center" min-width>
108
+            <template slot-scope="scope">
109
+              <el-button
110
+                type="text"
111
+                @click="btnClickEvents(2, 'Attitude', scope.row)"
112
+              >
113
+                {{ scope.row.Attitude }}
114
+              </el-button>
115
+            </template>
116
+          </el-table-column>
102
           <el-table-column
117
           <el-table-column
103
             prop="Attituderate"
118
             prop="Attituderate"
104
             label="不满意率"
119
             label="不满意率"
107
           />
122
           />
108
         </el-table-column>
123
         </el-table-column>
109
         <el-table-column label="效率" align="center" min-width>
124
         <el-table-column label="效率" align="center" min-width>
110
-          <el-table-column
111
-            prop="Efficiency"
112
-            label="数量"
113
-            align="center"
114
-            min-width
115
-          />
125
+          <el-table-column label="数量" align="center" min-width>
126
+            <template slot-scope="scope">
127
+              <el-button
128
+                type="text"
129
+                @click="btnClickEvents(2, 'Efficiency', scope.row)"
130
+              >
131
+                {{ scope.row.Efficiency }}
132
+              </el-button>
133
+            </template>
134
+          </el-table-column>
116
           <el-table-column
135
           <el-table-column
117
             prop="Efficiencyrate"
136
             prop="Efficiencyrate"
118
             label="不满意率"
137
             label="不满意率"
128
         v-if="listType === '2'"
147
         v-if="listType === '2'"
129
       >
148
       >
130
         <!-- <el-table-column label="总量" align="center" min-width> -->
149
         <!-- <el-table-column label="总量" align="center" min-width> -->
131
-        <el-table-column prop="score" label="数量" align="center" min-width />
150
+        <el-table-column label="数量" align="center" min-width>
151
+          <template slot-scope="scope">
152
+            <el-button
153
+              type="text"
154
+              @click="btnClickEvents(2, 'carscore', scope.row)"
155
+            >
156
+              {{ scope.row.score }}
157
+            </el-button>
158
+          </template>
159
+        </el-table-column>
132
         <el-table-column
160
         <el-table-column
133
           prop="scorerate"
161
           prop="scorerate"
134
           label="不满意率"
162
           label="不满意率"
144
 
172
 
145
 <script>
173
 <script>
146
 import Pagination from "@/components/context/Pagination"; // 对el-pagination 二次封装
174
 import Pagination from "@/components/context/Pagination"; // 对el-pagination 二次封装
175
+import reportComList from "../../cpns/reportComList";
147
 import {
176
 import {
148
   workMaintenanceReport,
177
   workMaintenanceReport,
149
   workMaintenanceCarReport,
178
   workMaintenanceCarReport,
166
       LoadingFlag: false,
195
       LoadingFlag: false,
167
       fieldListFlag: {},
196
       fieldListFlag: {},
168
       dataLists: [],
197
       dataLists: [],
169
-      ruleForm: {
170
-        startTime: [
171
-          getPreDate(3600 * 1000 * 24) + " 19:00:00",
172
-          getNowDate() + " 19:00:00",
173
-        ],
174
-        way: "",
175
-      },
198
+      spanArr: [],
199
+      keyValue: "",
200
+      ruleFormReport: {},
201
+      timeObj: {},
176
     };
202
     };
177
   },
203
   },
178
   computed: {},
204
   computed: {},
179
   mounted() {},
205
   mounted() {},
180
   methods: {
206
   methods: {
207
+    btnClickEvents(value, key, data) {
208
+      this.ruleFormReport = {};
209
+      this.ruleFormReport = this.timeObj;
210
+      this.ruleFormReport.isdone = value;
211
+      if (value === 2) {
212
+        delete this.ruleFormReport.isdone;
213
+      }
214
+      if (this.listType === "2") {
215
+        this.ruleFormReport.types = 1;
216
+        this.ruleFormReport.loweltype = data.F_Type;
217
+        this.ruleFormReport.dealDept = Number(data.DeptId);
218
+      } else if (this.listType === "1") {
219
+        this.ruleFormReport.types = 0;
220
+        this.ruleFormReport.DealUser = data.F_DealUser;
221
+        this.ruleFormReport.dealDept = Number(data.F_DealDept);
222
+      }
223
+      this.$layer.iframe({
224
+        content: {
225
+          content: reportComList, // 传递的组件对象
226
+          parent: this, // 当前的vue对象
227
+          data: { dataParams: this.ruleFormReport, keyValue: key },
228
+        },
229
+        area: ["80%", "90%"],
230
+        title: "工单列表",
231
+      });
232
+      console.log(this.ruleFormReport);
233
+    },
181
     getList(getParams) {
234
     getList(getParams) {
182
       this.LoadingFlag = true;
235
       this.LoadingFlag = true;
236
+      this.timeObj.starttime = getParams.starttime;
237
+      this.timeObj.endtime = getParams.endtime;
183
       return new Promise((resolve) => {
238
       return new Promise((resolve) => {
184
         if (this.listType === "1") {
239
         if (this.listType === "1") {
185
           workMaintenanceReport(getParams).then((response) => {
240
           workMaintenanceReport(getParams).then((response) => {

+ 6 - 6
CallCenterWeb.UI/RMYY/src/views/leadConcern/officeWorkReport/cpns/reportList.vue

122
 import reportComList from "../../cpns/reportComList";
122
 import reportComList from "../../cpns/reportComList";
123
 import { deptRepairReport } from "@/api/leadConcern/leadConcern";
123
 import { deptRepairReport } from "@/api/leadConcern/leadConcern";
124
 
124
 
125
-import { getNowDate, getPreDate, exportExcel, tableSpanArr } from "@/utils";
125
+import { tableSpanArr } from "@/utils";
126
 export default {
126
 export default {
127
   name: "TrafficWorkReport",
127
   name: "TrafficWorkReport",
128
   components: {
128
   components: {
134
       LoadingFlag: false,
134
       LoadingFlag: false,
135
       dataLists: [],
135
       dataLists: [],
136
       spanArr: [],
136
       spanArr: [],
137
+      timeObj: {},
137
       ruleFormReport: {},
138
       ruleFormReport: {},
138
     };
139
     };
139
   },
140
   },
141
   mounted() {},
142
   mounted() {},
142
   methods: {
143
   methods: {
143
     btnClickEvents(value, type, data) {
144
     btnClickEvents(value, type, data) {
144
-      console.log(value, data, this.ruleFormReport);
145
+      this.ruleFormReport = this.timeObj;
145
       this.ruleFormReport.proposerDept = data.F_ProposerDept;
146
       this.ruleFormReport.proposerDept = data.F_ProposerDept;
146
       this.ruleFormReport.type = type;
147
       this.ruleFormReport.type = type;
147
       this.ruleFormReport.isdone = value;
148
       this.ruleFormReport.isdone = value;
154
           parent: this, // 当前的vue对象
155
           parent: this, // 当前的vue对象
155
           data: { dataParams: this.ruleFormReport },
156
           data: { dataParams: this.ruleFormReport },
156
         },
157
         },
157
-        area: ["80%", "80%"],
158
+        area: ["80%", "90%"],
158
         title: "工单列表",
159
         title: "工单列表",
159
       });
160
       });
160
       this.ruleFormReport = {};
161
       this.ruleFormReport = {};
161
     },
162
     },
162
     getList(getParams) {
163
     getList(getParams) {
163
       this.LoadingFlag = true;
164
       this.LoadingFlag = true;
164
-      this.ruleFormReport.starttime = getParams.starttime;
165
-      this.ruleFormReport.endtime = getParams.endtime;
165
+      this.timeObj.starttime = getParams.starttime;
166
+      this.timeObj.endtime = getParams.endtime;
166
       return new Promise((resolve) => {
167
       return new Promise((resolve) => {
167
         deptRepairReport(getParams).then((response) => {
168
         deptRepairReport(getParams).then((response) => {
168
           if (response.state.toLowerCase() === "success") {
169
           if (response.state.toLowerCase() === "success") {
174
         resolve();
175
         resolve();
175
       });
176
       });
176
     },
177
     },
177
-
178
     objectSpanMethod({ row, column, rowIndex, columnIndex }) {
178
     objectSpanMethod({ row, column, rowIndex, columnIndex }) {
179
       if (columnIndex === 0) {
179
       if (columnIndex === 0) {
180
         const _row = this.spanArr[rowIndex];
180
         const _row = this.spanArr[rowIndex];

+ 0 - 2
CallCenterWeb.UI/RMYY/src/views/leadConcern/officeWorkReport/index.vue

86
       console.log(tab, event);
86
       console.log(tab, event);
87
     },
87
     },
88
     btn_search_task() {
88
     btn_search_task() {
89
-      console.log(this.ruleForm);
90
       this.ruleForm.starttime = this.startTime && this.startTime[0];
89
       this.ruleForm.starttime = this.startTime && this.startTime[0];
91
       this.ruleForm.endtime = this.startTime && this.startTime[1];
90
       this.ruleForm.endtime = this.startTime && this.startTime[1];
92
       this.$refs.reportCharts.initLineChart(this.ruleForm);
91
       this.$refs.reportCharts.initLineChart(this.ruleForm);
93
       this.$refs.reportList.getList(this.ruleForm);
92
       this.$refs.reportList.getList(this.ruleForm);
94
     },
93
     },
95
     btn_export() {
94
     btn_export() {
96
-      console.log(this.ruleForm);
97
       this.ruleForm.isdc = 1;
95
       this.ruleForm.isdc = 1;
98
       exportExcel(this.ruleForm, deptRepairReportExpt);
96
       exportExcel(this.ruleForm, deptRepairReportExpt);
99
     },
97
     },