Commit ca8e1b74 authored by 黄奎's avatar 黄奎

1111

parent c2c949ad
......@@ -199,6 +199,39 @@ export function queryPlanAppointmentStatic(data) {
});
}
/**
* 新增修改学员预约
*/
export function savePlanAppointment(data) {
return request({
url: '/PlanAppoiment/SetPlanAppointment',
method: 'post',
data
});
}
/**
* 获取预约时间段
*/
export function queryGetTimeList(data) {
return request({
url: '/PlanAppoiment/GetTimeList',
method: 'post',
data
});
}
/**
* 取消学员预约
*/
export function deletePlanAppointment(data) {
return request({
url: '/PlanAppoiment/RemovePlanAppointment',
method: 'post',
data
});
}
/**
* 获取预约详情列表
*/
......
<template>
<div>
<q-dialog v-model="show" persistent transition-show="scale" transition-hide="scale" @input="changeDig">
<q-card style="width: 800px;max-width:900px;">
<q-card-section class="row items-center q-pb-none">
<div class="text-h6">{{ editType == 1 ? "新增约课" : "详情" }}</div>
<q-space />
<q-btn icon="close" flat round dense @click="changeDig(false)" />
</q-card-section>
<q-card-section class="q-pt-none scroll" style="max-height: 70vh">
<div class="row col q-mr-lg q-col-gutter-md">
<q-field filled label="日期" stack-label class="col-12">
<template v-slot:control>
<div>{{ dateObj.date }}</div>
</template>
</q-field>
<!-- 详情显示内容 start-->
<div class="col-12" v-if="editType == 2">
<Detail :dateObj="dateObj" :saveObj="saveObj" :auth="auth" :CourseChapterName="CourseChapterName" @success="detailSuccessHandle"
@close="detailCloseHandle" />
</div>
<!-- 详情显示内容 end -->
<q-select filled stack-label use-input option-value="CourseId" option-label="CourseName"
v-model="teaClassMsg.CourseId" ref="CourseId" :options="CourseList" label="课程" :dense="false"
class="col-12" emit-value map-options @filter="filterCourse"
@input="getCanTeacherTimeList(), getChapterTree(), changeCourse()" v-if="editType == 1">
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
</q-select>
<select-tree v-show="teaClassMsg.CourseId > 0 && editType == 1" :treeData="chapterList"
v-model="returnString" nodeKey="ChapterId" labelKey="ChapterName" childrenKey="ChildList"
tipText="章节" @getChild="getChapter" class="col-12" ref="selectTree"></select-tree>
<div class="row col-12 q-col-gutter-md">
<q-select v-show="teaClassMsg.CourseId > 0 && editType == 1" filled v-model="teaClassMsg.TeacherId"
option-value="TId" option-label="TeacherName" :options="teacherList" emit-value map-options label="老师"
class="col-6" @input="getCanTeacherTimeList" />
<q-select v-show="
teaClassMsg.CourseId > 0 &&
teaClassMsg.TeacherId &&
teacherTimeList.length > 0 &&
editType == 1
" filled v-model="saveMsg.RoomId" option-value="RoomId" option-label="RoomName"
:options="ClassRoomList" emit-value map-options label="教室" :disable="addStuList.length > 0"
class="col-6">
<template v-slot:selected-item="scope">
<div class="row col-12 flex justify-between"> <span>{{scope.opt.RoomName}}</span><span>{{ scope.opt.SchoolName}}</span></div>
</template>
<template v-slot:option="scope">
<q-item v-bind="scope.itemProps" v-on="scope.itemEvents">
<q-item-section>
<q-item-label class="row flex justify-between"> <span>{{scope.opt.RoomName}}</span><span>{{ scope.opt.SchoolName}}</span></q-item-label>
</q-item-section>
</q-item>
</template>
</q-select>
</div>
<q-field filled label-slot stack-label class="col-12" v-if="teaClassMsg.TeacherId > 0">
<template #label>
<div class="row flex">
上课时段
<span style="color:#f5576c;font-size:13px;margin-left:5px;font-weight:500">(按顺序选择)</span>
<div style="color:#333;font-size:13px;margin-left:10px;font-weight:500">
需选课时:{{ checkChapter.StudyMinutes }}分钟
</div>
</div>
</template>
<template v-slot:control>
<div v-if="teacherTimeList.length > 0">
<div v-for="(item, index) in teacherTimeList" :key="index">
<div v-if="
item.CourseTimeList && item.CourseTimeList.length > 0
">
<div v-for="(_item, _index) in item.CourseTimeList" :key="_index" class="timeItem">
<q-checkbox v-model="courseCheckList" :val="_item">
{{ _item.StartTime }}-{{ _item.EndTime }}
</q-checkbox>
</div>
</div>
<div v-else>
暂无可约课程
</div>
</div>
</div>
<div v-else>
暂无可约课程
</div>
</template>
</q-field>
<div class="row col-12" v-show="
(editType == 1 && checkChapter.ChapterId > 0) ||
(saveObj.ClassType == 3 && saveObj.AppointState == 1)
">
<div class="row col-6">
<q-input filled stack-label v-model="stuMsg_v2.StuName" label="学员姓名" @keyup.enter.native="getStu_V2"
class="col-9" hint="提示:需输入学员姓名查询学员列表" />
<div class="col-3 q-pt-md q-pl-md">
<q-btn size="sm" color="accent" label="查询" @click="getStu_V2" />
</div>
</div>
<div class="row col-6">
<div class="col-9">
<q-select filled stack-label use-input option-value="StuId" option-label="StuName" v-model="stuInfo"
ref="CourseId" :options="stuList" label="学员列表" :dense="false" class="col-6" @filter="filterStu">
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
未找到相关数据
</q-item-section>
</q-item>
</template>
<template v-slot:option="scope">
<q-item v-bind="scope.itemProps" v-on="scope.itemEvents">
<q-item-section>
<div class="flex">
<span>{{ scope.opt.StuName }}</span>
<span v-if="scope.opt.State === 3">(重)</span>
<span class="q-ml-sm">{{
scope.opt.CourseName
}}</span>
</div>
</q-item-section>
</q-item>
</template>
</q-select>
</div>
<div class="col-3 q-pt-md q-pl-md">
<q-btn size="sm" color="accent" label="添加" @click="subscribeCourse" :loading="addLoading"
:disable="!stuInfo.StuId || stuInfo.StuId <= 0" />
</div>
</div>
</div>
<q-field filled label="已约学员" stack-label disable class="col-12"
v-if="editType == 1 && addStuList.length > 0">
<template v-slot:control>
<div v-for="(item, index) in addStuList" :key="index" class="q-mr-md">
{{ item }}
</div>
</template>
</q-field>
</div>
</q-card-section>
<q-separator />
<q-card-actions align="right" class="bg-white">
<q-btn label="取消" flat color="grey-10" style="font-weight:400 !important" @click="changeDig(false)" />
</q-card-actions>
</q-card>
</q-dialog>
</div>
</template>
<script>
import {
GetCanTeacherClassTimeList,
getCanAppointmentStuList_V2,
setAdminScrollAppointment_V2,
getScrollCourseChapterName,
} from "../../../api/studyabroad/subscribe.js";
import {
queryCourseDropdownList,
queryChapterTree
} from "../../../api/course/index";
import {
queryClassRoomList
} from "../../../api/school/index";
import selectTree from "./select-tree";
import Detail from "./detail.vue";
export default {
components: {
selectTree,
Detail
},
model: {
prop: "show",
event: "changeshow"
},
props: {
dateObj: {
type: Object,
default: null
},
saveObj: {
type: Object,
default: null
},
show: {
type: Boolean,
default: false
},
editType: {
type: Number,
default: 1 //1:新增,2详情
},
teacherList: {
type: Array,
default: () => []
},
auth: {
type: Object,
default: () => {
return {
IsEdit: false
};
}
}
},
watch: {
show(val) {
this.addLoading = false;
this.addStuList = [];
if (val) {
this.stuInfo = "";
this.teaClassMsg.CourseId = 0;
this.teaClassMsg.TeacherId = 0;
this.chapterList = [];
this.teacherTimeList = [];
this.courseCheckList = [];
this.stuList = [];
this.allStuList = [];
this.stuMsg_v2.StuName = "";
this.checkChapter = {};
if(this.editType==2&&this.saveObj.ClassType==3){
this.getScrollCourseChapterName()
}
}
}
},
data() {
return {
CourseList: [], //关联课程下拉数据
AllCourseList: [], //所有课程列表
teacherTimeList: [],
teaClassMsg: {
Date: "",
TeacherId: 0,
CourseId: 0
},
stuList: [],
allStuList: [],
stuMsg_v2: {
StuName: "",
NextCourseGradeNo: 0,
CourseGradeId: 0
},
detailObj: {},
detailMsg: {
StuId: 0,
GuestId: 0
},
saveMsg: {
Date: "",
TeacherId: 0,
ShiftSort: "",
StuId: 0,
GuestId: 0,
CourseId: 0,
CourseGradeId: 0,
CourseGradeNo: 0,
RoomId: 0,
Consume_CourseGradeNo:0,//消耗目标课程章节编号
},
stuInfo: "",
checkStuList: [],
courseCheckList: [],
addLoading: false,
chapterList: [], //章节列表,
checkChapter: {}, //选择的章节
returnString: [], //章节默认值
addStuList: [], //新增时展示用
ClassRoomList: [], //教室下拉
CourseChapterName:"",
};
},
mounted() {
this.getCourseList();
this.getClassRoomList();
},
methods: {
//获取教室下拉
getClassRoomList() {
queryClassRoomList({}).then(res => {
if (res.Code == 1) {
this.ClassRoomList = res.Data;
}
});
},
//开关弹窗
changeDig(val) {
this.$emit("changeshow", val);
if (!val) {
this.stuList = [];
this.allStuList = [];
}
},
//获取课程
getCourseList() {
queryCourseDropdownList({
IsQPrice: 1,
IsQuerySalePlat: 0,
IsScrollClass: 1
}).then(res => {
if (res.Code == 1) {
this.CourseList = res.Data;
var obj = {
CourseName: "请选择",
CourseId: 0
};
this.CourseList.unshift(obj);
this.AllCourseList = res.Data;
}
});
},
changeCourse() {
this.teaClassMsg.TeacherId = 0;
this.checkChapter = {};
this.checkStuList = [];
this.stuInfo = "";
this.$refs.selectTree.clearData();
},
//筛选课程
filterCourse(val, update) {
update(() => {
if (val === "") {
this.CourseList = JSON.parse(JSON.stringify(this.AllCourseList));
} else {
const needle = val.toLowerCase();
this.CourseList = this.AllCourseList.filter(
v => v.CourseName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取老师的空闲上课时段
getCanTeacherTimeList() {
this.teaClassMsg.Date = this.dateObj.date;
this.courseCheckList = [];
this.stuInfo = "";
if (this.teaClassMsg.TeacherId == 0) return;
GetCanTeacherClassTimeList(this.teaClassMsg).then(res => {
this.teacherTimeList = res.Data;
if (res.Data.length > 0) {
this.saveMsg.RoomId = res.Data[0].RoomId;
} else {
this.saveMsg.RoomId = 0;
}
});
},
//筛选学生
filterStu(val, update) {
update(() => {
if (val === "") {
this.stuList = JSON.parse(JSON.stringify(this.allStuList));
} else {
const needle = val.toLowerCase();
this.stuList = this.allStuList.filter(
v => v.StuName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取学生列表
getStu_V2() {
// if (!this.stuMsg_v2.StuName) {
// this.$q.notify({
// position: "top",
// message: "请输入学生姓名",
// timeout: 2500
// });
// return;
// }
if (this.editType == 1) {
this.stuMsg_v2.NextCourseGradeNo = this.checkChapter.ChapterGradeNo;
this.stuMsg_v2.CourseGradeId = this.checkChapter.CourseRate;
}
if (this.editType == 2) {
this.stuMsg_v2.NextCourseGradeNo = this.saveObj.Ranks;
this.stuMsg_v2.CourseGradeId = this.saveObj.CourseGradeId;
}
getCanAppointmentStuList_V2(this.stuMsg_v2).then(res => {
this.stuList = JSON.parse(JSON.stringify(res.Data));
this.allStuList = JSON.parse(JSON.stringify(res.Data));
});
},
//获取章节
getChapterTree() {
if (this.teaClassMsg.CourseId == 0) return;
const msg = {
CourseId: this.teaClassMsg.CourseId
};
queryChapterTree(msg).then(res => {
this.chapterList = res.Data;
this.chapterList.forEach(e => {
this.mapChapter(e.ChildList, "ChildList");
});
});
},
//禁用第一层后的子级
mapChapter(arr = [], key) {
arr.forEach(e => {
e.disabled = true;
if (e[key] && e[key].length > 0) {
this.mapChapter(e[key]);
}
});
},
//章节选择
getChapter(data) {
this.checkStuList = [];
this.stuInfo = "";
this.chapterList.map(e => {
if (e.ChapterId == data) {
this.checkChapter = e;
return;
}
});
this.teaClassMsg.TeacherId = 0;
this.teacherTimeList = [];
},
subscribeCourse() {
if (this.stuInfo.AppointDate) {
if (
new Date(this.dateObj.date).getTime() <
new Date(this.stuInfo.AppointDate).getTime()
) {
this.$q.notify({
message: `${this.stuInfo.StuName},不能预约${this.stuInfo.AppointDate}之前的日期`,
position: "top",
type: "negative"
});
return;
}
}
if (this.editType == 1) {
if (this.courseCheckList.length === 0) {
this.$q.notify({
message: "请选择上课时段",
position: "top",
type: "negative"
});
return;
}
const totalTime = this.courseCheckList.reduce((pre, cur) => {
return (pre += cur.Minutes);
}, 0);
if (this.checkChapter.StudyMinutes !== totalTime) {
this.$q.notify({
message: "课时不匹配,请重新上课时段",
position: "top",
type: "negative"
});
return;
}
let newCourseCheckList = this.courseCheckList.sort((a, b) => {
return a.Sort - b.Sort;
});
for (let i = 0; i < newCourseCheckList.length; i++) {
if (i > 0) {
const cur = newCourseCheckList[i].Sort;
const pre = newCourseCheckList[i - 1].Sort;
if (cur - pre > 1) {
this.$q.notify({
message: "请按顺序选择上课时段",
position: "top",
type: "negative"
});
return;
}
}
}
this.saveMsg.Date = this.dateObj.date;
this.saveMsg.StuId = this.stuInfo.StuId;
this.saveMsg.StuName = this.stuInfo.StuName;
this.saveMsg.GuestId = this.stuInfo.GuestId;
this.saveMsg.CourseId = this.teaClassMsg.CourseId;
this.saveMsg.TeacherId = this.teaClassMsg.TeacherId;
this.saveMsg.CourseGradeNo = this.checkChapter.ChapterGradeNo;
this.saveMsg.CourseGradeId = this.checkChapter.CourseRate;
this.saveMsg.ShiftSort = newCourseCheckList.map(e => e.Sort).toString();
} else if (this.editType == 2) {
this.saveMsg.Date = this.dateObj.date;
this.saveMsg.StuId = this.stuInfo.StuId;
this.saveMsg.StuName = this.stuInfo.StuName;
this.saveMsg.GuestId = this.stuInfo.GuestId;
this.saveMsg.CourseId = 0;
this.saveMsg.TeacherId = this.saveObj.Tid;
this.saveMsg.CourseGradeNo = this.saveObj.Ranks;
this.saveMsg.CourseGradeId = this.saveObj.CourseGradeId;
this.saveMsg.ShiftSort = this.saveObj.ShiftSort;
}
this.addLoading = true;
setAdminScrollAppointment_V2(this.saveMsg)
.then(res => {
this.addLoading = false;
if (res.Code == 1) {
this.$q.notify({
message: "操作成功",
position: "top"
});
if (this.editType == 1) {
this.addStuList.push(this.stuInfo.StuName);
}
if (this.editType == 2) {
this.saveObj.GuestList.push({
GuestName: this.stuInfo.StuName,
AppointmentId: res.Data
});
}
this.stuInfo = "";
this.stuMsg_v2.StuName = "";
this.$emit("success");
}
})
.catch(() => {
this.addLoading = false;
});
},
detailSuccessHandle(val) {
// this.getStu_V2();
this.stuMsg_v2.StuName = "";
this.stuList = [];
this.allStuList = [];
this.$emit("success");
},
detailCloseHandle() {
this.changeDig(false);
this.$emit("success");
},
getScrollCourseChapterName(){
const msg={
CourseId:this.saveObj.CourseId,
CourseGradeId:this.saveObj.CourseGradeId,
CourseGradeNo:this.saveObj.Ranks,
}
getScrollCourseChapterName(msg).then(res=>{
this.CourseChapterName=res.Data
})
}
}
};
</script>
<style>
.q-calendar-daily__day-interval:hover {
background: rgba(0, 0, 255, 0.1);
}
.q-calendar-weekly__workweek:hover {
background: rgba(0, 0, 255, 0.1);
}
.q-calendar-weekly__day:hover {
background: rgba(0, 0, 255, 0.1);
}
.q-calendar-weekly__head-weekday:hover {
background: rgba(0, 0, 255, 0.1);
}
.q-calendar-scheduler__day:hover {
background: rgba(0, 0, 255, 0.1);
}
.q-calendar-resource__resource-interval:hover {
background: rgba(0, 0, 255, 0.1);
}
.q-calendar-daily__day:hover {
background: rgba(0, 0, 255, 0.1);
}
</style>
<style>
.upload-assiatant-box .q-uploader__list {
display: none;
}
.upload-assiatant-box .q-uploader {
width: auto;
}
.timeItem {
margin: 10px 0;
}
</style>
......@@ -13,10 +13,13 @@
</div>
<div class="col-2">
<q-btn color="accent" size="sm" class="q-mr-md" label="下载" @click="DownLoadPlanAppointmentStatic()" />
<q-btn color="accent" size="sm" class="q-mr-md" label="新增" @click="ShowAddForm" />
</div>
</div>
<stuAppointmentList :tableData="tableData" @chang="getPlanAppointmentList" @refresh="refreshPage"
:loading="loading"></stuAppointmentList>
<appointmentForm v-if="isShowAddForm" :setingObj="setingObj" @refresh="refreshPage"></appointmentForm>
</div>
</template>
......@@ -29,17 +32,21 @@
EduDownLoad
} from "../../api/common/common";
import stuAppointmentList from "./components/stuAppointmentList";
import appointmentForm from "./components/appointmentForm";
export default {
meta: {
title: "学员预约统计",
},
components: {
stuAppointmentList,
appointmentForm,
},
data() {
return {
persistent: false,
loading: false,
//是否显示新增弹窗
isShowAddForm:false,
msg: {
StartTime: "",
EndTime: "",
......@@ -58,6 +65,7 @@
}
},
},
setingObj: {},
};
},
created() {
......@@ -84,6 +92,8 @@
});
},
refreshPage() {
this.isShowAddForm=false;
this.setingObj={};
this.getPlanAppointmentList();
},
//获取学员预约统计
......@@ -94,6 +104,12 @@
}
});
},
//线索新增弹窗
ShowAddForm()
{
this.isShowAddForm=true;
this.setingObj={};
}
},
};
</script>
......
<style>
</style>
<template>
<q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" transition-hide="scale">
<q-card style="width: 400px; max-width: 400px" class="stop">
<q-card-section>
<div class="text-h6">新增/修改学员预约</div>
</q-card-section>
<q-card-section class="q-pt-none" style="height: 30vh">
<q-input filled v-model="postMsg.Date" 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">
<q-date v-model="postMsg.Date" @input="() => $refs.qDateProxy1.hide()" />
</q-popup-proxy>
</q-icon>
</template>
</q-input>
<q-select filled stack-label option-value="Id" option-label="Name" v-model="postMsg.chooseTime" ref="Sort"
:options="TimeList" label="预约时段" :dense="false" emit-value map-options class="col-6 q-pr-lg q-pb-lg">
</q-select>
<q-select filled stack-label use-input option-value="StuId" option-label="StuName" v-model="postMsg.StuId"
ref="StuId" :options="StuList" label="学员" :dense="false" emit-value map-options class="col-6 q-pr-lg q-pb-lg"
@filter="filterStu">
</q-select>
</q-card-section>
<q-separator />
<q-card-actions align="right" class="bg-white">
<q-btn label="取消" flat color="grey-10" style="font-weight: 400 !important" @click="closeSaveForm" />
<q-btn label="立即提交" color="accent q-px-md" style="font-weight: 400 !important" :loading="saveLoading"
@click="saveAppointment" />
</q-card-actions>
</q-card>
</q-dialog>
</template>
<script>
import {
savePlanAppointment,
queryGetTimeList
} from "../../../api/stuMan/index";
import {
GetStudentList,
} from '../../../api/course/class';
import Lockr from "lockr";
export default {
props: {
setingObj: {
type: Object,
default: null,
},
},
data() {
return {
persistent: true,
postMsg: {
Date: "",
StartTime: "",
EndTime: "",
DetailsId: "",
StuId: "",
Account_Id: "",
chooseTime: ""
},
TimeList: [],
StuList: [],
allStuList: [], //所有学员
//防止重复提交
saveLoading: false,
};
},
created() {
this.getTimeList();
this.queryStudentList();
},
mounted() {
},
methods: {
//筛选学生
filterStu(val, update) {
update(() => {
if (val === "") {
this.StuList = JSON.parse(JSON.stringify(this.allStuList));
} else {
const needle = val.toLowerCase();
this.StuList = this.allStuList.filter(
v => v.StuName.toLowerCase().indexOf(needle) > -1
);
}
});
},
//获取学员列表
queryStudentList() {
GetStudentList({}).then(res => {
if (res.Code == 1) {
this.StuList = res.Data;
this.allStuList = res.Data;
}
})
},
//获取可约时间段
getTimeList() {
this.TimeList = [];
queryGetTimeList({}).then(res => {
if (res.Code == 1) {
var tempData = res.Data;
if (tempData && tempData.length > 0) {
tempData.forEach(item => {
this.TimeList.push({
Id: item.Sort,
Name: item.StartTime + "-" + item.EndTime,
StartTime: item.StartTime,
EndTime: item.EndTime
});
})
}
}
})
},
//关闭弹窗
closeSaveForm() {
this.$emit("refresh");
},
//保存预约信息
saveAppointment() {
if (this.postMsg.chooseTime && this.postMsg.chooseTime > 0) {
let chooseTime = this.TimeList.find(x => x.Id == this.postMsg.chooseTime);
if (chooseTime) {
this.postMsg.StartTime = chooseTime.StartTime;
this.postMsg.EndTime = chooseTime.EndTime;
}
}
if (this.postMsg.StuId && this.postMsg.StuId > 0) {
let chooseStu = this.allStuList.find(x => x.StuId == this.postMsg.StuId);
if (chooseStu) {
this.postMsg.Account_Id = chooseStu.Account_Id
}
}
this.saveLoading = true;
savePlanAppointment(this.postMsg).then(res => {
this.saveLoading = false;
if (res.Code == 1) {
this.$q.notify({
icon: 'iconfont icon-chenggong',
color: 'accent',
timeout: 2000,
message: '预约成功!',
position: 'top'
});
this.closeSaveForm();
}
}).catch(() => {
this.saveLoading = false
})
}
},
};
</script>
\ No newline at end of file
......@@ -3,30 +3,27 @@
<div style="padding: 20px 0;height: 700px;overflow-y: scroll;">
<div class="page-content">
<div class="list-box">
<!-- <div class="list-haeder">
<div>日期</div>
<div>上课学生</div>
</div> -->
<div v-for="item in tableData" class="listbox">
<div v-for="(item,index) in tableData" class="listbox" :key="index">
<div class="list-content">
<div class="content-week">
<p>{{item.DateStr}}</p>
<p>{{item.WeekStr}}</p>
</div>
<div class="content-right">
<div v-for="i in item.TimeList" class="right-box">
<div v-for="(subItem,subIndex) in item.TimeList" class="right-box" :key="subIndex">
<div class="content-class">
<div v-if="i.StartTime=='09:30'">第一节课</div>
<div v-if="i.StartTime=='11:10'">第二节课</div>
<div v-if="i.StartTime=='13:30'">第三节课</div>
<div v-if="i.StartTime=='15:10'">第四节课</div>
<div v-if="i.StartTime=='16:50'">第五节课</div>
<div v-if="i.StartTime=='19:00'">第六节课</div>
<div v-if="subItem.StartTime=='09:30'">第一节课</div>
<div v-if="subItem.StartTime=='11:10'">第二节课</div>
<div v-if="subItem.StartTime=='13:30'">第三节课</div>
<div v-if="subItem.StartTime=='15:10'">第四节课</div>
<div v-if="subItem.StartTime=='16:50'">第五节课</div>
<div v-if="subItem.StartTime=='19:00'">第六节课</div>
</div>
<div class="content-name">
<div v-for="S in i.StuList">
<q-badge color="blue" @click="getStuRight(S)">
{{S.StuName}}
<div v-for="(stuItem,stuIndex) in subItem.StuList" :key="stuIndex">
<q-badge color="blue" @click="getStuRight(stuItem)">
{{stuItem.StuName}}
</q-badge>
</div>
</div>
......@@ -39,21 +36,14 @@
</div>
<appointmentDetails v-if="isShowDetails" :showItem="showItem" @refreshpage="refreshpage"></appointmentDetails>
<!-- 学员信息抽屉 -->
<studentRight-form
v-if="isShowStuRight"
:isJudgeTrans="isJudgeTrans"
:BelongType="BelongType"
:save-obj="stuOption"
@close="closeStuForm"
@success="refreshStuList"
@reload="refreshStuList"
>
<studentRight-form v-if="isShowStuRight" :isJudgeTrans="isJudgeTrans" :BelongType="BelongType" :save-obj="stuOption"
@close="closeStuForm" @success="refreshStuList" @reload="refreshStuList">
</studentRight-form>
</div>
</template>
<script>
import appointmentDetails from "./appointmentDetails";
import studentRightForm from "../../../components/school/student/studentRight-form";//学员信息
import studentRightForm from "../../../components/school/student/studentRight-form"; //学员信息
export default {
props: {
tableData: {
......@@ -94,8 +84,8 @@
//是否显示预约详情
isShowDetails: false,
showItem: {},
isShowStuRight:false,
stuOption:null,
isShowStuRight: false,
stuOption: null,
BelongType: 1,
isJudgeTrans: 1,
};
......@@ -122,8 +112,8 @@
},
//刷新页面
refreshpage() {
this.isShowDetails=false;
this.showItem={};
this.isShowDetails = false;
this.showItem = {};
},
//显示预约详情
ShowStuAppoint(item) {
......@@ -134,27 +124,31 @@
};
</script>
<style>
.list-haeder div:first-child{
.list-haeder div:first-child {
width: 270px;
flex-shrink: 0;
text-align: center;
border-right: 1px solid #eeeeee;
}
.list-haeder div:last-child{
.list-haeder div:last-child {
padding: 0 0 0 10px;
}
.list-haeder{
.list-haeder {
line-height: 40px;
display: flex;
border-bottom: 1px solid #eeeeee;
color: #ffffff;
background: #305496;
}
.content-name div{
.content-name div {
margin-left: 5px;
cursor: pointer;
}
.content-name{
.content-name {
height: 40px;
overflow: hidden;
flex-grow: 1;
......@@ -165,10 +159,12 @@
border-bottom: 1px solid #eeeeee;
background: #ffffff;
}
.right-box:last-child .content-name{
.right-box:last-child .content-name {
border-bottom: 0;
}
.content-class{
.content-class {
width: 150px;
line-height: 40px;
height: 40px;
......@@ -178,51 +174,61 @@
background: #F2F4F7;
border-bottom: 1px solid #eeeeee;
}
.content-right .right-box:last-child .content-class{
.content-right .right-box:last-child .content-class {
border: 0;
}
.right-box{
.right-box {
display: flex;
align-items: center;
}
.content-right{
.content-right {
flex-grow: 1;
}
.content-week{
.content-week {
width: 120px;
flex-shrink: 0;
text-align: center;
}
.list-content{
.list-content {
display: flex;
align-items: center;
/* box-shadow: 0px 6px 14px 0px rgba(176, 176, 176, 0.2); */
}
.listbox{
.listbox {
display: flex;
flex-direction: column;
}
.list-box{
.list-box {
display: flex;
flex-direction: column;
border: 1px solid #eeeeee;
}
.list-box .listbox:last-child .height10{
.list-box .listbox:last-child .height10 {
height: 0;
border: 0;
}
.height10{
.height10 {
width: 100%;
height: 20px;
background: #F2F4F7;
border-top: 1px solid #eeeeee;
border-bottom: 1px solid #eeeeee;
}
.num-text{
cursor:pointer;
color:blue;
text-decoration:underline;
.num-text {
cursor: pointer;
color: blue;
text-decoration: underline;
margin-left: 10px;
margin-right: 30px;
}
......
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