Commit efe23b0f authored by 黄奎's avatar 黄奎

取消约课调整

parent f52f0f54
...@@ -79,15 +79,25 @@ ...@@ -79,15 +79,25 @@
Date: this.date, Date: this.date,
TeacherId: this.saveObj.Tid, TeacherId: this.saveObj.Tid,
ShiftSort: this.saveObj.ShiftSort, ShiftSort: this.saveObj.ShiftSort,
AppointIds: this.selectStu.toString() AppointIds: this.selectStu.toString(),
AccountId: this.saveObj.AccountId, //新取消接口参数
ChooseStuList: [], //新取消接口参数
}; };
if (this.selectStu && this.selectStu.length > 0) {
this.selectStu.forEach(item => {
msg.ChooseStuList.push({
AppointId: item,
IsCalcStuCheck: 0
});
})
}
cancelSureAppointment(msg).then(res => { cancelSureAppointment(msg).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
message: "操作成功", message: "操作成功",
position: "top" position: "top"
}); });
this.$emit("success",this.selectStu); this.$emit("success", this.selectStu);
this.selectStu = [] this.selectStu = []
this.changeDig(false) this.changeDig(false)
} }
......
...@@ -201,6 +201,12 @@ ...@@ -201,6 +201,12 @@
//取消预约 //取消预约
cancelSub() { cancelSub() {
let that = this; let that = this;
console.log("that.saveObj",that.saveObj);
const msg = {
Date: that.dateObj.date,
TeacherId: that.saveObj.Tid,
AppointIds: that.checkStuType2.toString()
};
this.$q this.$q
.dialog({ .dialog({
title: "提示信息", title: "提示信息",
...@@ -210,28 +216,24 @@ ...@@ -210,28 +216,24 @@
cancel: "否" cancel: "否"
}) })
.onOk(() => { .onOk(() => {
const msg = {
Date: that.dateObj.date, // CancelAppointment(msg).then(res => {
TeacherId: that.saveObj.Tid, // if (res.Code == 1) {
AppointIds: that.checkStuType2.toString() // that.$q.notify({
}; // message: "操作成功",
CancelAppointment(msg).then(res => { // position: "top"
if (res.Code == 1) { // });
that.$q.notify({ // that.checkStuType2.map(e => {
message: "操作成功", // that.saveObj.GuestList.map((_e, _i) => {
position: "top" // if (e == _e.AppointmentId) {
}); // that.saveObj.GuestList.splice(_i, 1);
that.checkStuType2.map(e => { // }
that.saveObj.GuestList.map((_e, _i) => { // });
if (e == _e.AppointmentId) { // });
that.saveObj.GuestList.splice(_i, 1); // that.checkStuType2 = [];
} // that.$emit("success");
}); // }
}); // });
that.checkStuType2 = [];
that.$emit("success");
}
});
}) })
.onCancel(() => {}); .onCancel(() => {});
}, },
...@@ -270,12 +272,18 @@ ...@@ -270,12 +272,18 @@
AppointIds: "", AppointIds: "",
Date: this.dateObj.date, Date: this.dateObj.date,
ShiftSort: item.ShiftSort, ShiftSort: item.ShiftSort,
TeacherId: item.Tid TeacherId: item.Tid,
AccountId: item.AccountId, //新接口取消约课参数
ChooseStuList: [], //新接口取消约课参数
}; };
var tempList = []; var tempList = [];
if (item.GuestList && item.GuestList.length > 0) { if (item.GuestList && item.GuestList.length > 0) {
item.GuestList.forEach(subItem => { item.GuestList.forEach(subItem => {
tempList.push(subItem.AppointmentId); tempList.push(subItem.AppointmentId);
postMsg.ChooseStuList.push({
AppointId: subItem.AppointmentId,
IsCalcStuCheck: 0
})
}) })
} }
if (tempList && tempList.length > 0) { if (tempList && tempList.length > 0) {
......
...@@ -41,12 +41,12 @@ ...@@ -41,12 +41,12 @@
<!-- <q-btn v-if="msg.ClassType==2" dense text-color="primary" icon="download" flat unelevated label="下载排课表" <!-- <q-btn v-if="msg.ClassType==2" dense text-color="primary" icon="download" flat unelevated label="下载排课表"
@click="DownLoadStuLearnChapterStatic" /> --> @click="DownLoadStuLearnChapterStatic" /> -->
<div style="margin-left:10px;"> <div style="margin-left:10px;">
<q-btn dense text-color="primary" flat unelevated class="q-mr-md" size="sm" icon="download" label="下载老师排课表" <q-btn dense text-color="primary" flat unelevated class="q-mr-md" size="sm" icon="download" label="下载老师排课表"
@click="DownLoadStuLearnChapterStatic" /> @click="DownLoadStuLearnChapterStatic" />
</div> </div>
<q-separator vertical /> <q-separator vertical />
<div style="margin-left:10px;"> <div style="margin-left:10px;">
<q-btn dense text-color="primary" flat unelevated class="q-mr-md" size="sm" icon="download" label="下载学生发课表" <q-btn dense text-color="primary" flat unelevated class="q-mr-md" size="sm" icon="download" label="下载学生发课表"
@click="DownLoadPlanStudentExcel" /> @click="DownLoadPlanStudentExcel" />
</div> </div>
</div> </div>
...@@ -450,7 +450,6 @@ ...@@ -450,7 +450,6 @@
EduDownLoad("/TeacherClass/GetAppointmentPlanStudentExcel", this.msg, (dateStartDate.getMonth() + 1) + "月" + EduDownLoad("/TeacherClass/GetAppointmentPlanStudentExcel", this.msg, (dateStartDate.getMonth() + 1) + "月" +
dateStartDate.getDate() + "日-" + (dateEndDate.getMonth() + 1) + "月" + dateEndDate.getDate() + "日学生排课统计.xls", dateStartDate.getDate() + "日-" + (dateEndDate.getMonth() + 1) + "月" + dateEndDate.getDate() + "日学生排课统计.xls",
res => {}); res => {});
}, },
badgeStyles(event, type, timeStartPos, timeDurationHeight, index, total) { badgeStyles(event, type, timeStartPos, timeDurationHeight, index, total) {
const s = {}; const s = {};
...@@ -514,7 +513,6 @@ ...@@ -514,7 +513,6 @@
TId: 0 TId: 0
}); });
this.legendList = JSON.parse(JSON.stringify(res.Data)); this.legendList = JSON.parse(JSON.stringify(res.Data));
this.legendList.forEach((item, index) => { this.legendList.forEach((item, index) => {
item.bg = this.colorList[index]; item.bg = this.colorList[index];
}); });
...@@ -535,7 +533,6 @@ ...@@ -535,7 +533,6 @@
}, },
getData() { getData() {
GetAppointmentPlanStat(this.msg).then(res => { GetAppointmentPlanStat(this.msg).then(res => {
// this.events = res.Data;
let data = JSON.parse(JSON.stringify(res.Data)); let data = JSON.parse(JSON.stringify(res.Data));
res.Data.map((e, i) => { res.Data.map((e, i) => {
data[i].RList = []; data[i].RList = [];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment