Commit 85f217ae authored by youjie's avatar youjie

no message

parent 803dfdcc
...@@ -112,6 +112,7 @@ ...@@ -112,6 +112,7 @@
proxy proxy
} = getCurrentInstance() } = getCurrentInstance()
const data = reactive({ const data = reactive({
isShowCalendar: false,
month:"", month:"",
titleList:[], titleList:[],
lessonList:[], lessonList:[],
...@@ -487,7 +488,7 @@ ...@@ -487,7 +488,7 @@
.text-img.activeTwo{ .text-img.activeTwo{
background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_986.png)no-repeat center #EED9FE; background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_986.png)no-repeat center #EED9FE;
background-size: 39rpx 38rpx; background-size: 39rpx 38rpx;
border-right: 2rpx solid #EED9FE; border-right: 2rpx solid #E3E1E7;
} }
.text-img.activeTwo .bottom{ .text-img.activeTwo .bottom{
width: 100%; width: 100%;
...@@ -499,7 +500,7 @@ ...@@ -499,7 +500,7 @@
.text-img.activeThree{ .text-img.activeThree{
background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_779.png)no-repeat center #D6F2E6; background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_779.png)no-repeat center #D6F2E6;
background-size: 39rpx 38rpx; background-size: 39rpx 38rpx;
border-right: 2rpx solid #D6F2E6; border-right: 2rpx solid #E3E1E7;
} }
.text-img.activeThree .bottom{ .text-img.activeThree .bottom{
width: 100%; width: 100%;
...@@ -511,7 +512,7 @@ ...@@ -511,7 +512,7 @@
.text-img.activeFour{ .text-img.activeFour{
background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577019000_548.png)no-repeat center #FFF2F2; background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577019000_548.png)no-repeat center #FFF2F2;
background-size: 39rpx 38rpx; background-size: 39rpx 38rpx;
border-right: 2rpx solid #FFF2F2; border-right: 2rpx solid #E3E1E7;
} }
.text-img.activeFour .bottom{ .text-img.activeFour .bottom{
width: 100%; width: 100%;
...@@ -523,7 +524,7 @@ ...@@ -523,7 +524,7 @@
.text-img.activeFive{ .text-img.activeFive{
background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_644.png)no-repeat center #E5F3FF; background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_644.png)no-repeat center #E5F3FF;
background-size: 39rpx 38rpx; background-size: 39rpx 38rpx;
border-right: 2rpx solid #E5F3FF; border-right: 2rpx solid #E3E1E7;
} }
.text-img.activeFive .bottom{ .text-img.activeFive .bottom{
width: 100%; width: 100%;
...@@ -535,7 +536,7 @@ ...@@ -535,7 +536,7 @@
.text-img.activeSix{ .text-img.activeSix{
background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_746.png)no-repeat center #EAF8FB; background: url(https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1656577024000_746.png)no-repeat center #EAF8FB;
background-size: 39rpx 38rpx; background-size: 39rpx 38rpx;
border-right: 2rpx solid #EAF8FB; border-right: 2rpx solid #E3E1E7;
} }
.text-img.activeSix .bottom{ .text-img.activeSix .bottom{
width: 100%; width: 100%;
......
...@@ -5,21 +5,56 @@ ...@@ -5,21 +5,56 @@
<view>{{year}}{{month}}</view> <view>{{year}}{{month}}</view>
<view>计划 {{total}}节课</view> <view>计划 {{total}}节课</view>
</view> </view>
<scroll-view scroll-y="true" style="width:100%;height: 100%;"> <!-- 滑动查看上周本周 -->
<view class="titleHeader-dateStr"> <!-- <swiper :style="{height:!isShowAllDay?'220rpx':'620rpx'}" circular :current="1"
<view v-for="item in titleList" @change="changeSwiper($event,preSwiperId)">
class="titleHeader-content"> <swiper-item :key="Sindex" v-for="i in 2">
<view class="titleHeader-name">{{item.name}}</view> <view class="titleHeader-dateStr">
<view class="titleHeader-num">{{item.num}}</view> <view v-for="item in titleList"
<view class="titleHeader-mark"> class="titleHeader-content">
<view v-for="(items,index) in item.listNum" :key="index" <view class="titleHeader-name">{{item.name}}</view>
:class="{'activeOne':items.StartTime=='09:30','activeTwo':items.StartTime=='11:10', <view class="titleHeader-num">{{item.num}}</view>
'activeThree':items.StartTime=='13:30','activeFour':items.StartTime=='15:10', <view class="titleHeader-mark" v-if="dataList.length>0">
'activeFive':items.StartTime=='16:50','activeSix':item.StartTime=='19:00'}"></view> <view v-for="(items,index) in item.listNum" :key="index"
:class="{'activeOne':items.StartTime=='09:30','activeTwo':items.StartTime=='11:10',
'activeThree':items.StartTime=='13:30','activeFour':items.StartTime=='15:10',
'activeFive':items.StartTime=='16:50','activeSix':item.StartTime=='19:00'}"></view>
</view>
</view> </view>
</view> </view>
</swiper-item>
</swiper> -->
<!-- 按钮切换上周下周本周 -->
<view class="titleHeader-dateStr">
<view v-if="weekType!=0" class="week" @click="getMonday(0)">
本周
</view> </view>
</scroll-view> <view class="position clickLeft" @click="getMonday(-1)">
<van-icon
name="arrow-left"
size="28rpx"
color="#333333"
></van-icon>
</view>
<view v-for="item in titleList"
class="titleHeader-content">
<view class="titleHeader-name">{{item.name}}</view>
<view class="titleHeader-num">{{item.num}}</view>
<view class="titleHeader-mark" v-if="dataList.length>0">
<view v-for="(items,index) in item.listNum" :key="index"
:class="{'activeOne':items.StartTime=='09:30','activeTwo':items.StartTime=='11:10',
'activeThree':items.StartTime=='13:30','activeFour':items.StartTime=='15:10',
'activeFive':items.StartTime=='16:50','activeSix':item.StartTime=='19:00'}"></view>
</view>
</view>
<view class="position clickRight" @click="getMonday(1)">
<van-icon
name="arrow"
size="28rpx"
color="#333333"
></van-icon>
</view>
</view>
</view> </view>
<view class="content-box" v-if="dataList.length>0"> <view class="content-box" v-if="dataList.length>0">
<scroll-view scroll-y="true" style="width:100%;height: 100%;"> <scroll-view scroll-y="true" style="width:100%;height: 100%;">
...@@ -69,6 +104,10 @@ ...@@ -69,6 +104,10 @@
proxy proxy
} = getCurrentInstance() } = getCurrentInstance()
const data = reactive({ const data = reactive({
indicatorDots: true,
autoplay: true,
interval: 2000,
duration: 500,
year: "", year: "",
month:"", month:"",
day:"", day:"",
...@@ -87,9 +126,24 @@ ...@@ -87,9 +126,24 @@
{name:'星期五',num:'',listNum:[]}, {name:'星期五',num:'',listNum:[]},
{name:'星期六',num:'',listNum:[]}, {name:'星期六',num:'',listNum:[]},
{name:'星期日',num:'',listNum:[]}, {name:'星期日',num:'',listNum:[]},
] ],
currentSwiper: 1,
preSwiperId: 1,
timer: null, //防抖
weekType: 0
}) })
const methods = { const methods = {
changeSwiper(val, PreId) {
let CurId = val.detail.current
// 上周
if(CurId==0){
methods.getMonday(-1)
}
// 本周
if(CurId==1){
methods.getMonday(0)
}
},
addPlan(){ addPlan(){
uni.navigateTo({ uni.navigateTo({
url: '/pages/bookAclass/addPlan', url: '/pages/bookAclass/addPlan',
...@@ -137,6 +191,7 @@ ...@@ -137,6 +191,7 @@
}, },
// 实现方法 // 实现方法
getMonday(dates) { getMonday(dates) {
data.weekType = dates
let arr = [],weekOne=''; let arr = [],weekOne='';
let todayTimeStr = new Date(new Date().toLocaleDateString()).getTime(); let todayTimeStr = new Date(new Date().toLocaleDateString()).getTime();
var day = (new Date().getDay() - 1) * 24 * 60 * 60 * 1000; var day = (new Date().getDay() - 1) * 24 * 60 * 60 * 1000;
...@@ -172,7 +227,7 @@ ...@@ -172,7 +227,7 @@
data.msg.StartDate = arr[0] data.msg.StartDate = arr[0]
data.msg.EndDate = arr[6] data.msg.EndDate = arr[6]
methods.getList() methods.getList()
// return arr; return arr;
}, },
getList(){ getList(){
if(data.msg.StartDate){ if(data.msg.StartDate){
...@@ -248,7 +303,6 @@ ...@@ -248,7 +303,6 @@
top: 475rpx; top: 475rpx;
} }
.noCourse { .noCourse {
margin-top: 163rpx;
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: center; justify-content: center;
...@@ -272,6 +326,36 @@ ...@@ -272,6 +326,36 @@
.titleHeader-dateStr{ .titleHeader-dateStr{
display: flex; display: flex;
flex-wrap: nowrap; flex-wrap: nowrap;
position: relative;
}
.position{
position: absolute;
top: 50rpx;
z-index: 2;
width: 50rpx;
height: 50rpx;
line-height: 50rpx;
text-align: center;
background: rgba(255,255,255,1);
box-shadow: 0rpx 10rpx 30rpx 0rpx rgba(255,255,255, 0.2);
border-radius: 50%;
}
.week{
position: absolute;
top: -75rpx;
right: -40rpx;
border-radius: 20rpx 0 0 20rpx;
background: rgba(255,255,255,1);
box-shadow: 0rpx 10rpx 30rpx 0rpx rgba(255,255,255, 0.2);
font-size: 24rpx;
line-height: 40rpx;
padding: 0 10rpx;
}
.clickLeft{
left: -20rpx;
}
.clickRight{
right: -20rpx;
} }
.titleHeader-content{ .titleHeader-content{
width: 89rpx; width: 89rpx;
......
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