|
@@ -7,7 +7,9 @@
|
|
|
label-position="right"
|
|
|
label-width="120px"
|
|
|
:inline="true">
|
|
|
+ <!-- -->
|
|
|
<el-form-item label="主教老师"
|
|
|
+ v-if="maskForm.type == 'VIP'"
|
|
|
prop="teacher">
|
|
|
<el-select v-model.trim="maskForm.teacher"
|
|
|
style="width:220px!important"
|
|
@@ -20,6 +22,19 @@
|
|
|
:label="item.realName"></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="主教老师"
|
|
|
+ v-else
|
|
|
+ prop="teacher">
|
|
|
+ <el-select v-model.trim="maskForm.teacher"
|
|
|
+ style="width:220px!important"
|
|
|
+ clearable
|
|
|
+ filterable>
|
|
|
+ <el-option v-for="(item,index) in teacherList"
|
|
|
+ :key="index"
|
|
|
+ :value="item.id"
|
|
|
+ :label="item.realName"></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
<el-form-item label="助教老师"
|
|
|
v-if="maskForm.type != 'MUSIC_NETWORK'&&maskForm.type != 'HIGH_ONLINE'&&maskForm.groupType == 'MUSIC'"
|
|
|
prop="assistant">
|
|
@@ -90,8 +105,9 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="教学地点"
|
|
|
- v-if="maskForm.teachMode == 'OFFLINE'&& maskForm.type == 'VIP'">
|
|
|
- <el-select v-model.trim="maskForm.address"
|
|
|
+ v-if="maskForm.teachMode == 'OFFLINE'">
|
|
|
+ <el-select v-model.trim="
|
|
|
+ maskForm.address"
|
|
|
style="width:220px!important"
|
|
|
filterable
|
|
|
clearable>
|
|
@@ -114,6 +130,7 @@
|
|
|
import { diffTimerFormMinute, addTimerFormMinute } from '@/utils/date'
|
|
|
import { getTeacher, resetCourse, getCourseScheduleDetail } from "@/api/buildTeam";
|
|
|
import { getTeachSchool } from "@/api/teacherManager";
|
|
|
+import { getSchool } from "@/api/systemManage"
|
|
|
import cleanDeep from 'clean-deep'
|
|
|
import dayjs from 'dayjs';
|
|
|
export default {
|
|
@@ -220,7 +237,6 @@ export default {
|
|
|
getDetail (id) {
|
|
|
getCourseScheduleDetail({ courseScheduleId: id }).then(res => {
|
|
|
if (res.code == 200) {
|
|
|
- console.log(res.data.groupType)
|
|
|
this.maskForm = {
|
|
|
id: res.data.id,
|
|
|
teacher: res.data.actualTeacherId,
|
|
@@ -231,7 +247,7 @@ export default {
|
|
|
timer: null,
|
|
|
type: res.data.type,
|
|
|
groupType: res.data.groupType,
|
|
|
- schoolId: res.data.schoolId,
|
|
|
+ address: res.data.schoolId,
|
|
|
teachMode: res.data.teachMode,
|
|
|
}
|
|
|
this.maskForm.assistant = [];
|
|
@@ -243,7 +259,7 @@ export default {
|
|
|
let time = diffTimerFormMinute(dayjs(res.data.classDate).format('YYYY-MM-DD'), dayjs(res.data.startClassTime).format('HH:mm'), dayjs(res.data.endClassTime).format('HH:mm'))
|
|
|
console.log(dayjs(res.data.startClassTime).format('HH:mm'))
|
|
|
this.maskForm.timer = time;
|
|
|
- if (this.maskForm.teacher) {
|
|
|
+ if (this.maskForm.teacher && this.maskForm.type == 'VIP') {
|
|
|
getTeachSchool({
|
|
|
userId: this.maskForm.teacher
|
|
|
}).then(res => {
|
|
@@ -251,6 +267,12 @@ export default {
|
|
|
this.schoolList = res.data;
|
|
|
}
|
|
|
})
|
|
|
+ } else {
|
|
|
+ getSchool({ organId: res.data.organId }).then(res => {
|
|
|
+ if (res.code == 200) {
|
|
|
+ this.schoolList = res.data;
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
}
|
|
|
})
|
|
@@ -263,48 +285,6 @@ export default {
|
|
|
this.getDetail(val)
|
|
|
}
|
|
|
},
|
|
|
- // show (val) {
|
|
|
- // console.log(val)
|
|
|
- // this.courseVisible = val;
|
|
|
- // },
|
|
|
- // courseVisible (val) {
|
|
|
- // if (!val) {
|
|
|
- // this.$emit("closeReset");
|
|
|
- // }
|
|
|
- // },
|
|
|
- // item: {
|
|
|
- // immediate: true,
|
|
|
- // deep: true,
|
|
|
- // handler (row, oldValue) {
|
|
|
- // if (row) {
|
|
|
- // console.log(row)
|
|
|
-
|
|
|
- // this.maskForm.assistant = [];
|
|
|
- // for (let i in row.teachingTeachers) {
|
|
|
- // if (row.teachingTeachers[i].teacherRole == "TEACHING") {
|
|
|
- // this.maskForm.assistant.push(row.teachingTeachers[i].userId);
|
|
|
- // }
|
|
|
- // }
|
|
|
- // let time = diffTimerFormMinute(dayjs(row.classDate).format('YYYY-MM-DD'), dayjs(row.startClassTime).format('HH:mm'), dayjs(row.endClassTime).format('HH:mm'))
|
|
|
- // console.log(dayjs(row.startClassTime).format('HH:mm'))
|
|
|
- // this.maskForm.timer = time;
|
|
|
- // } else {
|
|
|
- // this.maskForm = {
|
|
|
- // id: null,
|
|
|
- // teacher: null,
|
|
|
- // assistant: null,
|
|
|
- // date: null,
|
|
|
- // startTime: null,
|
|
|
- // endTime: null,
|
|
|
- // timer: null,
|
|
|
- // type: null,
|
|
|
- // groupType: null,
|
|
|
- // schoolId: null,
|
|
|
- // teachMode: null,
|
|
|
- // }
|
|
|
- // }
|
|
|
- // }
|
|
|
- // },
|
|
|
'maskForm.timer' (val) {
|
|
|
this.$nextTick(res => {
|
|
|
if (val) {
|