提交 909f79f2 authored 作者: lihuihui's avatar lihuihui

update

上级 a632e0c1
......@@ -112,17 +112,25 @@ export default {
},
getCourseList() {
getCourseList({ class_id: this.form.class_id }).then(res => {
console.log(this.form.course_id, 'idid')
this.form.course_id = this.form.course_id.reduce((a, b) => {
if (res.courses.find(i => i.id === b)) {
a.push(b)
}
return a
}, [])
this.courseList = res.courses
})
},
getClassList() {
getClassList().then(res => {
this.form.class_id = res.classes.find(i => i.id === this.form.class_id) ? this.form.class_id : ''
this.classList = res.classes
setTimeout(() => {
if (this.form.class_id) {
this.getCourseList()
}
}, 500)
}, 300)
})
},
submitForm() {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论