Commit 7222c2ebc78a72bab40813722fa60bf5f3c0ff4a
1 parent
109a6161
汇总前置条件修改,教学,行政可汇总
Showing
8 changed files
with
53 additions
and
81 deletions
src/views/basic/ask/analysis.vue
@@ -112,7 +112,7 @@ export default { | @@ -112,7 +112,7 @@ export default { | ||
112 | return { | 112 | return { |
113 | role: "", | 113 | role: "", |
114 | loading: false, | 114 | loading: false, |
115 | - classId: "", | 115 | + classIds: [], |
116 | className: "", | 116 | className: "", |
117 | subjectNames: "", | 117 | subjectNames: "", |
118 | id: [], | 118 | id: [], |
@@ -136,7 +136,7 @@ export default { | @@ -136,7 +136,7 @@ export default { | ||
136 | this.types = Number(this.$route.query.types); | 136 | this.types = Number(this.$route.query.types); |
137 | // this.className = this.$route.query.className; | 137 | // this.className = this.$route.query.className; |
138 | const queryData = JSON.parse(this.$route.query.params); | 138 | const queryData = JSON.parse(this.$route.query.params); |
139 | - this.classId = this.$route.query.classId; | 139 | + this.classIds = this.$route.query.classIds; |
140 | console.log(this.$route.query); | 140 | console.log(this.$route.query); |
141 | this.subjectNames = this.$route.query.subjectNames.split(","); | 141 | this.subjectNames = this.$route.query.subjectNames.split(","); |
142 | if (this.types == 1) { | 142 | if (this.types == 1) { |
@@ -279,13 +279,13 @@ export default { | @@ -279,13 +279,13 @@ export default { | ||
279 | query.type = this.type - 1; | 279 | query.type = this.type - 1; |
280 | } else { | 280 | } else { |
281 | query.periodIds = this.id; | 281 | query.periodIds = this.id; |
282 | + query.classIds = this.classIds; | ||
282 | if (this.types == 3) { | 283 | if (this.types == 3) { |
283 | query.subjectNames = this.subjectNames; | 284 | query.subjectNames = this.subjectNames; |
284 | } | 285 | } |
285 | } | 286 | } |
286 | this.loading = true; | 287 | this.loading = true; |
287 | let { data, info, status } = await queryData({ | 288 | let { data, info, status } = await queryData({ |
288 | - classId: this.classId, | ||
289 | ...query, | 289 | ...query, |
290 | }); | 290 | }); |
291 | this.loading = false; | 291 | this.loading = false; |
@@ -307,7 +307,7 @@ export default { | @@ -307,7 +307,7 @@ export default { | ||
307 | queryData = this.$request.cTPhaseAnswerReport; | 307 | queryData = this.$request.cTPhaseAnswerReport; |
308 | } | 308 | } |
309 | if (this.types != 1) { | 309 | if (this.types != 1) { |
310 | - query.classId = this.classId; | 310 | + query.classIds = this.classIds; |
311 | } | 311 | } |
312 | this.loading = true; | 312 | this.loading = true; |
313 | let { data, info, status } = await queryData({ | 313 | let { data, info, status } = await queryData({ |
@@ -351,16 +351,17 @@ export default { | @@ -351,16 +351,17 @@ export default { | ||
351 | : this.$request.exportPeriodReport; | 351 | : this.$request.exportPeriodReport; |
352 | } else if (this.types == 2) { | 352 | } else if (this.types == 2) { |
353 | query.periodIds = this.id; | 353 | query.periodIds = this.id; |
354 | + query.classIds = this.classIds; | ||
354 | exportPeriodReport = | 355 | exportPeriodReport = |
355 | this.role == "ROLE_PERSONAL" | 356 | this.role == "ROLE_PERSONAL" |
356 | ? this.$request.pExportPhaseAnswerReport | 357 | ? this.$request.pExportPhaseAnswerReport |
357 | : this.$request.exportPhaseAnswerReport; | 358 | : this.$request.exportPhaseAnswerReport; |
358 | } else { | 359 | } else { |
359 | query.periodIds = this.id; | 360 | query.periodIds = this.id; |
361 | + query.classIds = this.classIds; | ||
360 | exportPeriodReport = this.$request.cTExportPhaseAnswerReport; | 362 | exportPeriodReport = this.$request.cTExportPhaseAnswerReport; |
361 | } | 363 | } |
362 | const data = await exportPeriodReport({ | 364 | const data = await exportPeriodReport({ |
363 | - classId: this.classId, | ||
364 | ...query, | 365 | ...query, |
365 | }); | 366 | }); |
366 | this.exportLoading = false; | 367 | this.exportLoading = false; |
src/views/basic/ask/list.vue
@@ -38,11 +38,14 @@ | @@ -38,11 +38,14 @@ | ||
38 | > | 38 | > |
39 | <el-table-column align="center" width="48"> | 39 | <el-table-column align="center" width="48"> |
40 | <template slot-scope="scope"> | 40 | <template slot-scope="scope"> |
41 | - <el-checkbox | 41 | + <!-- <el-checkbox |
42 | v-model="multipleSelection" | 42 | v-model="multipleSelection" |
43 | :label="scope.row.id" | 43 | :label="scope.row.id" |
44 | :disabled="checkboxDisabled(scope.row)" | 44 | :disabled="checkboxDisabled(scope.row)" |
45 | ><span></span | 45 | ><span></span |
46 | + ></el-checkbox> --> | ||
47 | + <el-checkbox v-model="multipleSelection" :label="scope.row.id" | ||
48 | + ><span></span | ||
46 | ></el-checkbox> | 49 | ></el-checkbox> |
47 | </template> | 50 | </template> |
48 | </el-table-column> | 51 | </el-table-column> |
@@ -267,7 +270,7 @@ export default { | @@ -267,7 +270,7 @@ export default { | ||
267 | return; | 270 | return; |
268 | } | 271 | } |
269 | let subjectArr = []; | 272 | let subjectArr = []; |
270 | - let classId = ""; | 273 | + let classIds = []; |
271 | let multipleData = []; | 274 | let multipleData = []; |
272 | let multipleSelectionData = []; | 275 | let multipleSelectionData = []; |
273 | Object.keys(this.multipleSelectionObj).map((keys) => { | 276 | Object.keys(this.multipleSelectionObj).map((keys) => { |
@@ -279,10 +282,11 @@ export default { | @@ -279,10 +282,11 @@ export default { | ||
279 | if (this.multipleSelection.includes(item.id)) { | 282 | if (this.multipleSelection.includes(item.id)) { |
280 | subjectArr.push(item.subjectName); | 283 | subjectArr.push(item.subjectName); |
281 | multipleData.push(item); | 284 | multipleData.push(item); |
282 | - classId = item.classId; | 285 | + classIds.push(item.classId); |
283 | } | 286 | } |
284 | }); | 287 | }); |
285 | subjectArr = [...new Set(subjectArr)]; | 288 | subjectArr = [...new Set(subjectArr)]; |
289 | + classIds = [...new Set(classIds)]; | ||
286 | if (this.multipleSelection.length == 1) { | 290 | if (this.multipleSelection.length == 1) { |
287 | this.$router.push({ | 291 | this.$router.push({ |
288 | path: "/askAnalysis", | 292 | path: "/askAnalysis", |
@@ -290,6 +294,7 @@ export default { | @@ -290,6 +294,7 @@ export default { | ||
290 | id: JSON.stringify(this.multipleSelection), | 294 | id: JSON.stringify(this.multipleSelection), |
291 | types: 1, | 295 | types: 1, |
292 | subjectNames: subjectArr[0], | 296 | subjectNames: subjectArr[0], |
297 | + classIds: classIds, | ||
293 | params: this.$route.query.params, | 298 | params: this.$route.query.params, |
294 | }, | 299 | }, |
295 | }); | 300 | }); |
@@ -306,7 +311,8 @@ export default { | @@ -306,7 +311,8 @@ export default { | ||
306 | : 3, | 311 | : 3, |
307 | subjectNames: subjectArr.join(","), | 312 | subjectNames: subjectArr.join(","), |
308 | params: this.$route.query.params, | 313 | params: this.$route.query.params, |
309 | - classId: classId, | 314 | + // classId: classId, |
315 | + classIds: classIds, | ||
310 | }, | 316 | }, |
311 | }); | 317 | }); |
312 | } | 318 | } |
src/views/basic/test/analysis.vue
@@ -17,7 +17,7 @@ | @@ -17,7 +17,7 @@ | ||
17 | v-if="type == 1" | 17 | v-if="type == 1" |
18 | :role="role" | 18 | :role="role" |
19 | :id="id" | 19 | :id="id" |
20 | - :classId="classId" | 20 | + :classIds="classIds" |
21 | :subjectName="subjectName" | 21 | :subjectName="subjectName" |
22 | :title="title" | 22 | :title="title" |
23 | :score="score" | 23 | :score="score" |
@@ -27,14 +27,14 @@ | @@ -27,14 +27,14 @@ | ||
27 | v-else-if="type == 2" | 27 | v-else-if="type == 2" |
28 | :role="role" | 28 | :role="role" |
29 | :ids="ids" | 29 | :ids="ids" |
30 | - :classId="classId" | 30 | + :classIds="classIds" |
31 | :subjectName="subjectName" | 31 | :subjectName="subjectName" |
32 | /> | 32 | /> |
33 | <MultipleSubTest | 33 | <MultipleSubTest |
34 | v-else-if="type == 3" | 34 | v-else-if="type == 3" |
35 | :role="role" | 35 | :role="role" |
36 | :ids="ids" | 36 | :ids="ids" |
37 | - :classId="classId" | 37 | + :classIds="classIds" |
38 | :subjectName="subjectName" | 38 | :subjectName="subjectName" |
39 | /> | 39 | /> |
40 | <Contrast | 40 | <Contrast |
@@ -65,7 +65,7 @@ export default { | @@ -65,7 +65,7 @@ export default { | ||
65 | id: "", | 65 | id: "", |
66 | ids: [], | 66 | ids: [], |
67 | type: 0, | 67 | type: 0, |
68 | - classId: "", | 68 | + classIds: [], |
69 | subjectName: "", | 69 | subjectName: "", |
70 | title: "", | 70 | title: "", |
71 | score: 0, | 71 | score: 0, |
@@ -82,7 +82,7 @@ export default { | @@ -82,7 +82,7 @@ export default { | ||
82 | this.ids = | 82 | this.ids = |
83 | (this.$route.query.ids && this.$route.query.ids.split(",")) || []; | 83 | (this.$route.query.ids && this.$route.query.ids.split(",")) || []; |
84 | this.type = this.$route.query.type; | 84 | this.type = this.$route.query.type; |
85 | - this.classId = this.$route.query.classId || ""; | 85 | + this.classIds = this.$route.query.classIds || []; |
86 | this.title = this.$route.query.title || ""; | 86 | this.title = this.$route.query.title || ""; |
87 | this.subjectName = this.$route.query.subjectName || ""; | 87 | this.subjectName = this.$route.query.subjectName || ""; |
88 | }, | 88 | }, |
src/views/basic/test/components/multipleSubTest.vue
@@ -116,7 +116,7 @@ export default { | @@ -116,7 +116,7 @@ export default { | ||
116 | props: { | 116 | props: { |
117 | role: "", | 117 | role: "", |
118 | ids: Array, | 118 | ids: Array, |
119 | - classId: String, | 119 | + classIds: Array, |
120 | subjectName: String, | 120 | subjectName: String, |
121 | }, | 121 | }, |
122 | data() { | 122 | data() { |
@@ -259,7 +259,7 @@ export default { | @@ -259,7 +259,7 @@ export default { | ||
259 | async phaseExamReport() { | 259 | async phaseExamReport() { |
260 | this.loading = true; | 260 | this.loading = true; |
261 | const { data, status, info } = await this.$request.cTPhaseExamReport({ | 261 | const { data, status, info } = await this.$request.cTPhaseExamReport({ |
262 | - classId: this.classId, | 262 | + classIds: this.classIds, |
263 | examIds: this.ids, | 263 | examIds: this.ids, |
264 | subjectNames: this.subjectList, | 264 | subjectNames: this.subjectList, |
265 | }); | 265 | }); |
@@ -311,7 +311,7 @@ export default { | @@ -311,7 +311,7 @@ export default { | ||
311 | } | 311 | } |
312 | 312 | ||
313 | const data = await this.$request.cTExportPhaseExamReport({ | 313 | const data = await this.$request.cTExportPhaseExamReport({ |
314 | - classId: this.classId, | 314 | + classIds: this.classIds, |
315 | examIds: this.ids, | 315 | examIds: this.ids, |
316 | ...query, | 316 | ...query, |
317 | }); | 317 | }); |
src/views/basic/test/components/multipleTest.vue
@@ -14,11 +14,9 @@ | @@ -14,11 +14,9 @@ | ||
14 | fixed | 14 | fixed |
15 | ></el-table-column> | 15 | ></el-table-column> |
16 | <el-table-column prop="studentName" label="姓名" fixed align="center"> | 16 | <el-table-column prop="studentName" label="姓名" fixed align="center"> |
17 | - <template slot-scope="scoped" | ||
18 | - ><span class="click-b" @click="toPortrait(scoped.row)"> | ||
19 | - {{ scoped.row.studentName }} | ||
20 | - </span></template | ||
21 | - ></el-table-column | 17 | + <template slot-scope="scoped"> |
18 | + {{ scoped.row.studentName }} | ||
19 | + </template></el-table-column | ||
22 | > | 20 | > |
23 | <el-table-column | 21 | <el-table-column |
24 | align="center" | 22 | align="center" |
@@ -105,7 +103,7 @@ export default { | @@ -105,7 +103,7 @@ export default { | ||
105 | props: { | 103 | props: { |
106 | role: "", | 104 | role: "", |
107 | ids: Array, | 105 | ids: Array, |
108 | - classId: String, | 106 | + classIds: Array, |
109 | subjectName: String, | 107 | subjectName: String, |
110 | }, | 108 | }, |
111 | data() { | 109 | data() { |
@@ -140,42 +138,6 @@ export default { | @@ -140,42 +138,6 @@ export default { | ||
140 | print() { | 138 | print() { |
141 | tablePrint("print-content", this.subjectName + "汇总报表"); | 139 | tablePrint("print-content", this.subjectName + "汇总报表"); |
142 | }, | 140 | }, |
143 | - toPortrait(obj) { | ||
144 | - //暂时不上线 | ||
145 | - return; | ||
146 | - if (this.$store.getters.code) { | ||
147 | - return; | ||
148 | - } | ||
149 | - let subjectNames = []; | ||
150 | - subjectNames = | ||
151 | - this.role == "ROLE_BANZHUREN" | ||
152 | - ? [...this.query["subjectNames"]] | ||
153 | - : [this.query["subjectNames"]]; | ||
154 | - if ( | ||
155 | - this.query["subjectNames"] && | ||
156 | - this.query["subjectNames"]?.length == 1 && | ||
157 | - this.query["subjectNames"][0] == "全部" | ||
158 | - ) { | ||
159 | - subjectNames = this.subjectList.map((item) => { | ||
160 | - return item.value; | ||
161 | - }); | ||
162 | - subjectNames?.shift(); | ||
163 | - } | ||
164 | - //去学生画像 | ||
165 | - this.$router.push({ | ||
166 | - path: "/portraitDetail", | ||
167 | - query: { | ||
168 | - id: obj.studentId, | ||
169 | - classId: this.query.classId, | ||
170 | - subjectNames: subjectNames.join(","), | ||
171 | - studentName: obj.studentName, | ||
172 | - studentCode: obj.studentCode, | ||
173 | - startDay: this.query.startDay, | ||
174 | - endDay: this.query.endDay, | ||
175 | - date: this.date, | ||
176 | - }, | ||
177 | - }); | ||
178 | - }, | ||
179 | //查看折线图 | 141 | //查看折线图 |
180 | openChart(obj) { | 142 | openChart(obj) { |
181 | this.studentName = obj.studentName; | 143 | this.studentName = obj.studentName; |
@@ -212,7 +174,7 @@ export default { | @@ -212,7 +174,7 @@ export default { | ||
212 | ? this.$request.pPhaseExamReport | 174 | ? this.$request.pPhaseExamReport |
213 | : this.$request.phaseExamReport; | 175 | : this.$request.phaseExamReport; |
214 | const { data, status, info } = await phaseExamReport({ | 176 | const { data, status, info } = await phaseExamReport({ |
215 | - classId: this.classId, | 177 | + classIds: this.classIds, |
216 | examIds: this.ids, | 178 | examIds: this.ids, |
217 | subjectName: this.subjectName, | 179 | subjectName: this.subjectName, |
218 | }); | 180 | }); |
@@ -277,7 +239,7 @@ export default { | @@ -277,7 +239,7 @@ export default { | ||
277 | ? this.$request.pExportPhaseExamReport | 239 | ? this.$request.pExportPhaseExamReport |
278 | : this.$request.exportPhaseExamReport; | 240 | : this.$request.exportPhaseExamReport; |
279 | const data = await exportPhaseExamReport({ | 241 | const data = await exportPhaseExamReport({ |
280 | - classId: this.classId, | 242 | + classIds: this.classIds, |
281 | examIds: this.ids, | 243 | examIds: this.ids, |
282 | ...query, | 244 | ...query, |
283 | }); | 245 | }); |
src/views/basic/test/components/test.vue
@@ -518,7 +518,7 @@ export default { | @@ -518,7 +518,7 @@ export default { | ||
518 | role: "", | 518 | role: "", |
519 | id: "", | 519 | id: "", |
520 | title: String, | 520 | title: String, |
521 | - classId: String, | 521 | + classIds: Array, |
522 | subjectName: String, | 522 | subjectName: String, |
523 | examType: String, | 523 | examType: String, |
524 | score: { | 524 | score: { |
@@ -666,7 +666,7 @@ export default { | @@ -666,7 +666,7 @@ export default { | ||
666 | } | 666 | } |
667 | this.loadingTange = true; | 667 | this.loadingTange = true; |
668 | let { data, status, info } = await this.$request.setLowRange({ | 668 | let { data, status, info } = await this.$request.setLowRange({ |
669 | - classId: this.classId, | 669 | + classId: this.classIds[0], |
670 | subjectName: this.subjectName, | 670 | subjectName: this.subjectName, |
671 | ...this.lowRange, | 671 | ...this.lowRange, |
672 | }); | 672 | }); |
src/views/basic/test/list.vue
@@ -327,7 +327,7 @@ export default { | @@ -327,7 +327,7 @@ export default { | ||
327 | return; | 327 | return; |
328 | } | 328 | } |
329 | let subjectArr = []; | 329 | let subjectArr = []; |
330 | - let classIds = ""; | 330 | + let classIds = []; |
331 | let multipleData = []; | 331 | let multipleData = []; |
332 | let multipleSelectionData = []; | 332 | let multipleSelectionData = []; |
333 | Object.keys(this.multipleSelectionObj).map((keys) => { | 333 | Object.keys(this.multipleSelectionObj).map((keys) => { |
@@ -339,10 +339,11 @@ export default { | @@ -339,10 +339,11 @@ export default { | ||
339 | if (this.multipleSelection.includes(item.id)) { | 339 | if (this.multipleSelection.includes(item.id)) { |
340 | subjectArr.push(item.subjectName); | 340 | subjectArr.push(item.subjectName); |
341 | multipleData.push(item); | 341 | multipleData.push(item); |
342 | - classIds = item.classId; | 342 | + classIds.push(item.classId); |
343 | } | 343 | } |
344 | }); | 344 | }); |
345 | subjectArr = [...new Set(subjectArr)]; | 345 | subjectArr = [...new Set(subjectArr)]; |
346 | + classIds = [...new Set(classIds)]; | ||
346 | console.log(subjectArr); | 347 | console.log(subjectArr); |
347 | if (this.multipleSelection.length == 1) { | 348 | if (this.multipleSelection.length == 1) { |
348 | this.$router.push({ | 349 | this.$router.push({ |
@@ -353,7 +354,7 @@ export default { | @@ -353,7 +354,7 @@ export default { | ||
353 | score: multipleData[0].examPaperScore || 0, | 354 | score: multipleData[0].examPaperScore || 0, |
354 | type: 1, | 355 | type: 1, |
355 | subjectName: subjectArr.join(), | 356 | subjectName: subjectArr.join(), |
356 | - classId: classIds, | 357 | + classIds: classIds, |
357 | params: this.$route.query.params, | 358 | params: this.$route.query.params, |
358 | }, | 359 | }, |
359 | }); | 360 | }); |
@@ -363,7 +364,7 @@ export default { | @@ -363,7 +364,7 @@ export default { | ||
363 | path: "/testAnalysis", | 364 | path: "/testAnalysis", |
364 | query: { | 365 | query: { |
365 | ids: this.multipleSelection.join(), | 366 | ids: this.multipleSelection.join(), |
366 | - classId: classIds, | 367 | + classIds: classIds, |
367 | type: subjectArr.length == 1 ? 2 : 3, | 368 | type: subjectArr.length == 1 ? 2 : 3, |
368 | subjectName: subjectArr.join(), | 369 | subjectName: subjectArr.join(), |
369 | params: this.$route.query.params, | 370 | params: this.$route.query.params, |
@@ -390,19 +391,20 @@ export default { | @@ -390,19 +391,20 @@ export default { | ||
390 | // 班主任教学班不能与行政班汇总 | 391 | // 班主任教学班不能与行政班汇总 |
391 | checkboxDisabled(obj) { | 392 | checkboxDisabled(obj) { |
392 | if (obj.examStartTime) { | 393 | if (obj.examStartTime) { |
393 | - if (this.role == "ROLE_BANZHUREN") { | ||
394 | - let classId = | ||
395 | - (this.multipleSelectionObj[1] && | ||
396 | - this.multipleSelectionObj[1][0]?.classId) || | ||
397 | - ""; | ||
398 | - if (classId) { | ||
399 | - return obj.classId == classId ? false : true; | ||
400 | - } else { | ||
401 | - return false; | ||
402 | - } | ||
403 | - } else { | ||
404 | - return false; | ||
405 | - } | 394 | + // if (this.role == "ROLE_BANZHUREN") { |
395 | + // let classId = | ||
396 | + // (this.multipleSelectionObj[1] && | ||
397 | + // this.multipleSelectionObj[1][0]?.classId) || | ||
398 | + // ""; | ||
399 | + // if (classId) { | ||
400 | + // return obj.classId == classId ? false : true; | ||
401 | + // } else { | ||
402 | + // return false; | ||
403 | + // } | ||
404 | + // } else { | ||
405 | + // return false; | ||
406 | + // } | ||
407 | + return false; | ||
406 | } else { | 408 | } else { |
407 | return true; | 409 | return true; |
408 | } | 410 | } |
vue.config.js
@@ -22,8 +22,9 @@ module.exports = { | @@ -22,8 +22,9 @@ module.exports = { | ||
22 | }, | 22 | }, |
23 | proxy: { | 23 | proxy: { |
24 | "/": { | 24 | "/": { |
25 | - target:"http://121.40.127.171", | ||
26 | // target:"http://ezquiz.sunvotecloud.cn", | 25 | // target:"http://ezquiz.sunvotecloud.cn", |
26 | + // target:"http://121.40.127.171", | ||
27 | + target:"http://192.168.3.221:8080", | ||
27 | changeOrigin: true, | 28 | changeOrigin: true, |
28 | ws:true, | 29 | ws:true, |
29 | }, | 30 | }, |