|
@@ -102,7 +102,7 @@
|
|
|
当前日期暂无演出场次,请重新选择
|
|
|
</view>
|
|
|
<view class="date-list u-flex u-flex-wrap" v-else>
|
|
|
- <view class="date-item" :class="{active:sessionIndex==index}" @click="sessionClick(index,date)" v-for="(date,index) in sessionList" :key="index">
|
|
|
+ <view class="date-item" :class="{active:sessionIndex==index,disabled:!date.ifVaild}" @click="sessionClick(index,date)" v-for="(date,index) in sessionList" :key="index">
|
|
|
<view class="name">{{ date.performTimeStart}} - {{date.performTimeEnd}}</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -453,9 +453,13 @@
|
|
|
return item
|
|
|
});
|
|
|
console.log('this.sessionList',this.sessionList);
|
|
|
- this.sessionIndex = 0;
|
|
|
- let session = this.sessionList[this.sessionIndex];
|
|
|
- this.getPositionData();
|
|
|
+ // this.sessionIndex = 0;
|
|
|
+ this.sessionIndex = this.sessionList.findIndex(item => item.ifVaild === 1);
|
|
|
+ if (this.sessionIndex !== -1) {
|
|
|
+ this.getPositionData();
|
|
|
+ }
|
|
|
+ // let session = this.sessionList[this.sessionIndex];
|
|
|
+
|
|
|
}).catch(err=>{
|
|
|
console.log('getPoster',err);
|
|
|
})
|
|
@@ -563,6 +567,13 @@
|
|
|
sessionClick(index,data){
|
|
|
// console.log('sessionClick index',index);
|
|
|
console.log('sessionClick data',data);
|
|
|
+ if(!data.ifVaild){
|
|
|
+ uni.showToast({
|
|
|
+ title:'该场次不可用',
|
|
|
+ icon:'none'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
if(this.sessionIndex==index){
|
|
|
// console.log('不变');
|
|
|
return
|