|
@@ -8,6 +8,7 @@
|
|
|
class="r_select"
|
|
|
v-model="uname"
|
|
|
placeholder="全部"
|
|
|
+ filterable
|
|
|
>
|
|
|
<el-option
|
|
|
v-for="item in userAarray"
|
|
@@ -121,7 +122,6 @@ export default {
|
|
|
var _userA = this.userAarray;
|
|
|
var _chap = JSON.parse(JSON.stringify(this.chap));
|
|
|
var _task = this.task;
|
|
|
-
|
|
|
if (this.uname.length) {
|
|
|
for (var i = 0; i < _userA.length; i++) {
|
|
|
if (this.uname.join(",").indexOf(_userA[i].userid) != -1) {
|
|
@@ -421,7 +421,21 @@ export default {
|
|
|
// debugger
|
|
|
//生成报告
|
|
|
const link = document.createElement("a");
|
|
|
- link.download = "报告.html"; // 文件名
|
|
|
+ // link.download = "报告.html"; // 文件名
|
|
|
+ let dname = this.course.title+'-'
|
|
|
+ var _uname = [];
|
|
|
+ var _userA = this.userAarray;
|
|
|
+ if (this.uname.length) {
|
|
|
+ for (var i = 0; i < _userA.length; i++) {
|
|
|
+ if (this.uname.join(",").indexOf(_userA[i].userid) != -1) {
|
|
|
+ _uname.push(_userA[i].username);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ dname+=_uname.join('、')+'.html'
|
|
|
+ } else {
|
|
|
+ dname+='全部学生.html'
|
|
|
+ }
|
|
|
+ link.download = dname; // 文件名
|
|
|
link.style.display = "none";
|
|
|
// 创建文件流
|
|
|
// 创建bolb实例时,内容一定要放在[]中
|