Commit 9512ce6b authored by 罗超's avatar 罗超

1

parent c8aeed15
<template> <template>
<q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" transition-hide="scale"> <q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" transition-hide="scale">
<q-card style="width: 500px;max-width:600px;"> <q-card style="width: 600px;max-width:600px;">
<q-card-section> <q-card-section>
<div class="text-h6">{{objOption.RoomId==0?'新增教室信息':'修改教室信息'}}</div> <div class="text-h6">{{objOption.RoomId==0?'新增教室信息':'修改教室信息'}}</div>
</q-card-section> </q-card-section>
...@@ -22,7 +22,6 @@ ...@@ -22,7 +22,6 @@
<div class="row wrap"> <div class="row wrap">
<el-time-select <el-time-select
class="q-mr-lg" class="q-mr-lg"
v-model="objOption.StartTime" v-model="objOption.StartTime"
:picker-options="{ :picker-options="{
start: '00:00', start: '00:00',
...@@ -47,10 +46,10 @@ ...@@ -47,10 +46,10 @@
</div> </div>
<div class="row wrap" style="padding-top:20px"> <div class="row wrap" style="padding-top:20px">
<q-uploader style="display: inline-block;height:320px; max-width: 100%;background-repeat:no-repeat" <q-uploader style="display: inline-block;min-height:320px; max-width: 100%;background-repeat:no-repeat"
:style="{'background-image':'url(' + objOption.RoomPicList + ')'}" max-files="1" hide-upload-btn max-files="10" hide-upload-btn
label="教室封面" :max-file-size="5*1024*1024" accept=".jpg, image/*" auto-upload label="教室封面" :max-file-size="5*1024*1024" accept=".jpg, image/*" auto-upload multiple batch
:factory="uploadFile" > :factory="uploadFile">
</q-uploader> </q-uploader>
</div> </div>
...@@ -120,7 +119,7 @@ ...@@ -120,7 +119,7 @@
this.objOption.StartTime=res.Data.StartTime||"06:00";//排班开始时间 this.objOption.StartTime=res.Data.StartTime||"06:00";//排班开始时间
this.objOption.EndTime=res.Data.EndTime||"";//排班结束时间 this.objOption.EndTime=res.Data.EndTime||"";//排班结束时间
this.objOption.SeatNum=res.Data.SeatNum;//座位数 this.objOption.SeatNum=res.Data.SeatNum;//座位数
this.objOption.RoomPicList=res.Data.RoomPic;//教室图片 this.objOption.RoomPicList=res.Data.RoomPicList;//教室图片
} }
}); });
} else { } else {
...@@ -207,12 +206,15 @@ ...@@ -207,12 +206,15 @@
}) })
}, },
uploadFile(files) { uploadFile(files) {
UploadSelfFile('studentIcon', files[0], res => { UploadSelfFile('studentIcon', files[0], res => {
if (res.Code == 1) { if (res.Code == 1) {
this.objOption.RoomPicList = res.FileUrl; console.log(211,res)
this.objOption.RoomPicList.push(res.FileUrl);
} }
}) })
}, },
} }
} }
......
...@@ -44,6 +44,7 @@ ...@@ -44,6 +44,7 @@
<div v-if="chosenMenu==2" class="col" style="height: 750px;overflow: auto"> <div v-if="chosenMenu==2" class="col" style="height: 750px;overflow: auto">
<teachplan></teachplan> <teachplan></teachplan>
</div> </div>
<!-- 备课管理 -->
<div v-if="chosenMenu==3" style="height: 750px;overflow: auto"> <div v-if="chosenMenu==3" style="height: 750px;overflow: auto">
<mySchedule></mySchedule> <mySchedule></mySchedule>
</div> </div>
......
<template> <template>
<div class="page-body" v-loading="loading"> <div class="page-body room-list" v-loading="loading">
<div v-for="item in classdata" :key="item.Key" class="school-item"> <div v-for="item in classdata" :key="item.Key" class="school-item">
<div class="school-name">{{item.SchoolName}}</div> <div class="school-name">{{item.SchoolName}}</div>
<div class="classroom-box"> <div class="classroom-box">
<div v-for="(_item,_index) in item.RoomList" :key="item.RoomId" > <div v-for="(_item,_index) in item.RoomList" :key="item.RoomId" >
<div class="classroom-item q-mr-lg q-mb-lg" :class="{'classroom-item-noUse':_item.UserRate===1}" > <div class="classroom-item q-mr-lg q-mb-lg" :class="{'classroom-item-noUse':_item.UserRate==0}" >
<div @click="goUrl(item,_item)"> <div @click="goUrl(item,_item)">
<el-image class="classroom-img" :src="_item.RoomPicList[0]" fit="contain" > <el-image class="classroom-img" :src="_item.RoomPicList[0]" fit="contain" >
<div slot="error" class="image-slot"> <div slot="error" class="image-slot">
...@@ -35,6 +35,7 @@ ...@@ -35,6 +35,7 @@
使用率 使用率
</q-knob> </q-knob>
<div class="classroom-info"> <div class="classroom-info">
<div v-if="_item.TimeList.length>0">
<q-carousel <q-carousel
v-model="_item.slide" v-model="_item.slide"
animated animated
...@@ -46,14 +47,19 @@ ...@@ -46,14 +47,19 @@
control-text-color="primary" control-text-color="primary"
control-type="regular" control-type="regular"
> >
<q-carousel-slide v-for="(slide,slideIndex) in _item.TimeList" :key="slideIndex" :name="slideIndex"> <q-carousel-slide v-for="(slide,slideIndex) in _item.TimeList" :key="slideIndex" :name="slideIndex" >
<div class="info-box"> <div class="info-box">
<div class="time">{{ slide.StartTime }}</div> <div class="time">{{ slide.StartTime }}</div>
<div class="info">{{slide.ClassName}}</div> <div class="info">{{slide.TeacherName}}{{slide.ClassName}}</div>
</div> </div>
</q-carousel-slide> </q-carousel-slide>
</q-carousel> </q-carousel>
</div> </div>
<div v-if="_item.TimeList.length===0" class="no-data">
暂无课程安排
</div>
</div>
</div> </div>
</div> </div>
...@@ -139,10 +145,12 @@ import { ...@@ -139,10 +145,12 @@ import {
margin-bottom: 30px; margin-bottom: 30px;
} }
.classroom-box{ .classroom-box{
width: 1680px;
display: flex; display: flex;
// justify-content: space-between;
flex-wrap: wrap; flex-wrap: wrap;
.classroom-item-noUse{ .classroom-item-noUse{
opacity:0.5; opacity:0.8;
} }
.classroom-item{ .classroom-item{
width: 390px; width: 390px;
...@@ -215,5 +223,15 @@ import { ...@@ -215,5 +223,15 @@ import {
} }
} }
} }
.no-data{
height: 75px;
font-size: 14px;
color: #000000;
display: flex;
justify-content: center;
align-items: center;
}
.room-list{
overflow: scroll;
}
</style> </style>
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<!-- </q-item-section> --> <!-- </q-item-section> -->
<q-item-section>{{x.SchoolName}}</q-item-section> <q-item-section>{{x.SchoolName}}</q-item-section>
</q-item> </q-item>
<q-expansion-item v-else :label="x.SchoolName" @show="showNav($event,x.Key)"> <q-expansion-item v-else :label="x.SchoolName" @show="showNav($event,x.Key)" :default-opened="x.Key===routeKey">
<q-item to="" clickable v-ripple :active="currentNav==y.RoomId" <q-item to="" clickable v-ripple :active="currentNav==y.RoomId"
v-for="(y, yi) in x.RoomList" :key="y.RoomId" @click="chooseNav(y)"> v-for="(y, yi) in x.RoomList" :key="y.RoomId" @click="chooseNav(y)">
<!-- <q-item-section avatar style="padding-right:0;min-width:30px;"> --> <!-- <q-item-section avatar style="padding-right:0;min-width:30px;"> -->
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</template> </template>
<script> <script>
import { active } from 'src/pages/financial/lang/zh'; // import { active } from 'src/pages/financial/lang/zh';
export default { export default {
meta: { meta: {
title: "使用记录" title: "使用记录"
...@@ -37,19 +37,47 @@ import { active } from 'src/pages/financial/lang/zh'; ...@@ -37,19 +37,47 @@ import { active } from 'src/pages/financial/lang/zh';
activeNav:{ activeNav:{
type:[Number,String], type:[Number,String],
default:0 default:0
},
activeFaNav:{
type:[Number,String],
default:0
}
},
watch:{
activeNav:{
handler(val){
if(!this.$route.query.key){
this.currentNav=val
}
}
},
activeFaNav:{
handler(val){
if(!this.$route.query.key){
this.routeKey=val
}
}
} }
}, },
data() { data() {
return { return {
currentNav: this.activeNav, currentNav: this.activeNav,
schoolId:0, schoolId:0,
routeKey:0,
}; };
}, },
created(){
if(this.$route.query.key){
this.routeKey=this.$route.query.key
}
},
mounted(){
},
methods:{ methods:{
showNav(val,id){ showNav(val,id){
this.schoolId=id this.schoolId=id
console.log(id)
}, },
chooseNav(i){ chooseNav(i){
this.currentNav=i.RoomId this.currentNav=i.RoomId
......
...@@ -230,7 +230,7 @@ ...@@ -230,7 +230,7 @@
} }
.comSummary .summaryTable { .comSummary .summaryTable {
width:100%; width:100%;
min-width: 1400px; /* min-width: 1400px; */
border-radius:4px; border-radius:4px;
/* background-color:#E6E6E6; */ /* background-color:#E6E6E6; */
background-color: #F1F6FB; background-color: #F1F6FB;
......
<style lang="scss"> <style lang="scss">
@import "./css/comSummary.css"; @import "./css/comSummary.css";
.td-item{ .td-item{
min-width: 160px; // min-width: 160px;
width: 100%;
position: relative; position: relative;
margin: 0 10px; margin: 0 10px;
border-radius: 4px; border-radius: 4px;
box-shadow: 0px 4px 40px 0px rgba(2, 44, 66, 0.1); box-shadow: 0px 4px 40px 0px rgba(2, 44, 66, 0.1);
margin-bottom: 20px; // margin-bottom: 20px;
padding: 10px; padding: 10px;
background-color: #fff; background-color: #fff;
.ClassStatus{ .ClassStatus{
...@@ -88,13 +89,13 @@ ...@@ -88,13 +89,13 @@
</td> </td>
<td v-for="(item,index) in tbodayData" :class="{'td-bg':index%2==0}" > <td v-for="(item,index) in tbodayData" :class="{'td-bg':index%2==0}" >
<div v-for="(_item,_index) in item.InfoList" class="absolute" :style="{'top':_item.offSetTop+'px','z-index':_index}"> <div v-for="(_item,_index) in item.InfoList" class="absolute" :style="{'top':_item.offSetTop+'px','z-index':_index}">
<div class="td-item" v-if="_item.Type===0" @click="goCourseInfo(_item)"> <div class="td-item" v-if="_item.Type===0" @click="goCourseInfo(_item)" :style="{'height':_item.height}">
<img src="../../../assets/images/classroom/useing.png" alt="" class="ClassStatus" v-if="_item.ClassStatus===1"> <img src="../../../assets/images/classroom/useing.png" alt="" class="ClassStatus" v-if="_item.ClassStatus===1">
<img src="../../../assets/images/classroom/not-use.png" alt="" class="ClassStatus" v-if="_item.ClassStatus!==1"> <img src="../../../assets/images/classroom/not-use.png" alt="" class="ClassStatus" v-if="_item.ClassStatus!==1">
<span class="name">{{_item.Title}}</span> <span class="name">{{_item.Title}}</span>
<div class="time">{{_item.StartTime}}-{{_item.EndTime}}</div> <div class="time">{{_item.StartTime}}-{{_item.EndTime}}</div>
</div> </div>
<div class="td-item" v-if="_item.Type===1" @click="taggleUserHistory(_item)"> <div class="td-item" v-if="_item.Type===1" @click="taggleUserHistory(_item)" :style="{'height':_item.height}">
<span class="name">{{_item.Title}}</span> <span class="name">{{_item.Title}}</span>
<div class="time">{{_item.StartTime}}-{{_item.EndTime}}</div> <div class="time">{{_item.StartTime}}-{{_item.EndTime}}</div>
</div> </div>
...@@ -139,8 +140,12 @@ export default { ...@@ -139,8 +140,12 @@ export default {
let top= this.getOffSet(i) let top= this.getOffSet(i)
_e.offSetTop=top-190 _e.offSetTop=top-190
} }
// let res=this.timeDifference(_e.StartTime,_e.EndTime)
_e.height=_e.IntervalNum*41+'px'
}) })
} }
}) })
}) })
}, },
...@@ -393,7 +398,19 @@ export default { ...@@ -393,7 +398,19 @@ export default {
let el=document.getElementsByClassName('el-timeline-item')[index] let el=document.getElementsByClassName('el-timeline-item')[index]
let top=el.getBoundingClientRect().top let top=el.getBoundingClientRect().top
return top return top
} },
// timeDifference(startTime,endTime){
// var start1=startTime.split(":");
// var startAll=parseInt(start1[0]*60)+parseInt(start1[1]);
// var end1=endTime.split(":");
// var endAll=parseInt(end1[0]*60)+parseInt(end1[1]);
// let res=Math.ceil((endAll-startAll)/15)
// console.log("时间差===",res);
// return res
// }
}, },
mounted() { mounted() {
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
</q-popup-proxy> </q-popup-proxy>
</q-btn> </q-btn>
</div> --> </div> -->
<ClassroomNav :NavData="navData" :activeNav="msg.RoomId" @success="successNav"/> <ClassroomNav :NavData="navData" :activeNav="msg.RoomId" :activeFaNav="msg.SchoolId" @success="successNav"/>
</div> </div>
<div class="right"> <div class="right">
<Calendar :tbodayData="tbodayData" :startT="dateModel" @change="CalendarChange"></Calendar> <Calendar :tbodayData="tbodayData" :startT="dateModel" @change="CalendarChange"></Calendar>
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
} from '../../api/classroom/index'; } from '../../api/classroom/index';
export default { export default {
meta: { meta: {
title: "教室状态" title: "使用记录"
}, },
components:{ components:{
ClassroomNav, ClassroomNav,
...@@ -53,8 +53,12 @@ ...@@ -53,8 +53,12 @@
}; };
}, },
created(){ created(){
if(this.$route.query.key){
this.msg.SchoolId=this.$route.query.key this.msg.SchoolId=this.$route.query.key
}
if(this.$route.query.roomId){
this.msg.RoomId=this.$route.query.roomId this.msg.RoomId=this.$route.query.roomId
}
let d=new Date(); let d=new Date();
let year =d.getFullYear(); let year =d.getFullYear();
let month=d.getMonth()+1; let month=d.getMonth()+1;
...@@ -90,6 +94,12 @@ ...@@ -90,6 +94,12 @@
getSchoolAndRoomNav({}).then(res => { getSchoolAndRoomNav({}).then(res => {
if(res.Code===1){ if(res.Code===1){
this.navData=res.Data this.navData=res.Data
if(!this.$route.query.key){
this.msg.SchoolId=this.navData[0].Key
}
if(!this.$route.query.roomId){
this.msg.RoomId=this.navData[0].RoomList[0].RoomId
}
that.getClassRoomTimeList() that.getClassRoomTimeList()
} }
}).catch(() => { }).catch(() => {
...@@ -116,7 +126,7 @@ ...@@ -116,7 +126,7 @@
this.$forceUpdate() this.$forceUpdate()
}, },
dateChoose(value, reason, details){ dateChoose(value, reason, details){
console.log(112,this.dateModel) // console.log(112,this.dateModel)
}, },
//获取结束日期 //获取结束日期
getEndTime(date){ getEndTime(date){
...@@ -158,11 +168,40 @@ ...@@ -158,11 +168,40 @@
.con{ .con{
padding: 5px !important; padding: 5px !important;
display: flex; display: flex;
height: calc( 100vh - 80px);
.left{ .left{
width: 200px; width: 200px;
background-color: rgb(245, 246, 247); background-color: rgb(245, 246, 247);
min-height: 100%;
}
.right{
width: calc(100% + 10px);
padding-right: 10px;
height: 100%;
overflow: scroll;
} }
} }
.right::-webkit-scrollbar{
width:10px;
height:10px;
/**/
}
.right::-webkit-scrollbar-track{
background: rgb(239, 239, 239);
border-radius:2px;
}
.right::-webkit-scrollbar-thumb{
background: #bfbfbf;
border-radius:10px;
}
.right::-webkit-scrollbar-thumb:hover{
background: #333;
}
.right::-webkit-scrollbar-corner{
background: #179a16;
}
.dateModel{ .dateModel{
// height: 50px; // height: 50px;
padding: 20px 10px; padding: 20px 10px;
......
...@@ -386,7 +386,10 @@ ...@@ -386,7 +386,10 @@
}) })
this.plmsg.Score = 5; this.plmsg.Score = 5;
this.plmsg.Comment = ''; this.plmsg.Comment = '';
this.getUserComment()
this.getCommentList() this.getCommentList()
} }
}) })
}, },
......
...@@ -201,6 +201,12 @@ ...@@ -201,6 +201,12 @@
color:var(--q-color-primary); color:var(--q-color-primary);
margin-left:10px; margin-left:10px;
} }
.teacherLesson .teacher-box{
background-color: #f5f5f5;
padding: 20px;
border-radius: 20px;
margin-bottom: 20px;
}
</style> </style>
<template> <template>
<div class="page-body teacherLesson"> <div class="page-body teacherLesson">
...@@ -241,7 +247,9 @@ ...@@ -241,7 +247,9 @@
</div> </div>
<div class="TeacherYarr">{{tYear}}{{tMonth}}{{ckedIndex}}</div> <div class="TeacherYarr">{{tYear}}{{tMonth}}{{ckedIndex}}</div>
<div style="margin-top:30px;"> <div style="margin-top:30px;">
<div class="TeacherInfo_List" v-for="(item,index) in newDataList"> <div >
<div v-for="item1 in newDataListRes" :key="item1.id" class="teacher-box">
<div class="TeacherInfo_List" v-for="(item,index) in item1.planListTeacher">
<div class="timeleft"> <div class="timeleft">
<div style="width: 45px;"> <div style="width: 45px;">
{{item.StartTime}} {{item.StartTime}}
...@@ -263,6 +271,8 @@ ...@@ -263,6 +271,8 @@
<span class="beikeBtn" v-if="item.LessonPlanNum>0" style="background:#3FC4FF;" @click="goyibeike(item)">已备课</span> <span class="beikeBtn" v-if="item.LessonPlanNum>0" style="background:#3FC4FF;" @click="goyibeike(item)">已备课</span>
<span class="beikeBtn" v-if="AccountType&&item.LessonPlanNum==0" @click="goBeike(item)">备课</span> <span class="beikeBtn" v-if="AccountType&&item.LessonPlanNum==0" @click="goBeike(item)">备课</span>
<span class="beikeBtn" v-if="AccountType&&item.LessonPlanNum>0" @click="goBeike(item)">修改</span> <span class="beikeBtn" v-if="AccountType&&item.LessonPlanNum>0" @click="goBeike(item)">修改</span>
<span class="beikeBtn" v-if="item.LessonPlanNum===0" >未备课</span>
</div>
</div> </div>
</div> </div>
</div> </div>
...@@ -270,6 +280,8 @@ ...@@ -270,6 +280,8 @@
</div> </div>
</div> </div>
</div>
</template> </template>
<script> <script>
...@@ -296,6 +308,7 @@ ...@@ -296,6 +308,7 @@
}, },
dataList: [], dataList: [],
newDataList:[], newDataList:[],
newDataListRes:[],
AccountType:true, AccountType:true,
} }
}, },
...@@ -359,7 +372,8 @@ ...@@ -359,7 +372,8 @@
} }
this.dataList.forEach(x=>{ this.dataList.forEach(x=>{
if(x.DateYear==this.tYear&&x.DateMonth==month&&x.DateDay==day){ if(x.DateYear==this.tYear&&x.DateMonth==month&&x.DateDay==day){
this.newDataList = x.PlanList; this.newDataList = x.planList;
this.newDataListRes = x.planListResult;
} }
}) })
} }
...@@ -379,6 +393,7 @@ ...@@ -379,6 +393,7 @@
this.dataList.forEach(x=>{ this.dataList.forEach(x=>{
if(x.DateYear==this.tYear&&x.DateMonth==month&&x.DateDay==day){ if(x.DateYear==this.tYear&&x.DateMonth==month&&x.DateDay==day){
this.newDataList = x.PlanList; this.newDataList = x.PlanList;
this.newDataListRes = x.planListResult;
} }
}) })
}, },
...@@ -404,6 +419,7 @@ ...@@ -404,6 +419,7 @@
} }
} }
}) })
console.log()
return Str; return Str;
}, },
//跳转至备课 //跳转至备课
......
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