|
@@ -910,83 +910,83 @@ export default {
|
|
|
|
|
|
// }
|
|
|
// );
|
|
|
- let sotrage = JSON.parse(localStorage.getItem(`newPractice`));
|
|
|
- if (sotrage?.leftForm?.classOrganId) {
|
|
|
- this.$confirm("检测到您有未提交的数据, 是否恢复?", "提示", {
|
|
|
- confirmButtonText: "确定",
|
|
|
- cancelButtonText: "取消",
|
|
|
- closeOnClickModal: false,
|
|
|
- type: "warning",
|
|
|
- }).then(async () => {
|
|
|
- this.activeStudentList = sotrage.activeStudentList;
|
|
|
- this.centerForm = sotrage.centerForm;
|
|
|
- this.leftForm = sotrage.leftForm;
|
|
|
- this.rightForm = sotrage.rightForm;
|
|
|
- this.timeTable = sotrage.timeTable;
|
|
|
- this.educationList = sotrage.educationList;
|
|
|
- this.courseTypeList = sotrage.courseTypeList;
|
|
|
- // 为了刷新线上课单价和线下课单价
|
|
|
- await vipGroupCategory({
|
|
|
- organId: sotrage?.leftForm?.classOrganId,
|
|
|
- }).then((res) => {
|
|
|
- if (res.code == 200) {
|
|
|
- this.courseTypeList = res.data;
|
|
|
- }
|
|
|
- });
|
|
|
- this.scetionList = sotrage.scetionList;
|
|
|
- this.studentList = sotrage.studentList;
|
|
|
- this.activeList = sotrage.activeList;
|
|
|
- this.studentLimit = sotrage.studentLimit;
|
|
|
- this.teacherList = sotrage.teacherList;
|
|
|
- this.isMusicTheory = sotrage.isMusicTheory;
|
|
|
- this.chioseStudent = sotrage.chioseStudent;
|
|
|
- this.maxCourseNum = sotrage.maxCourseNum;
|
|
|
- this.minCourseNum = sotrage.minCourseNum;
|
|
|
- if (this.leftForm?.courseType) {
|
|
|
- this.changePrice(this.leftForm.courseType);
|
|
|
- }
|
|
|
- });
|
|
|
- }
|
|
|
- } else {
|
|
|
- this.title = "VIP/乐理课申请";
|
|
|
- this.$route.meta.title = "VIP/乐理课申请";
|
|
|
- let sotrage = JSON.parse(localStorage.getItem(`newVip`));
|
|
|
- if (sotrage?.leftForm?.classOrganId) {
|
|
|
- this.$confirm("检测到您有未提交的数据, 是否恢复?", "提示", {
|
|
|
- confirmButtonText: "确定",
|
|
|
- cancelButtonText: "取消",
|
|
|
- closeOnClickModal: false,
|
|
|
- type: "warning",
|
|
|
- }).then(async () => {
|
|
|
- this.activeStudentList = sotrage.activeStudentList;
|
|
|
- this.centerForm = sotrage.centerForm;
|
|
|
- this.leftForm = sotrage.leftForm;
|
|
|
- this.rightForm = sotrage.rightForm;
|
|
|
- this.timeTable = sotrage.timeTable;
|
|
|
- this.educationList = sotrage.educationList;
|
|
|
- this.courseTypeList = sotrage.courseTypeList;
|
|
|
- this.maxCourseNum = sotrage.maxCourseNum;
|
|
|
- this.minCourseNum = sotrage.minCourseNum;
|
|
|
- // 为了刷新线上课单价和线下课单价
|
|
|
- await vipGroupCategory({
|
|
|
- organId: sotrage?.leftForm?.classOrganId,
|
|
|
- }).then((res) => {
|
|
|
- if (res.code == 200) {
|
|
|
- this.courseTypeList = res.data;
|
|
|
- }
|
|
|
- });
|
|
|
- this.scetionList = sotrage.scetionList;
|
|
|
- this.studentList = sotrage.studentList;
|
|
|
- this.activeList = sotrage.activeList;
|
|
|
- this.studentLimit = sotrage.studentLimit;
|
|
|
- this.teacherList = sotrage.teacherList;
|
|
|
- this.isMusicTheory = sotrage.isMusicTheory;
|
|
|
- this.chioseStudent = sotrage.chioseStudent;
|
|
|
- if (this.leftForm?.courseType) {
|
|
|
- this.changePrice(this.leftForm.courseType);
|
|
|
- }
|
|
|
- });
|
|
|
- }
|
|
|
+ // let sotrage = JSON.parse(localStorage.getItem(`newPractice`));
|
|
|
+ // if (sotrage?.leftForm?.classOrganId) {
|
|
|
+ // this.$confirm("检测到您有未提交的数据, 是否恢复?", "提示", {
|
|
|
+ // confirmButtonText: "确定",
|
|
|
+ // cancelButtonText: "取消",
|
|
|
+ // closeOnClickModal: false,
|
|
|
+ // type: "warning",
|
|
|
+ // }).then(async () => {
|
|
|
+ // this.activeStudentList = sotrage.activeStudentList;
|
|
|
+ // this.centerForm = sotrage.centerForm;
|
|
|
+ // this.leftForm = sotrage.leftForm;
|
|
|
+ // this.rightForm = sotrage.rightForm;
|
|
|
+ // this.timeTable = sotrage.timeTable;
|
|
|
+ // this.educationList = sotrage.educationList;
|
|
|
+ // this.courseTypeList = sotrage.courseTypeList;
|
|
|
+ // // 为了刷新线上课单价和线下课单价
|
|
|
+ // await vipGroupCategory({
|
|
|
+ // organId: sotrage?.leftForm?.classOrganId,
|
|
|
+ // }).then((res) => {
|
|
|
+ // if (res.code == 200) {
|
|
|
+ // this.courseTypeList = res.data;
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // this.scetionList = sotrage.scetionList;
|
|
|
+ // this.studentList = sotrage.studentList;
|
|
|
+ // this.activeList = sotrage.activeList;
|
|
|
+ // this.studentLimit = sotrage.studentLimit;
|
|
|
+ // this.teacherList = sotrage.teacherList;
|
|
|
+ // this.isMusicTheory = sotrage.isMusicTheory;
|
|
|
+ // this.chioseStudent = sotrage.chioseStudent;
|
|
|
+ // this.maxCourseNum = sotrage.maxCourseNum;
|
|
|
+ // this.minCourseNum = sotrage.minCourseNum;
|
|
|
+ // if (this.leftForm?.courseType) {
|
|
|
+ // this.changePrice(this.leftForm.courseType);
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // }
|
|
|
+ // } else {
|
|
|
+ // this.title = "VIP/乐理课申请";
|
|
|
+ // this.$route.meta.title = "VIP/乐理课申请";
|
|
|
+ // let sotrage = JSON.parse(localStorage.getItem(`newVip`));
|
|
|
+ // if (sotrage?.leftForm?.classOrganId) {
|
|
|
+ // this.$confirm("检测到您有未提交的数据, 是否恢复?", "提示", {
|
|
|
+ // confirmButtonText: "确定",
|
|
|
+ // cancelButtonText: "取消",
|
|
|
+ // closeOnClickModal: false,
|
|
|
+ // type: "warning",
|
|
|
+ // }).then(async () => {
|
|
|
+ // this.activeStudentList = sotrage.activeStudentList;
|
|
|
+ // this.centerForm = sotrage.centerForm;
|
|
|
+ // this.leftForm = sotrage.leftForm;
|
|
|
+ // this.rightForm = sotrage.rightForm;
|
|
|
+ // this.timeTable = sotrage.timeTable;
|
|
|
+ // this.educationList = sotrage.educationList;
|
|
|
+ // this.courseTypeList = sotrage.courseTypeList;
|
|
|
+ // this.maxCourseNum = sotrage.maxCourseNum;
|
|
|
+ // this.minCourseNum = sotrage.minCourseNum;
|
|
|
+ // // 为了刷新线上课单价和线下课单价
|
|
|
+ // await vipGroupCategory({
|
|
|
+ // organId: sotrage?.leftForm?.classOrganId,
|
|
|
+ // }).then((res) => {
|
|
|
+ // if (res.code == 200) {
|
|
|
+ // this.courseTypeList = res.data;
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // this.scetionList = sotrage.scetionList;
|
|
|
+ // this.studentList = sotrage.studentList;
|
|
|
+ // this.activeList = sotrage.activeList;
|
|
|
+ // this.studentLimit = sotrage.studentLimit;
|
|
|
+ // this.teacherList = sotrage.teacherList;
|
|
|
+ // this.isMusicTheory = sotrage.isMusicTheory;
|
|
|
+ // this.chioseStudent = sotrage.chioseStudent;
|
|
|
+ // if (this.leftForm?.courseType) {
|
|
|
+ // this.changePrice(this.leftForm.courseType);
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // }
|
|
|
}
|
|
|
|
|
|
this.init();
|
|
@@ -998,32 +998,13 @@ export default {
|
|
|
// }, 100);
|
|
|
// this.init();
|
|
|
},
|
|
|
- beforeDestroy() {
|
|
|
- let obj = {
|
|
|
- leftForm: this.leftForm,
|
|
|
- centerForm: this.centerForm,
|
|
|
- rightForm: this.rightForm,
|
|
|
- timeTable: this.timeTable,
|
|
|
- activeStudentList: this.activeStudentList,
|
|
|
- teacherList: this.teacherList,
|
|
|
- educationList: this.educationList,
|
|
|
- courseTypeList: this.courseTypeList,
|
|
|
- scetionList: this.scetionList,
|
|
|
- studentList: this.studentList,
|
|
|
- activeList: this.activeList,
|
|
|
- studentLimit: this.studentLimit,
|
|
|
- isMusicTheory: this.isMusicTheory,
|
|
|
- chioseStudent: this.chioseStudent,
|
|
|
- maxCourseNum: this.maxCourseNum,
|
|
|
- minCourseNum: this.minCourseNum,
|
|
|
-
|
|
|
- // computationalBtn:this.computationalBtn,
|
|
|
- };
|
|
|
- if (this.courseType == "PRACTICE") {
|
|
|
- localStorage.setItem(`newPractice`, JSON.stringify(obj));
|
|
|
- } else {
|
|
|
- localStorage.setItem(`newVip`, JSON.stringify(obj));
|
|
|
- }
|
|
|
+ async beforeDestroy() {
|
|
|
+ this.$confirm("检测到您有未提交的数据, 是否恢复?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ closeOnClickModal: false,
|
|
|
+ type: "warning",
|
|
|
+ }).then(async () => {});
|
|
|
},
|
|
|
methods: {
|
|
|
resetFrom() {
|
|
@@ -1683,6 +1664,11 @@ export default {
|
|
|
}
|
|
|
let onlineTeacherSalary = this.rightForm.onlineCourse || null;
|
|
|
let offlineTeacherSalary = this.rightForm.offlineCourse || null;
|
|
|
+ let studentId = this.activeStudentList
|
|
|
+ .map((stu) => {
|
|
|
+ return stu.studentId;
|
|
|
+ })
|
|
|
+ .join(",");
|
|
|
if (this.courseType == "PRACTICE") {
|
|
|
getPracticeGroupCostCount({
|
|
|
vipGroupActivityId,
|
|
@@ -1696,8 +1682,8 @@ export default {
|
|
|
userId,
|
|
|
giveTeachMode,
|
|
|
singleClassMinutes,
|
|
|
- vipGroupStudentCoursePrices: this.activeStudentList,
|
|
|
organId: this.leftForm?.classOrganId,
|
|
|
+ studentId,
|
|
|
}).then((res) => {
|
|
|
if (res.code == 200) {
|
|
|
this.rightForm.onlineCourse = res.data.onlineTeacherSalary;
|
|
@@ -1719,9 +1705,10 @@ export default {
|
|
|
onlineClassesNum,
|
|
|
offlineClassesNum,
|
|
|
userId,
|
|
|
+ studentIdList: userId,
|
|
|
giveTeachMode,
|
|
|
singleClassMinutes,
|
|
|
- vipGroupStudentCoursePrices: this.activeStudentList,
|
|
|
+ studentIdList: studentId,
|
|
|
}).then((res) => {
|
|
|
if (res.code == 200) {
|
|
|
this.rightForm.onlineCourse = res.data.onlineTeacherSalary;
|