|
@@ -66,11 +66,10 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column align='center'
|
|
|
- label="是否排课">
|
|
|
+ label="当前课次">
|
|
|
<template slot-scope="scope">
|
|
|
<div>
|
|
|
- <p v-if="scope.row.totalClassTimes > 0"> 是</p>
|
|
|
- <p v-if="scope.row.totalClassTimes <= 0"> 否</p>
|
|
|
+ {{scope.row.currentClassTimes+'/'+ scope.row.totalClassTimes}}
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
@@ -100,7 +99,24 @@
|
|
|
</div>
|
|
|
<!-- v-if="scope.row.type !='MIX'" -->
|
|
|
<el-button type="text"
|
|
|
- slot="reference">删除</el-button>
|
|
|
+ slot="reference">删除班级</el-button>
|
|
|
+ </el-popover>
|
|
|
+
|
|
|
+ <el-popover placement="top"
|
|
|
+ width="160"
|
|
|
+ :ref="scope.$index">
|
|
|
+ <p>是否清空课表?</p>
|
|
|
+ <div style="text-align: right; margin: 0">
|
|
|
+ <el-button size="mini"
|
|
|
+ type="text"
|
|
|
+ @click="scope._self.$refs[scope.$index].doClose()">取消</el-button>
|
|
|
+ <el-button type="primary"
|
|
|
+ size="mini"
|
|
|
+ @click="clearCourse(scope)">确定</el-button>
|
|
|
+ </div>
|
|
|
+ <!-- v-if="scope.row.type !='MIX'" -->
|
|
|
+ <el-button type="text"
|
|
|
+ slot="reference">清空课表</el-button>
|
|
|
</el-popover>
|
|
|
</div>
|
|
|
</template>
|
|
@@ -333,6 +349,7 @@
|
|
|
<el-form-item label="排课起始时间"
|
|
|
prop="courseTime">
|
|
|
<el-date-picker v-model="teacherForm.courseTime"
|
|
|
+ :picker-options="pickerOptions"
|
|
|
style="width:200px!important;"
|
|
|
type="date"
|
|
|
value-format="yyyy-MM-dd"
|
|
@@ -424,7 +441,7 @@
|
|
|
:key="index">
|
|
|
{{ item.name }}
|
|
|
<el-button type='text'
|
|
|
- @click="removeSiginforMix(item)">删除</el-button>
|
|
|
+ @click="removeSiginforMix(item)">删除班级</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -615,7 +632,7 @@
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
-import { getAllClass, getAllSignClassandTeacher, getAllSignClass, removeSingleClass, getNoClassStudentAll, findSound, teamSoundStudent, findMusicGroupClassTeacher, revisionClassGroup, revisionAddClassGroup, getEmployeeOrgan, getTeacher, findNoClassSingle, getMusicGroupStuNoClassType, classGroupUpdate, getTeamBaseInfo } from '@/api/buildTeam'
|
|
|
+import { getAllClass, getAllSignClassandTeacher, getAllSignClass, removeSingleClass, getNoClassStudentAll, findSound, teamSoundStudent, findMusicGroupClassTeacher, revisionClassGroup, revisionAddClassGroup, getEmployeeOrgan, getTeacher, findNoClassSingle, getMusicGroupStuNoClassType, classGroupUpdate, getTeamBaseInfo, clearClassCourse } from '@/api/buildTeam'
|
|
|
import { getClassAllStudent, removeStudents, addStudents } from '@/api/studentManager'
|
|
|
import { queryEmployByOrganId } from '@/api/systemManage'
|
|
|
|
|
@@ -624,6 +641,11 @@ import qs from 'qs'
|
|
|
export default {
|
|
|
data () {
|
|
|
return {
|
|
|
+ pickerOptions: {
|
|
|
+ disabledDate (time) {
|
|
|
+ return time.getTime() < new Date().getTime()
|
|
|
+ }
|
|
|
+ },
|
|
|
teamid: '',
|
|
|
topForm: {
|
|
|
classType: ''
|
|
@@ -924,6 +946,23 @@ export default {
|
|
|
this.activeListStudent = this.objArrayRemoval(this.activeListStudent, 'userId');
|
|
|
// 将其填入选中的学生
|
|
|
},
|
|
|
+ clearCourse (scope) {
|
|
|
+ clearClassCourse({ classGroupId: scope.row.id }).then(res => {
|
|
|
+ if (res.code == 200) {
|
|
|
+ this.$message.success('清除成功')
|
|
|
+ scope._self.$refs[scope.$index].doClose();
|
|
|
+ // 重新请求列表
|
|
|
+ this.getList(this.activeMixClass);
|
|
|
+ } else {
|
|
|
+ this.$message.error(res.msg)
|
|
|
+ scope._self.$refs[scope.$index].doClose();
|
|
|
+ }
|
|
|
+
|
|
|
+ }).catch(res => {
|
|
|
+ scope._self.$refs[scope.$index].doClose();
|
|
|
+ })
|
|
|
+ // 清空课表
|
|
|
+ },
|
|
|
// 删除班级
|
|
|
removeClass (scope) {
|
|
|
removeSingleClass({ classGroupId: scope.row.id }).then(res => {
|