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

1

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