Commit 92b3f1bb authored by youjie's avatar youjie

no message

parent 11d3b73d
<template>
<div class="page-body MainPlan xg">
<div class="col row wrap q-col-gutter-md">
<div class="col-2 flex">
<el-select v-model="msg.TeacherId" style="width: 100%" placeholder="教师" size="small" @change="getPlanList()">
<el-option v-for="item in TeacherList" :key="item.TeacherName" :label="item.TeacherName" :value="item.TId">
</el-option>
<div slot="prefix" class="full-height flex items-center" style="color: #000; padding-right: 10px">
教师:
</div>
</el-select>
</div>
<div class="col-2">
<el-select v-model="msg.ClassRoomId" style="width: 100%" placeholder="教室" size="small" @change="getTypeWay()">
<el-option v-for="item in ClassRoomList" :key="item.RoomName" :label="item.RoomName" :value="item.RoomId">
</el-option>
<div slot="prefix" class="full-height flex items-center" style="color: #000; padding-right: 10px">
教室:
</div>
</el-select>
</div>
<div class="col-2" style="width: 13%">
<el-date-picker v-model="msg.StartTime" type="date" value-format="yyyy-MM-dd" placeholder="开始日期" size="small"
style="width: 100%" @change="getTypeWay()" :picker-options="picker" :clearable="false">
</el-date-picker>
</div>
<div class="col-2" style="width: 13%">
<el-date-picker v-model="msg.EndTime" type="date" value-format="yyyy-MM-dd" placeholder="结束日期" size="small"
style="width: 100%" @change="getTypeWay()" clear-icon="iconfont icon-guanbi" :picker-options="pickerEnd">
</el-date-picker>
</div>
<div class="col-1" style="width: 10%">
<el-select v-model="msg.ClassType" style="width: 100%" placeholder="类型" size="small" @change="getTypeWay()">
<el-option :key="0" label="全部" :value="0"> </el-option>
<el-option :key="1" label="跟班课" :value="1"> </el-option>
<el-option :key="2" label="试听课" :value="2"> </el-option>
<el-option :key="2" label="预约课" :value="3"> </el-option>
<div slot="prefix" class="full-height flex items-center" style="color: #000; padding-right: 10px">
类型:
</div>
</el-select>
</div>
<div class="col-2 yuyuezhuangtai" style="width: 10%" v-if="msg.ClassType==3">
<el-select v-model="msg.AppointState" style="width: 100%;" placeholder="预约状态" size="small"
@change="getTypeWay()">
<el-option :key="0" label="不限" :value="0"> </el-option>
<el-option :key="0" label="待确认" :value="1"> </el-option>
<el-option :key="1" label="已确认" :value="2"> </el-option>
<div slot="prefix" class="full-height flex items-center"
style="color: #000;margin-right:61px; white-space:nowrap;">
预约状态:
</div>
</el-select>
</div>
<div class="col-3" style="width: 30%">
<q-btn color="accent" size="sm" class="q-mr-md" style="margin-top: 2px" @click="exchangeType"
:label="typeName" />
<q-btn color="accent" size="sm" class="q-mr-md" label="下载计划" @click="downLoadPlan()" />
<q-btn color="negative" size="sm" label="调课申请" @click="openForm"></q-btn>
</div>
</div>
<classmateForm :dataList="dataList" v-if="commonType == 1" :loading="loading"></classmateForm>
<change-class-form v-if="persistent" @close="closeSaveForm" @success="refreshPage"></change-class-form>
<teachTable v-if="commonType == 2" :tableData="tableData" :PageCount="PageCount" :setMsg="tabMsg" :showCZ="false"
@getChange="getChange" :loading="loading"></teachTable>
</div>
</template>
<script>
import {
getTeacherDropDownList,
queryClassRoomList,
} from "../../api/school/index";
import {
GetClassPlanStatistical,
GetClassPlanStatisticalPage,
} from "../../api/teacher/index";
import {
EduDownLoad
} from "../../api/common/common";
import classmateForm from "./components/classmateForm";
import teachTable from "./components/teachTable";
import changeClassForm from "../../components/teacher/changeClassForm.vue";
export default {
meta: {
title: "学员预约统计",
},
components: {
classmateForm,
teachTable,
changeClassForm,
},
data() {
return {
persistent: false,
TeacherList: [], //教师团队
ClassRoomList: [], //
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
dataList: {},
activeNames: [1],
msg: {
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
ClassType: 0,
AppointState: 0,
},
commonType: 1, //1日历模式 2列表模式
typeName: "列表模式",
tabMsg: {
PageIndex: 1,
PageSize: 12,
rowsPerPage: 12,
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
ClassType: 0,
},
tableData: [], //表格数据
PageCount: 0,
picker: {
disabledDate: (time) => {
// let endTime=this.msg.EndTime
// if(endTime){
// return Date.now() - 8.64e7>time.getTime()>=new Date(endTime).getTime()- 8.64e7
// }else{
// return time.getTime() < Date.now() - 8.64e7
// }
},
},
pickerEnd: {
disabledDate: (time) => {
let startTime = this.msg.StartTime;
if (startTime) {
return time.getTime() <= new Date(startTime).getTime() - 8.64e7;
} else {
return time.getTime() < Date.now() - 8.64e7;
}
},
},
loading: false,
};
},
created() {
if (this.$route.query && this.$route.query.ClassType) {
this.msg.ClassType = this.$route.query.ClassType;
}
let date = new Date();
let today =
date.getFullYear() +
"-" +
(date.getMonth() < 9 ?
"0" + (date.getMonth() + 1) :
date.getMonth() + 1) +
"-" +
(date.getDate() < 10 ? "0" + date.getDate() : date.getDate());
this.msg.StartTime = today;
this.tabMsg.StartTime = today;
this.getClassRoomList();
},
mounted() {
this.exchangeType()
this.GetTeacherList();
this.getPlanList();
},
methods: {
downLoadPlan() {
//导出
var newMsg = JSON.parse(JSON.stringify(this.msg));
EduDownLoad("/Class/DownLoadClassPlan", newMsg, "老师上课计划.xls");
},
refreshPage() {
this.getPlanList();
},
openForm() {
this.persistent = true;
},
closeSaveForm() {
this.persistent = false;
},
// 获取校区教室导航列表
getPlanList() {
GetClassPlanStatistical(this.msg).then((res) => {
if (res.Code == 1) {
this.dataList = res.Data;
}
});
},
//获取教师下拉
GetTeacherList() {
getTeacherDropDownList({}).then((res) => {
if (res.Code == 1) {
this.TeacherList = res.Data;
var obj = {
TeacherName: "请选择",
TId: 0,
};
this.TeacherList.unshift(obj);
}
});
},
//获取教室下拉
getClassRoomList() {
queryClassRoomList({}).then((res) => {
if (res.Code == 1) {
this.ClassRoomList = res.Data;
var obj = {
RoomName: "请选择",
RoomId: 0,
};
this.ClassRoomList.unshift(obj);
}
});
},
exchangeType() {
if (this.commonType == 1) {
this.commonType = 2;
this.typeName = "日历模式";
this.getTableList();
} else {
this.commonType = 1;
this.typeName = "列表模式";
this.getPlanList();
}
},
getTableList() {
this.tabMsg.StartTime = this.msg.StartTime;
this.tabMsg.EndTime = this.msg.EndTime;
this.tabMsg.ClassRoomId = this.msg.ClassRoomId;
this.tabMsg.ClassType = this.msg.ClassType;
this.loading = true;
GetClassPlanStatisticalPage(this.tabMsg).then((res) => {
this.loading = false;
if (res.Code == 1) {
this.tableData = res.Data.PageData;
this.PageCount = res.Data.PageCount;
}
});
},
getChange(val) {
this.tabMsg.PageIndex = val;
this.getTableList();
},
getTypeWay() {
if (this.commonType == 2) {
this.getTableList();
} else {
this.getPlanList();
}
},
},
};
</script>
<style lang="scss">
.xg .el-input--prefix .el-input__inner {
padding-left: 50px;
}
.yuyuezhuangtai .el-input--prefix .el-input__inner {
padding-left: 60px;
}
</style>
\ No newline at end of file
<template>
<div class="page-body MainPlan xg">
<div class="col row wrap q-col-gutter-md">
<div class="col-2 flex">
<el-select v-model="msg.TeacherId" style="width: 100%" placeholder="教师" size="small" @change="getPlanList()">
<el-option v-for="item in TeacherList" :key="item.TeacherName" :label="item.TeacherName" :value="item.TId">
</el-option>
<div slot="prefix" class="full-height flex items-center" style="color: #000; padding-right: 10px">
教师:
</div>
</el-select>
</div>
<div class="col-2">
<el-select v-model="msg.ClassRoomId" style="width: 100%" placeholder="教室" size="small" @change="getTypeWay()">
<el-option v-for="item in ClassRoomList" :key="item.RoomName" :label="item.RoomName" :value="item.RoomId">
</el-option>
<div slot="prefix" class="full-height flex items-center" style="color: #000; padding-right: 10px">
教室:
</div>
</el-select>
</div>
<div class="col-2" style="width: 13%">
<el-date-picker v-model="msg.StartTime" type="date" value-format="yyyy-MM-dd" placeholder="开始日期" size="small"
style="width: 100%" @change="getTypeWay()" :picker-options="picker" :clearable="false">
</el-date-picker>
</div>
<div class="col-2" style="width: 13%">
<el-date-picker v-model="msg.EndTime" type="date" value-format="yyyy-MM-dd" placeholder="结束日期" size="small"
style="width: 100%" @change="getTypeWay()" clear-icon="iconfont icon-guanbi" :picker-options="pickerEnd">
</el-date-picker>
</div>
<div class="col-1" style="width: 10%">
<el-select v-model="msg.ClassType" style="width: 100%" placeholder="类型" size="small" @change="getTypeWay()">
<el-option :key="0" label="全部" :value="0"> </el-option>
<el-option :key="1" label="跟班课" :value="1"> </el-option>
<el-option :key="2" label="试听课" :value="2"> </el-option>
<el-option :key="2" label="预约课" :value="3"> </el-option>
<div slot="prefix" class="full-height flex items-center" style="color: #000; padding-right: 10px">
类型:
</div>
</el-select>
</div>
<div class="col-2 yuyuezhuangtai" style="width: 10%" v-if="msg.ClassType==3">
<el-select v-model="msg.AppointState" style="width: 100%;" placeholder="预约状态" size="small"
@change="getTypeWay()">
<el-option :key="0" label="不限" :value="0"> </el-option>
<el-option :key="0" label="待确认" :value="1"> </el-option>
<el-option :key="1" label="已确认" :value="2"> </el-option>
<div slot="prefix" class="full-height flex items-center"
style="color: #000;margin-right:61px; white-space:nowrap;">
预约状态:
</div>
</el-select>
</div>
<div class="col-3" style="width: 30%">
<q-btn color="accent" size="sm" class="q-mr-md" style="margin-top: 2px" @click="exchangeType"
:label="typeName" />
<q-btn color="accent" size="sm" class="q-mr-md" label="下载计划" @click="downLoadPlan()" />
<q-btn color="negative" size="sm" label="调课申请" @click="openForm"></q-btn>
</div>
</div>
<cancelClassList></cancelClassList>
</div>
</template>
<script>
import {
getTeacherDropDownList,
queryClassRoomList,
} from "../../api/school/index";
import {
GetClassPlanStatistical,
GetClassPlanStatisticalPage,
} from "../../api/teacher/index";
import {
EduDownLoad
} from "../../api/common/common";
import cancelClassList from "./components/cancelClassList";
export default {
meta: {
title: "学员消课统计",
},
components: {
cancelClassList
},
data() {
return {
persistent: false,
TeacherList: [], //教师团队
ClassRoomList: [], //
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
dataList: {},
activeNames: [1],
msg: {
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
ClassType: 0,
AppointState: 0,
},
commonType: 1, //1日历模式 2列表模式
typeName: "列表模式",
tabMsg: {
PageIndex: 1,
PageSize: 12,
rowsPerPage: 12,
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
ClassType: 0,
},
tableData: [], //表格数据
PageCount: 0,
picker: {
disabledDate: (time) => {
// let endTime=this.msg.EndTime
// if(endTime){
// return Date.now() - 8.64e7>time.getTime()>=new Date(endTime).getTime()- 8.64e7
// }else{
// return time.getTime() < Date.now() - 8.64e7
// }
},
},
pickerEnd: {
disabledDate: (time) => {
let startTime = this.msg.StartTime;
if (startTime) {
return time.getTime() <= new Date(startTime).getTime() - 8.64e7;
} else {
return time.getTime() < Date.now() - 8.64e7;
}
},
},
loading: false,
};
},
created() {
if (this.$route.query && this.$route.query.ClassType) {
this.msg.ClassType = this.$route.query.ClassType;
}
let date = new Date();
let today =
date.getFullYear() +
"-" +
(date.getMonth() < 9 ?
"0" + (date.getMonth() + 1) :
date.getMonth() + 1) +
"-" +
(date.getDate() < 10 ? "0" + date.getDate() : date.getDate());
this.msg.StartTime = today;
this.tabMsg.StartTime = today;
this.getClassRoomList();
},
mounted() {
this.exchangeType()
this.GetTeacherList();
this.getPlanList();
},
methods: {
downLoadPlan() {
//导出
var newMsg = JSON.parse(JSON.stringify(this.msg));
EduDownLoad("/Class/DownLoadClassPlan", newMsg, "老师上课计划.xls");
},
refreshPage() {
this.getPlanList();
},
openForm() {
this.persistent = true;
},
closeSaveForm() {
this.persistent = false;
},
// 获取校区教室导航列表
getPlanList() {
GetClassPlanStatistical(this.msg).then((res) => {
if (res.Code == 1) {
this.dataList = res.Data;
}
});
},
//获取教师下拉
GetTeacherList() {
getTeacherDropDownList({}).then((res) => {
if (res.Code == 1) {
this.TeacherList = res.Data;
var obj = {
TeacherName: "请选择",
TId: 0,
};
this.TeacherList.unshift(obj);
}
});
},
//获取教室下拉
getClassRoomList() {
queryClassRoomList({}).then((res) => {
if (res.Code == 1) {
this.ClassRoomList = res.Data;
var obj = {
RoomName: "请选择",
RoomId: 0,
};
this.ClassRoomList.unshift(obj);
}
});
},
exchangeType() {
if (this.commonType == 1) {
this.commonType = 2;
this.typeName = "日历模式";
this.getTableList();
} else {
this.commonType = 1;
this.typeName = "列表模式";
this.getPlanList();
}
},
getTableList() {
this.tabMsg.StartTime = this.msg.StartTime;
this.tabMsg.EndTime = this.msg.EndTime;
this.tabMsg.ClassRoomId = this.msg.ClassRoomId;
this.tabMsg.ClassType = this.msg.ClassType;
this.loading = true;
GetClassPlanStatisticalPage(this.tabMsg).then((res) => {
this.loading = false;
if (res.Code == 1) {
this.tableData = res.Data.PageData;
this.PageCount = res.Data.PageCount;
}
});
},
getChange(val) {
this.tabMsg.PageIndex = val;
this.getTableList();
},
getTypeWay() {
if (this.commonType == 2) {
this.getTableList();
} else {
this.getPlanList();
}
},
},
};
</script>
<style lang="scss">
.xg .el-input--prefix .el-input__inner {
padding-left: 50px;
}
.yuyuezhuangtai .el-input--prefix .el-input__inner {
padding-left: 60px;
}
</style>
\ No newline at end of file
<template>
<div class="page-body">
<q-tabs v-model="tabCheck" narrow-indicator dense align="left" class="text-primary q-mb-sm">
<q-tab :ripple="false" :name="9" label="学员预约分配规则"></q-tab>
</q-tabs>
<stuAbroad v-if="tabCheck==9"></stuAbroad>
</div>
</template>
<script>
import stuAbroad from "./stuAbroad";
export default {
meta: {
title: "学员预约分配规则"
},
components: {
stuAbroad
},
data() {
return {
tabCheck: 9
};
}
};
</script>
\ No newline at end of file
<template>
<div class="page-cancelClassList-body">
<div class="fit row no-wrap items-start content-start">
<div class="cancelClassList-left col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3">
<div v-for="item in titleList" class="left-text">
{{item.name}}
</div>
<div v-for="item in numList" class="left-text">
{{item.name}}
</div>
</div>
<div class="cancelClassList-right col-xl-20 col-lg-20 col-md-20 col-sm-19 col-xs-19">
<div class="cancelClassList-right-box Xscroll fit row no-wrap"
:class="{}">
<div class="right-box" v-for="item in 25">
<div class="content-title courseName activeOne">名称</div>
<div class="content-title teacherName">老师名字</div>
<div class="content-title traineesName activeOne">学员名字</div>
<div class="right-content" v-for="item in 3">
<div class="content-single">语音1语音1语音1语音1</div>
<div class="content-multiple">
<div class="content-tetx">理解1语音1语音1语音1</div>
<div class="content-tetx">活动2</div>
</div>
<div class="content-show">
<div></div>
语音1语音1语音1语音1
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
props: {
setMsg: {
type: Object,
default: null,
},
tableData: {
type: Array,
default: null,
},
PageCount: {
type: Number,
default: null,
},
showCZ: {
//是否显示操作栏
Type: Boolean,
default: true,
},
loading:{
type:Boolean,
default:false,
}
},
meta: {
title: "学员消课统计",
},
components: {
},
data() {
return {
titleList:[
{name:'课程名称'},
{name:'课程老师'},
{name:'学员姓名'},
],
numList:[
{name:'1'},
{name:'2'},
{name:'3'}
]
};
},
created() {
},
mounted() {
},
methods: {
},
};
</script>
<style lang="scss" scoped>
.page-cancelClassList-body{
/* border: 1px solid #E5E5E5; */
margin-top: 20px;
}
.cancelClassList-left{
background: #E5E5E5;
}
.left-text{
width: 100%;
padding: 0 20px;
height: 40px;
line-height: 40px;
border-bottom: 1px solid #DDDEE0;
text-align: center;
font-size: 14px;
}
.left-text:first-child,.left-text:nth-child(2),
.left-text:nth-child(3),.left-text:nth-child(4){
font-weight: bold;
}
.left-text:last-child{
border-bottom: 0;
}
.cancelClassList-right{
overflow: hidden;
}
.courseName{
background: #F8CBAD;
}
.courseName.activeOne{
background: #FFD964;
}
.courseName.activeTwo{
background: #F4B183;
}
.teacherName{
background: #C4C4F5;
}
.traineesName{
background: #CEF5A5;
}
.traineesName.activeOne{
background: #F5AFAF;
}
.cancelClassList-right-box{
}
.Xscroll{
overflow-x: scroll;
}
.right-box{
display: flex;
flex-direction: column;
font-size: 13px;
}
.content-title:first-child{
border-top: 1px solid #DDDEE0;
}
.content-title{
width: 100%;
padding: 0 5px;
height: 40px;
line-height: 40px;
overflow: hidden;
text-align: center;
border-bottom: 1px solid #DDDEE0;
border-right: 1px solid #DDDEE0;
}
.right-content{
display: flex;
flex-direction: column;
width: 80px;
height: 40px;
border-bottom: 1px solid #DDDEE0;
border-right: 1px solid #DDDEE0;
position: relative;
cursor: pointer;
}
.right-content:last-child{
border-bottom: 0;
}
.content-single,.content-tetx{
flex: 1;
flex-shrink: 0;
line-height: 40px;
text-align: center;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
padding: 0 5px;
}
.right-content.activeOne{
background: #6FE053;
}
.right-content.activeTwo{
background: #FA716A;
color: white;
}
.content-tetx{
border-right: 1px solid #DDDEE0;
}
.content-tetx:last-child{
border: 0;
}
.content-multiple{
display: flex;
}
.content-show{
position: absolute;
top: -60px;
left: -50px;
background: #ffffff;
border-radius: 10px;
padding: 10px;
display: none;
background: #fff;
padding: 10px 19px;
box-shadow: 5px 5px 20px 5px #ccc;
}
.content-show div{
width: 0px;
height: 0px;
border: 8px solid transparent;
border-top-color: #ffffff;
position: absolute;
bottom: -15px;
right: 20px;
}
.right-content:hover .content-show{
/* display: block; */
}
</style>
\ No newline at end of file
This diff is collapsed.
<style>
.MainPlan .ClassPlanTable {
width: 100%;
color: #000;
}
.ClassPlanTable th,
.ClassPlanTable td {
border: 1px solid #d1d1d1;
height: 40px;
}
.teacher-Table td {
vertical-align: top;
padding: 5px;
width: 14%;
}
.MainPlan {
margin: 20px;
}
.MainPlan .plan_ClassDate {
height: 30px;
line-height: 30px;
font-size: 15px;
font-weight: bold;
}
.MainPlan .plantHead th {
border-bottom: 0;
}
.MainPlan .planTabDiv {
max-height: calc(100vh - 235px);
height: calc(100vh - 235px);
overflow-y: overlay;
/* margin-right: -3px; */
}
.planTabDiv::-webkit-scrollbar {
width: 3px;
height: 3px;
background-color: #F5F5F5;
}
/*!*定义滚动条轨道 内阴影+圆角*!*/
.planTabDiv::-webkit-scrollbar-track {
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
border-radius: 10px;
background-color: #F5F5F5;
}
/*!*定义滑块 内阴影+圆角*!*/
.planTabDiv::-webkit-scrollbar-thumb {
border-radius: 10px;
-webkit-box-shadow: -webkit-gradient(linear, 0 0, 0 100%, color-stop(.5, rgba(255, 255, 255, .2)), color-stop(.5, transparent), to(transparent));
background-color: #0ae;
}
.MainPlan .el-collapse-item__header {
font-size: 12px;
line-height: normal;
color: #000;
}
.MainPlan .plan_Inner {
font-size: 12px;
color: #000;
display: flex;
margin-top: 5px;
}
.MainPlan .plan_LeftTitle {
width: 60px;
text-align: right;
flex-shrink: 0
}
.MainPlan .plan_RightInner {
width: 100%;
}
.MainPlan .commonTimeStr {
display: inline-block;
color: #fff;
padding: 1px 3px;
border-radius: 5px;
}
.MainPlan .greenTime {
background-color: green;
}
.MainPlan .blueTime {
background-color: blue;
}
.MainPlan .orangeTime {
background-color: orange;
}
.MainPlan .plan_Tdiv {
text-overflow: ellipsis;
overflow: hidden;
word-break: break-all;
}
</style>
<template>
<div>
<table class="ClassPlanTable plantHead" style="border-collapse:collapse;width:100%;margin:15px 0 0 0;">
<thead>
<tr>
<th colspan="16">甲鹤校区教室使用情况</th>
</tr>
<tr>
<th>周一</th>
<th>周二</th>
<th>周三</th>
<th>周四</th>
<th>周五</th>
<th>周六</th>
<th>周日</th>
</tr>
</thead>
</table>
<div class="planTabDiv" ref="planTabDiv">
<table class="ClassPlanTable teacher-Table" ref="PlanTable" style="border-collapse:collapse;margin-top:0;">
<tbody>
<tr v-for="(item,index) in dataList.fridayList" :key="index">
<td>
<div class="plan_ClassDate">{{dataList.mondayList[index].ClassDate}}</div>
<mateitem v-if="dataList.mondayList&&dataList.mondayList[index].SubList"
:dayData="dataList.mondayList[index]"></mateitem>
</td>
<td>
<div class="plan_ClassDate">{{dataList.tuesdayList[index].ClassDate}}</div>
<mateitem v-if="dataList.tuesdayList&&dataList.tuesdayList[index].SubList"
:dayData="dataList.tuesdayList[index]"></mateitem>
</td>
<td>
<div class="plan_ClassDate">{{dataList.wednesdayList[index].ClassDate}}</div>
<mateitem v-if="dataList.wednesdayList&&dataList.wednesdayList[index].SubList"
:dayData="dataList.wednesdayList[index]"></mateitem>
</td>
<td>
<div class="plan_ClassDate">{{dataList.thursdayList[index].ClassDate}}</div>
<mateitem v-if="dataList.thursdayList&&dataList.thursdayList[index].SubList"
:dayData="dataList.thursdayList[index]"></mateitem>
</td>
<td>
<div class="plan_ClassDate">{{dataList.fridayList[index].ClassDate}}</div>
<mateitem v-if="dataList.fridayList&&dataList.fridayList[index].SubList"
:dayData="dataList.fridayList[index]"></mateitem>
</td>
<td>
<div class="plan_ClassDate">{{dataList.saturdayList[index].ClassDate}}</div>
<mateitem v-if="dataList.saturdayList&&dataList.saturdayList[index].SubList"
:dayData="dataList.saturdayList[index]"></mateitem>
</td>
<td>
<div class="plan_ClassDate">{{dataList.sundayList[index].ClassDate}}</div>
<mateitem v-if="dataList.sundayList&&dataList.sundayList[index].SubList"
:dayData="dataList.sundayList[index]"></mateitem>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</template>
<script>
import mateitem from './mateitem';
export default {
props: {
dataList: {
type: Object,
default: null
},
},
components: {
mateitem,
},
data() {
return {
msg: {
StartTime: "",
EndTime: '',
TeacherId: 0,
ClassRoomId: 0
},
};
},
created() {
},
mounted() {},
methods: {
//获取进度条
getProgress(num, total) {
if (num == 0 || total == 0) {
return 0;
}
return (Math.round(num / total * 100) / 100.00);
}
}
};
</script>
\ No newline at end of file
<style>
</style>
<template>
<div>
<el-collapse v-if="dayData&&dayData.SubList&&dayData.SubList.length>0">
<el-collapse-item v-for="(subItem,subIndex) in dayData.SubList" :key="subIndex" :name="subIndex">
<template slot="title">
<div class="plan_Tdiv">
<span v-if="subItem.TimeStr==='早上'" class="commonTimeStr greenTime">{{subItem.TimeStr}}</span>
<span v-if="subItem.TimeStr==='下午'" class="commonTimeStr blueTime">{{subItem.TimeStr}}</span>
<span v-if="subItem.TimeStr==='晚上'" class="commonTimeStr orangeTime">{{subItem.TimeStr}}</span>
<q-badge rounded color="orange" label="试听课" v-if="subItem.ClassType==2"
style="margin-left:5px;font-size:10px" />
<q-badge rounded color="cyan-7" label="预约课" v-if="subItem.ClassType==3"
style="margin-left:5px;font-size:10px" />
<q-badge rounded color="orange" label="跟班" v-if="subItem.ClassType == 2&&subItem.ReserveType==1"
style="margin-left:5px;font-size:10px" />
<span style="color:red;margin:0 5px;">{{subItem.TeacherName}}</span>
<span>[{{subItem.RoomName}}]</span>
<template v-if="
subItem.ClassType == 3 &&
subItem.AppointState == 1 &&
isShowTag(subItem.GuestList, subItem.ScrollMinNum)
">
<q-badge color="red" rounded style="margin-left:5px;">
</q-badge>
</template>
</div>
</template>
<div @click="goUrl(subItem)" style="cursor:pointer;">
<div class="plan_Inner">
<div class="plan_LeftTitle">上课时间:</div>
<div class="plan_RightInner">{{subItem.StartTime}}-{{subItem.EndTime}}</div>
</div>
<div class="plan_Inner" v-if="subItem.ClassName">
<div class="plan_LeftTitle">班级:</div>
<div class="plan_RightInner">{{subItem.ClassName}}</div>
</div>
<div class="plan_Inner">
<div class="plan_LeftTitle">课程名称:</div>
<div class="plan_RightInner">{{subItem.CourseName}}</div>
</div>
<div class="plan_Inner" v-if="subItem.GuestList&&subItem.GuestList.length>0">
<div class="plan_LeftTitle">学生名称:</div>
<div class="plan_RightInner">
<span style="margin-right:10px;" v-for="tItem in subItem.GuestList">{{tItem.GuestName}}
<span v-if="tItem.AppointType == 2">(补)</span>
<span v-if="tItem.AppointType == 3">(重)</span>
</span>
</div>
</div>
<div class="plan_Inner" style="align-items:center;" v-if="subItem.ClassType == 1&&subItem.ClassType ==3">
<div class="plan_LeftTitle">课程进度:</div>
<div class="plan_RightInner">
<span v-if="subItem.ClassType == 1">{{ subItem.Ranks }}/{{ subItem.TotalPlanNum }}</span>
<span v-if="subItem.ClassType == 3&&subItem.CourseGradeIdName" class="q-mr-sm">{{subItem.CourseGradeIdName}}</span>
<span v-if="subItem.ClassType == 3">第{{ subItem.Ranks||0 }}次课</span>
</div>
</div>
<template v-if="subItem.ClassType == 3">
<div class="plan_Inner">
<div class="plan_LeftTitle">课程状态:</div>
<div class="plan_RightInner" style="color: rgb(239, 83, 80);" v-if="subItem.AppointState == 1">
待确认
</div>
<div class="plan_RightInner" style="color: rgb(33, 186, 69);" v-if="subItem.AppointState == 2">
已确认
</div>
</div>
<div class="plan_Inner" v-if="subItem.ScrollMinNum">
<div class="plan_LeftTitle">最小成班:</div>
<div class="plan_RightInner">
<span style="color: rgb(33, 186, 69);">{{
subItem.ScrollMinNum
}}</span>
</div>
</div>
</template>
</div>
</el-collapse-item>
</el-collapse>
</div>
</template>
<script>
export default {
props: {
dayData: {
type: Object,
default: null
}
},
components: {
},
data() {
return {
}
},
created() {},
mounted() {
},
methods: {
goUrl(item) {
if (item.ClassType === 1) {
this.OpenNewUrl("../../classroom/courseInfo", {
id: item.Id
});
}
},
isShowTag(arr, min) {
let n = 0;
arr.map(e => {
if (e.AppointType !== 3) {
n += 1;
}
});
if (n < min) {
return true;
} else {
return false;
}
}
}
}
</script>
<template>
<div style="padding: 20px 0">
<div class="page-content">
<!-- separator="none" -->
<q-table :pagination="setMsg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-column-table sticky-right-column-table"
:data="tableData" :columns="showCZ ? columns : columns2" row-key="name">
<template v-slot:body-cell-ClassDate="props">
<q-td auto-width :props="props">
{{ props.row.ClassDate }}
</q-td>
</template>
<template v-slot:body-cell-StartTime="props">
<q-td :props="props">
<div v-for="item in 5">
{{ props.row.StartTime }}-{{ props.row.EndTime }}
</div>
</q-td>
</template>
<template v-slot:body-cell-ClassName="props">
<q-td :props="props">
{{ props.row.ClassName }}
</q-td>
</template>
<template v-slot:bottom>
<q-pagination class="full-width justify-end" v-model="PageIndex" color="primary" :max="PageCount"
:input="true" @input="changePage" />
</template>
</q-table>
</div>
</div>
</template>
<script>
export default {
props: {
setMsg: {
type: Object,
default: null,
},
tableData: {
type: Array,
default: null,
},
PageCount: {
type: Number,
default: null,
},
showCZ: {
//是否显示操作栏
Type: Boolean,
default: true,
},
loading:{
type:Boolean,
default:false,
}
},
meta: {
title: "我的课表",
},
components: {},
data() {
return {
columns: [{
name: "ClassDate",
label: "日期",
field: "ClassDate",
align: "left",
},
{
name: "StartTime",
label: "上课时间",
field: "StartTime",
align: "left",
},
{
name: "ClassName",
label: "班级",
field: "ClassName",
align: "left",
},
{
name: "optioned",
label: "操作",
field: "Id",
},
],
columns2: [{
name: "ClassDate",
label: "日期",
field: "ClassDate",
align: "left",
},
{
name: "StartTime",
label: "时段",
field: "StartTime",
// field: row => row.StartTime,
align: "left",
},
{
name: "ClassName",
label: "人数",
field: "ClassName",
align: "left",
}
],
tabMsg: {
PageIndex: 1,
PageSize: 15,
rowsPerPage: 15,
StartTime: "",
EndTime: "",
TeacherId: 0,
ClassRoomId: 0,
ClassType: 0,
},
PageIndex: 1,
};
},
created() {},
mounted() {},
methods: {
//翻页
changePage(val) {
this.PageIndex = val;
this.$emit("getChange", this.PageIndex);
},
//跳转到课程回顾
goCourseRecord(item) {
this.OpenNewUrl("../../classroom/courseInfo", {
id: item.Id,
});
},
//跳转到课程反馈
goFeedBack(item) {
this.OpenNewUrl("/teacher/feedBackList", {
id: item.Id,
});
},
},
};
</script>
<style lang="sass">
@import url('~assets/css/table.sass')
</style>
\ No newline at end of file
<style>
.stuCloseBtn {
position: absolute;
right: -8px;
top: -9px;
width: 20px;
height: 20px;
border: 1px solid red;
background-color: red;
color: #fff;
line-height: 18px;
text-align: center;
border-radius: 50%;
cursor:pointer;
}
</style>
<template>
<div>
<q-card flat class="q-pa-lg q-my-lg" v-loading="loading">
<div class="text-h6 text-weight-bold">分配给以下部门/成员</div>
<div style="display:flex;justify-content:end;width:600px;margin-bottom:10px;">
<q-btn round color="primary" icon="iconfont icon-img_haha" @click="addEmployee()" />
</div>
<div style="display:flex;margin-bottom:10px;position:relative;width:620px;" v-for="(item,index) in List" :key="index">
<q-select class="col-6 q-pb" v-model="item.Content" @input="getName(item.Content,index)"
style="width:300px;margin-right:10px;" clearable filled stack-label use-input option-value="Id"
option-label="EmployeeName" ref="ManagerId" :options="EmployeeList" label="留学顾问" :dense="false" emit-value
map-options @filter="filterFn">
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
</q-select>
<q-select filled v-model="item.CodeList" multiple option-value="Id" option-label="Name" :options="NeedData"
label="客户需求" style="width: 300px" emit-value map-options />
<div class="stuCloseBtn">
<i @click="delStepStu(index)" class="iconfont icon-guanbi"></i>
</div>
</div>
<q-btn class="q-mt-xl q-px-lg" unelevated color="primary" :loading="saving" @click="saveHandler">立即保存</q-btn>
</q-card>
<choiceapproval v-if="outerVisible" @close="getclose()" :singleCheck="true" @success="getsuccess2"
:byval="chosenUser" cptype="0">
</choiceapproval>
</div>
</template>
<script>
import choiceapproval from "../../components/enterprise/choiceapproval";
import {
getDictValue
} from "../../api/administration/administration";
import {
saveDict
} from "../../api/system/notiveSysSet";
import {
GetNeedsList
} from "../../api/school/index";
import {
queryEmployee
} from "../../api/users/user"; //获取员工
export default {
components: {
choiceapproval
},
data() {
return {
chosenUser: [],
outerVisible: false,
saving: false,
loading: false,
dictObjEmp: {
ID: 0,
Code: "",
Content: "",
DictKey: "PUSH_STU_STUDYABROAD",
Mask: "",
Name: "学员预约分配规则",
},
multiCheck: [],
NeedData: [], //多选
EmployeeList: [], // 员工
AllemployeeList: [],
List: [{
CodeList: [],
Code: '',
Content: '',
Mask: ""
}]
};
},
created() {
this.getGetNeedsList();
this.getEmployee();
this.init();
},
methods: {
//点击添加
addEmployee() {
let obj = {
CodeList: [],
Code: '',
Content: '',
Mask: ""
}
this.List.push(obj);
},
delStepStu(index){
this.List.splice(index,1);
},
//选择Name
getName(Id, index) {
this.EmployeeList.forEach(x => {
if (x.Id == Id) {
this.List[index].Mask = x.EmployeeName;
}
})
},
//获取业务员
getEmployee() {
var qMsg = {
EmployeeName: ''
}
queryEmployee(qMsg).then(res => {
if (res.Code == 1) {
this.EmployeeList = res.Data;
this.AllemployeeList = res.Data;
}
})
},
//筛选员工
filterFn(val, update) {
update(() => {
if (val === '') {
this.EmployeeList = JSON.parse(JSON.stringify(this.AllemployeeList))
} else {
const needle = val.toLowerCase();
this.EmployeeList = this.AllemployeeList.filter(v => v.EmployeeName.toLowerCase().indexOf(needle) > -1);
}
})
},
//获取客户需求
getGetNeedsList() {
GetNeedsList().then(res => {
if (res.Code == 1) {
this.NeedData = res.Data;
}
});
},
getclose() {
// 企业关闭
this.ismember = false;
this.outerVisible = false;
},
getsuccess2(list, type) {
this.chosenUser = list;
this.outerVisible = false;
},
init() {
this.loading = true;
getDictValue({
Key: "PUSH_STU_STUDYABROAD"
}).then(res => {
this.loading = false;
if (res.Code == 1) {
var tempObj = res.Data;
if (tempObj) {
this.dictObjEmp.ID = tempObj.ID;
this.dictObjEmp.Content = tempObj.Content;
if (tempObj.Content) {
this.List = JSON.parse(tempObj.Content);
}
}
}
});
},
saveHandler() {
if(this.List.length==0){
this.$q.notify({
type: 'negative',
position: "top",
message: `请添加数据`
});
return
}
if(this.List.length>0){
for(let i=0;i<this.List.length;i++){
if(this.List[i].Content==''||this.List[i].Content==null){
this.$q.notify({
type: 'negative',
position: "top",
message: `请选择第${i+1}条留学顾问`
});
return
}
if(this.List[i].CodeList.length==0){
this.$q.notify({
type: 'negative',
position: "top",
message: `请选择第${i+1}条客户需求`
});
return
}
}
this.List.forEach(x => {
x.Code = x.CodeList.toString();
})
}
this.dictObjEmp.Content = JSON.stringify(this.List);
this.saving = true;
saveDict(this.dictObjEmp).then(r => {
this.saving = false;
if (r.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "数据保存成功!",
position: "top"
});
this.init();
} else {
this.saving = false;
}
});
}
}
};
</script>
<style></style>
\ No newline at end of file
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