Commit 465c2dd6 authored by zhengke's avatar zhengke

修改

parent 28389ca7
......@@ -160,7 +160,8 @@
</div>
<div v-if="msg.ChangeType==1&&msg.MoveType==2">
<div class="row">
<q-input filled v-model="msg.AllChangePlanItem.OpenTimeStr" class="col-6 q-pr-lg q-pb-lg" mask="date" label="开班时间">
<q-input filled v-model="msg.AllChangePlanItem.OpenTimeStr" class="col-6 q-pr-lg q-pb-lg" mask="date"
label="开班时间">
<template v-slot:append>
<q-icon name="event" class="cursor-pointer">
<q-popup-proxy ref="qDateProxy1" transition-show="scale" transition-hide="scale">
......@@ -169,9 +170,10 @@
</q-icon>
</template>
</q-input>
<q-select filled stack-label option-value="Id" option-label="Name" v-model="msg.AllChangePlanItem.ClassStyle"
ref="ClassStyle" :options="classSetList" label="排课安排" :dense="false" class="col-6 q-pr-lg q-pb-lg"
emit-value map-options @input="changeClassStyle(msg.AllChangePlanItem.ClassStyle)" />
<q-select filled stack-label option-value="Id" option-label="Name"
v-model="msg.AllChangePlanItem.ClassStyle" ref="ClassStyle" :options="classSetList" label="排课安排"
:dense="false" class="col-6 q-pr-lg q-pb-lg" emit-value map-options
@input="changeClassStyle(msg.AllChangePlanItem.ClassStyle)" />
</div>
<div class="row wrap" v-if="msg.AllChangePlanItem.ClassStyle==1">
<div class="col-6">
......@@ -293,7 +295,8 @@
<div class="row wrap" style="margin-top:30px;">
<div class="col-6">
<q-input filled stack-label maxlength="6" v-model="msg.AllChangePlanItem.ClassHours" :dense="false"
class="col-6 q-pr-lg q-pb-lg" label="学习课时" @keyup.native="checkInteger(msg.AllChangePlanItem,'ClassHours')" />
class="col-6 q-pr-lg q-pb-lg" label="学习课时"
@keyup.native="checkInteger(msg.AllChangePlanItem,'ClassHours')" />
</div>
<div class="col-6">
<q-select label="课时分钟数" filled stack-label v-model="msg.AllChangePlanItem.ClassHourMinute"
......@@ -393,17 +396,17 @@
ClassRoomId: 0,
TeacherId: 0,
OldChangePlanItemList: [],
NewChangePlanItemList: [],
AllChangePlanItem:{
OpenTimeStr:'', //开班时间
ClassStyle: 1, //排课方式(1-周,2-月,3-固定日期,4-约课)
ClassHours:0, //
ClassHourMinute:0,
WeekDayList:[], //周几
TeacherId:0,
ClassRoomId:0,
DefaultTimeList:[]
}
NewChangePlanItemList: [],
AllChangePlanItem: {
OpenTimeStr: '', //开班时间
ClassStyle: 1, //排课方式(1-周,2-月,3-固定日期,4-约课)
ClassHours: 0, //
ClassHourMinute: 0,
WeekDayList: [], //周几
TeacherId: 0,
ClassRoomId: 0,
DefaultTimeList: []
}
},
selected: [],
classList: [],
......@@ -663,8 +666,30 @@
newObj.PlanTimeList.push(obj);
})
this.msg.NewChangePlanItemList.push(newObj);
})
this.msg.AllChangePlanItem={};
})
this.msg.AllChangePlanItem = {};
//日期相同 上课时间不能相同
// if(this.msg.OldChangePlanItemList.length>0&&this.msg.NewChangePlanItemList.length>0){
// for(let i=0;i<this.msg.OldChangePlanItemList.length;i++){
// for(let j=0;j<this.msg.NewChangePlanItemList.length;j++){
// if(this.msg.OldChangePlanItemList[i].ClassDate==this.msg.NewChangePlanItemList[j].ClassDate){
// for(let k=0;k<this.msg.OldChangePlanItemList[i].PlanTimeList.length;k++){
// for(let p=0;p<this.msg.NewChangePlanItemList[j].PlanTimeList.length;p++){
// if((this.msg.OldChangePlanItemList[i].PlanTimeList[k].StartTime==this.msg.NewChangePlanItemList[j].PlanTimeList[p].StartTime)&&
// (this.msg.OldChangePlanItemList[i].PlanTimeList[k].EndTime==this.msg.NewChangePlanItemList[j].PlanTimeList[p].EndTime)){
// this.$q.notify({
// type: 'negative',
// position: "top",
// message: `请改变第${p+1}节课目标时间`
// })
// return;
// }
// }
// }
// }
// }
// }
// }
} else {
this.$q.notify({
type: 'negative',
......@@ -676,8 +701,8 @@
}
//变更类型课程时间 变更范围 全局
if (this.msg.ChangeType == 1 && this.msg.MoveType == 2) {
this.msg.AllChangePlanItem.WeekDayList = this.checkedDays;
this.msg.AllChangePlanItem.DefaultTimeList = this.DefaultPlanTimeList;
this.msg.AllChangePlanItem.WeekDayList = this.checkedDays;
this.msg.AllChangePlanItem.DefaultTimeList = this.DefaultPlanTimeList;
}
//变更类型老师 变更范围单个或多个
if (this.msg.ChangeType == 2 && this.msg.MoveType == 1) {
......@@ -740,8 +765,8 @@
newObj.PlanTimeList.push(obj);
})
this.msg.NewChangePlanItemList.push(newObj);
})
this.msg.AllChangePlanItem={};
})
this.msg.AllChangePlanItem = {};
} else {
this.$q.notify({
type: 'negative',
......@@ -753,7 +778,7 @@
}
//变更类型老师 变更范围 单全局
if (this.msg.ChangeType == 2 && this.msg.MoveType == 2) {
this.msg.AllChangePlanItem.TeacherId = this.msg.TeacherId;
this.msg.AllChangePlanItem.TeacherId = this.msg.TeacherId;
}
//变更类型教室 变更范围单个或多个
if (this.msg.ChangeType == 3 && this.msg.MoveType == 1) {
......@@ -816,8 +841,8 @@
newObj.PlanTimeList.push(obj);
})
this.msg.NewChangePlanItemList.push(newObj);
})
this.msg.AllChangePlanItem={};
})
this.msg.AllChangePlanItem = {};
} else {
this.$q.notify({
type: 'negative',
......@@ -829,7 +854,7 @@
}
//变更类型教室 变更范围全局
if (this.msg.ChangeType == 3 && this.msg.MoveType == 2) {
this.msg.AllChangePlanItem.ClassRoomId = this.msg.ClassRoomId;
this.msg.AllChangePlanItem.ClassRoomId = this.msg.ClassRoomId;
}
//变更类型 取消上课 变更范围单个或多个
if (this.msg.ChangeType == 4 && this.msg.MoveType == 1) {
......@@ -860,8 +885,8 @@
obj.PlanTimeList.push(obj2);
})
this.msg.OldChangePlanItemList.push(obj);
})
this.msg.AllChangePlanItem={};
})
this.msg.AllChangePlanItem = {};
} else {
this.$q.notify({
type: 'negative',
......@@ -870,25 +895,25 @@
})
return;
}
}
//变更类型 取消上课 变更范围 全局
if (this.msg.ChangeType == 4 && this.msg.MoveType ==2){
this.msg.OldChangePlanItemList = [];
this.msg.NewChangePlanItemList = [];
this.msg.AllChangePlanItem={}
}
}
//变更类型 取消上课 变更范围 全局
if (this.msg.ChangeType == 4 && this.msg.MoveType == 2) {
this.msg.OldChangePlanItemList = [];
this.msg.NewChangePlanItemList = [];
this.msg.AllChangePlanItem = {}
}
SetChangeClassPlan(this.msg).then(res => {
if (res.Code == 1) {
this.closeSaveForm();
this.$emit("success")
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: res.Message,
position: "top"
});
}
this.closeSaveForm();
this.$emit("success")
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: res.Message,
position: "top"
});
}
})
},
proteinRangeValidation(val) {
......@@ -934,8 +959,8 @@
}).PlanList
},
changeTypeResult(val) {
this.selected=[];
},
this.selected = [];
},
changeSchool(val) {
this.queryClass.SchoolId = val
this.getClass()
......@@ -1011,8 +1036,8 @@
DateList: [],
TimeList: [{
StartTime: "",
EndTime: "",
TimeHour:''
EndTime: "",
TimeHour: ''
}],
}
this.DefaultPlanTimeList.push(planObj);
......
......@@ -29,7 +29,7 @@
</div>
<div class="col-4">
<q-btn color="accent" size="sm" class="q-mr-md" style="margin-top:2px;" @click="exchangeType" :label="typeName" />
<q-btn color="negative" size="sm" label="调课申请" @click="openForm" style="display:none;"></q-btn>
<q-btn color="negative" size="sm" label="调课申请" @click="openForm"></q-btn>
</div>
</div>
<classmateForm :dataList="dataList" v-if="commonType==1"></classmateForm>
......
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