|
@@ -103,7 +103,7 @@
|
|
|
<el-form-item>
|
|
|
<el-button native-type="submit" type="danger">搜索</el-button>
|
|
|
<el-button type="primary" native-type="reset">重置</el-button>
|
|
|
- <el-button type="primary" native-type="reset">导出</el-button>
|
|
|
+ <el-button type="primary" @click="exportCourse">导出</el-button>
|
|
|
</el-form-item>
|
|
|
</save-form>
|
|
|
<div class="btnWraps"></div>
|
|
@@ -595,6 +595,7 @@ import { diffTimerFormMinute, addTimerFormMinute } from "@/utils/date";
|
|
|
import { classTimeList, musicCourseType } from "@/utils/searchArray";
|
|
|
import { getSchool } from "@/api/systemManage";
|
|
|
import cleanDeep from "clean-deep";
|
|
|
+import { Export } from "@/utils/downLoadFile";
|
|
|
import { getMusicGroupCourseScheduleStatistics } from "../api";
|
|
|
let that;
|
|
|
export default {
|
|
@@ -687,9 +688,9 @@ export default {
|
|
|
courseTimeList: {},
|
|
|
typeTimeList: [],
|
|
|
detail: {
|
|
|
- attendanceRate: "",
|
|
|
- homeworkCommitRate: "",
|
|
|
- standardRate: "",
|
|
|
+ attendanceRate: "0.00%",
|
|
|
+ homeworkCommitRate: "0.00%",
|
|
|
+ standardRate: "0.00%",
|
|
|
},
|
|
|
};
|
|
|
},
|
|
@@ -830,11 +831,46 @@ export default {
|
|
|
|
|
|
try {
|
|
|
const res = await getMusicGroupCourseScheduleStatistics({ ...obj });
|
|
|
- this.detail = { ...res.data };
|
|
|
+ if(res.data){
|
|
|
+ this.detail = { ...res.data };
|
|
|
+ }
|
|
|
+
|
|
|
} catch (e) {
|
|
|
console.log(e);
|
|
|
}
|
|
|
},
|
|
|
+ async exportCourse(){
|
|
|
+ // 导出
|
|
|
+ let searchForm = this.searchForm;
|
|
|
+ if (!searchForm.timer) {
|
|
|
+ searchForm.timer = [];
|
|
|
+ }
|
|
|
+ let obj = {
|
|
|
+ classScheduleStatus: searchForm.classStatus || null,
|
|
|
+ classScheduleType: searchForm.courseStatus || null,
|
|
|
+ musicGroupId: this.teamid,
|
|
|
+ startTime: searchForm.timer[0] || null,
|
|
|
+ endTime: searchForm.timer[1] || null,
|
|
|
+ page: this.rules.page,
|
|
|
+ rows: this.rules.limit,
|
|
|
+ classGroupId: searchForm.class || null,
|
|
|
+ isSettlement: searchForm.isSettlement || null,
|
|
|
+ homeworkFlag: searchForm.homeworkFlag,
|
|
|
+ serviceFlag: searchForm.serviceFlag,
|
|
|
+ };
|
|
|
+ Export(
|
|
|
+ this,
|
|
|
+ {
|
|
|
+ url: "/api-web/export/exportMusicGroupCourseScheduleDetail",
|
|
|
+ fileName: "乐团课表详情.xls",
|
|
|
+ method: "get",
|
|
|
+ params: {
|
|
|
+ ...obj
|
|
|
+ },
|
|
|
+ },
|
|
|
+ "您确定导出乐团课表详情?"
|
|
|
+ );
|
|
|
+ },
|
|
|
resetClass(row) {
|
|
|
this.maskForm.teacher = parseInt(row.masterTeacherId);
|
|
|
this.maskForm.courseScheduleType = row.courseScheduleType;
|