【bug】会议报名时间超出的提示
This commit is contained in:
@@ -24,7 +24,18 @@ Page({
|
||||
// 缴费二维码的图片路径
|
||||
payOrCode: '',
|
||||
// 标协会议酒店信息
|
||||
hotelContactsList:[]
|
||||
hotelContactsList:[],
|
||||
// 当前会议是否超出时间
|
||||
isMoreBool:false
|
||||
},
|
||||
compareCurrentTime(time) {
|
||||
let date = new Date()
|
||||
let compareTime = new Date(time)
|
||||
if (date.getTime() > compareTime.getTime()) {
|
||||
return true
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
},
|
||||
// 获取会议详情
|
||||
queryMeetingDetail(id) {
|
||||
@@ -46,6 +57,17 @@ Page({
|
||||
meetingFilesList: res,
|
||||
})
|
||||
})
|
||||
// 判断当前会议是否超出时间
|
||||
let flag = that.compareCurrentTime(res.result.registerDeadline)
|
||||
if(flag){
|
||||
wx.showToast({
|
||||
title: '当前会议超出报名时间,不可报名',
|
||||
duration:3000
|
||||
})
|
||||
}
|
||||
that.setData({
|
||||
isMoreBool:false
|
||||
})
|
||||
}
|
||||
}).catch(err => {
|
||||
wx.showToast({
|
||||
|
||||
@@ -118,7 +118,7 @@
|
||||
</view>
|
||||
|
||||
<view class="sign-up-empty"></view>
|
||||
<view class="sign-up">
|
||||
<view class="sign-up" wx:if="{{isMoreBool}}">
|
||||
<button class="sign-up-btn" bindtap='signUp'>报名</button>
|
||||
</view>
|
||||
</view>
|
||||
Reference in New Issue
Block a user