|
|
|
|
@ -115,8 +115,8 @@
|
|
|
|
|
chooseNum: "",
|
|
|
|
|
numbers: [],
|
|
|
|
|
showNumbers: false,
|
|
|
|
|
teamType:"",
|
|
|
|
|
activity_number_id:""
|
|
|
|
|
teamType: "",
|
|
|
|
|
activity_number_id: ""
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
onLoad(options) {
|
|
|
|
|
@ -151,14 +151,15 @@
|
|
|
|
|
address: this.list.address
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
closeNum(){
|
|
|
|
|
this.showNumbers=false
|
|
|
|
|
closeNum() {
|
|
|
|
|
this.showNumbers = false
|
|
|
|
|
this.chooseNum = ""
|
|
|
|
|
},
|
|
|
|
|
numChange(val) {
|
|
|
|
|
console.log(val)
|
|
|
|
|
this.activity_number_id = val
|
|
|
|
|
console.log("book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id)
|
|
|
|
|
console.log("book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id=" + this
|
|
|
|
|
.activity_number_id)
|
|
|
|
|
// uni.navigateTo({
|
|
|
|
|
// url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id
|
|
|
|
|
// })
|
|
|
|
|
@ -167,7 +168,7 @@
|
|
|
|
|
// this.showNumbers = true
|
|
|
|
|
this.teamType = type;
|
|
|
|
|
|
|
|
|
|
if(this.util.isNull(this.activity_number_id)){
|
|
|
|
|
if (this.util.isNull(this.activity_number_id)) {
|
|
|
|
|
uni.showToast({
|
|
|
|
|
icon: "none",
|
|
|
|
|
title: "请选择活动场次"
|
|
|
|
|
@ -175,7 +176,8 @@
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
uni.navigateTo({
|
|
|
|
|
url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id
|
|
|
|
|
url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id=" + this
|
|
|
|
|
.activity_number_id
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
loadActiveInfo() {
|
|
|
|
|
@ -193,14 +195,17 @@
|
|
|
|
|
that.list = res;
|
|
|
|
|
let numberArr = []
|
|
|
|
|
let nowTime = that.getNowTime()
|
|
|
|
|
for(var m of res.numbers){
|
|
|
|
|
m.label = m.name + "(" + that.timeFormat(m.start_time,"yyyy年MM月DD日") + " " + that.getHm(m.start_time)+"-"+that.getHm(m.end_time) + ")"
|
|
|
|
|
if(m.has_total==m.total&&m.total!=0 || that.compareDate(nowTime,m.end_plan)){
|
|
|
|
|
for (var m of res.numbers) {
|
|
|
|
|
m.label = m.name + "(" + that.timeFormat(m.start_time, "yyyy年MM月DD日") + " " + that
|
|
|
|
|
.getHm(m.start_time) + "-" + that.getHm(m.end_time) + ")"
|
|
|
|
|
if (m.has_total == m.total && m.total != 0 || that.compareDate(nowTime, m
|
|
|
|
|
.end_plan)) {
|
|
|
|
|
m.disabled = true
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
numberArr.push(m)
|
|
|
|
|
numberArr.push(m);
|
|
|
|
|
if(that.chooseNum==""){
|
|
|
|
|
that.chooseNum=m.id;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
that.numbers = numberArr
|
|
|
|
|
wx.setStorage({
|
|
|
|
|
@ -217,14 +222,14 @@
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
// 比较时间
|
|
|
|
|
getNowTime(){
|
|
|
|
|
getNowTime() {
|
|
|
|
|
const date = new Date();
|
|
|
|
|
let year = date.getFullYear();
|
|
|
|
|
let month = date.getMonth() + 1;
|
|
|
|
|
let day = date.getDate();
|
|
|
|
|
let hours = date.getHours()
|
|
|
|
|
let minutes = date.getMinutes()
|
|
|
|
|
let seconds =date.getSeconds()
|
|
|
|
|
let seconds = date.getSeconds()
|
|
|
|
|
month = month > 9 ? month : '0' + month;
|
|
|
|
|
day = day > 9 ? day : '0' + day;
|
|
|
|
|
return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
|
|
|
|
|
@ -296,18 +301,20 @@
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
/* background: linear-gradient(0deg, #ffffff 85%, #E4C8A2); */
|
|
|
|
|
}
|
|
|
|
|
.mpopup{
|
|
|
|
|
margin-top:0rpx;
|
|
|
|
|
min-height:200rpx
|
|
|
|
|
|
|
|
|
|
.mpopup {
|
|
|
|
|
margin-top: 0rpx;
|
|
|
|
|
min-height: 200rpx
|
|
|
|
|
}
|
|
|
|
|
.mpopup-title{
|
|
|
|
|
padding:20rpx 0
|
|
|
|
|
|
|
|
|
|
.mpopup-title {
|
|
|
|
|
padding: 20rpx 0
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.numbers {
|
|
|
|
|
/* min-height: 300rpx; */
|
|
|
|
|
padding: 31rpx 24rpx;
|
|
|
|
|
padding-bottom:13rpx;
|
|
|
|
|
padding-bottom: 13rpx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.numbers .u-radio {
|
|
|
|
|
|