Commit 4d5235d7e2f9165e3388f9bd4e6aaf2c64b02595
1 parent
a9f5dfcf
学生,教师修改,顶部返回备题组卷记录筛选参数
Showing
4 changed files
with
63 additions
and
2 deletions
src/assets/images/example.jpg
0 → 100644
519 KB
src/views/basic/setUp/student.vue
| ... | ... | @@ -352,6 +352,7 @@ export default { |
| 352 | 352 | console.log(hasName); |
| 353 | 353 | if (hasName) { |
| 354 | 354 | this.$message.warning("学生姓名已存在"); |
| 355 | + this.loading = false; | |
| 355 | 356 | return; |
| 356 | 357 | } |
| 357 | 358 | const { data, status, info } = await this.$request.addStudent({ |
| ... | ... | @@ -369,6 +370,7 @@ export default { |
| 369 | 370 | this.$message.error(info); |
| 370 | 371 | } |
| 371 | 372 | } else { |
| 373 | + this.loading = false; | |
| 372 | 374 | this.$message.error("数据有误,请检查!"); |
| 373 | 375 | } |
| 374 | 376 | }); | ... | ... |
src/views/basic/setUp/teacher.vue
| ... | ... | @@ -252,6 +252,21 @@ export default { |
| 252 | 252 | gradeClassList: [], |
| 253 | 253 | gradeSubListClass: [], |
| 254 | 254 | teacherList: [], |
| 255 | + RoleList: [ | |
| 256 | + //角色 | |
| 257 | + { | |
| 258 | + value: 6, | |
| 259 | + label: "班主任", | |
| 260 | + }, | |
| 261 | + { | |
| 262 | + value: 7, | |
| 263 | + label: "任课老师", | |
| 264 | + }, | |
| 265 | + { | |
| 266 | + value: 8, | |
| 267 | + label: "备课组长", | |
| 268 | + }, | |
| 269 | + ], | |
| 255 | 270 | teacherRoleList: [ |
| 256 | 271 | //角色 |
| 257 | 272 | { |
| ... | ... | @@ -324,6 +339,12 @@ export default { |
| 324 | 339 | this.query.type = 0 |
| 325 | 340 | this.query.teacherName = "" |
| 326 | 341 | this.query.phone = "" |
| 342 | + if (this.query.classType === 0) { | |
| 343 | + this.teacherRoleList = [...this.RoleList] | |
| 344 | + } else { | |
| 345 | + this.teacherRoleList = this.RoleList.slice(1, 3) | |
| 346 | + } | |
| 347 | + | |
| 327 | 348 | this._QueryData(6); |
| 328 | 349 | await this._QueryDataGrade(); |
| 329 | 350 | }, |
| ... | ... | @@ -669,6 +690,7 @@ export default { |
| 669 | 690 | query.phone = this.query.phone; |
| 670 | 691 | query.type = this.query.type; |
| 671 | 692 | } else if (type == 4) { |
| 693 | + this.query.classType = 0; | |
| 672 | 694 | this.query.teacherName = ""; |
| 673 | 695 | this.query.phone = ""; |
| 674 | 696 | this.query.gradeClassSub = []; | ... | ... |
src/views/examinationPaper/index.vue
| ... | ... | @@ -134,8 +134,13 @@ |
| 134 | 134 | <el-dialog :close-on-click-modal="false" title="上传word文档" :visible.sync="diaUp" width="600"> |
| 135 | 135 | <upload :url="url" :params="{ type: query.type }" @upSuccess="upSuccess" fileName="下载"> |
| 136 | 136 | <div class="down-box" slot="down"> |
| 137 | - <p>第一步:导出菁优网试卷或 | |
| 138 | - <el-link type="danger" @click="downExcel">模板下载</el-link> 。 | |
| 137 | + <p class="down-head"> <span>第一步:导出菁优网试卷,</span> | |
| 138 | + <!-- <el-link type="danger" @click="downExcel">模板下载</el-link> 。 --> | |
| 139 | + <span class="img-box"> | |
| 140 | + <el-image class="img" :src="examplePic" :preview-src-list="examplePicList"> | |
| 141 | + </el-image> | |
| 142 | + 导出选项示例。 | |
| 143 | + </span> | |
| 139 | 144 | </p> |
| 140 | 145 | <p>第二步:上传完成编辑好的试卷。</p> |
| 141 | 146 | </div> |
| ... | ... | @@ -150,6 +155,7 @@ |
| 150 | 155 | <script> |
| 151 | 156 | import { downloadFile } from "@/utils"; |
| 152 | 157 | import axios from "axios"; |
| 158 | +import example from "@/assets/images/example.jpg" | |
| 153 | 159 | export default { |
| 154 | 160 | name: "examinationPaper", |
| 155 | 161 | data() { |
| ... | ... | @@ -190,6 +196,8 @@ export default { |
| 190 | 196 | }, |
| 191 | 197 | diaUp: false,//上传word弹窗开关 |
| 192 | 198 | url: "/api_html/common/paper/upload",//上传文档地址 |
| 199 | + examplePic: example, | |
| 200 | + examplePicList: [example] | |
| 193 | 201 | }; |
| 194 | 202 | }, |
| 195 | 203 | async created() { |
| ... | ... | @@ -200,6 +208,7 @@ export default { |
| 200 | 208 | this.userName = this.$store.getters.info.name || ""; |
| 201 | 209 | this.query.type = this.$route.query.type || 1; |
| 202 | 210 | this.query.share = this.$route.query.share || 0; |
| 211 | + console.log(1) | |
| 203 | 212 | this._QueryClassList2() |
| 204 | 213 | await this._QueryClassList(); |
| 205 | 214 | if (!this.query.classId) { |
| ... | ... | @@ -279,6 +288,7 @@ export default { |
| 279 | 288 | changPaperType(type) { |
| 280 | 289 | this.query.type = type |
| 281 | 290 | this.changShare(0) |
| 291 | + | |
| 282 | 292 | }, |
| 283 | 293 | changePage(page) { |
| 284 | 294 | this.page = page; |
| ... | ... | @@ -333,6 +343,13 @@ export default { |
| 333 | 343 | async changShare(share) { |
| 334 | 344 | this.query.share = share |
| 335 | 345 | this.page = 1; |
| 346 | + this.$router.replace({ | |
| 347 | + name: "examinationPaper", | |
| 348 | + query: { | |
| 349 | + type: this.query.type, | |
| 350 | + share: this.query.share, | |
| 351 | + } | |
| 352 | + }) | |
| 336 | 353 | this._QueryData(false); |
| 337 | 354 | }, |
| 338 | 355 | // 查找班级 |
| ... | ... | @@ -666,4 +683,24 @@ export default { |
| 666 | 683 | } |
| 667 | 684 | } |
| 668 | 685 | } |
| 686 | + | |
| 687 | +.down-head { | |
| 688 | + display: flex; | |
| 689 | + align-items: center; | |
| 690 | + line-height: 22px; | |
| 691 | + | |
| 692 | + .img-box { | |
| 693 | + position: relative; | |
| 694 | + color: #667ffd; | |
| 695 | + | |
| 696 | + .img { | |
| 697 | + position: absolute; | |
| 698 | + left: -1px; | |
| 699 | + top: -1px; | |
| 700 | + opacity: 0; | |
| 701 | + width: 86px; | |
| 702 | + height: 22px; | |
| 703 | + } | |
| 704 | + } | |
| 705 | +} | |
| 669 | 706 | </style> |
| 670 | 707 | \ No newline at end of file | ... | ... |