From 07db3d92d9fa0ad7083c80ec6528d432e12e575f Mon Sep 17 00:00:00 2001
From: lion <120344285@qq.com>
Date: Fri, 16 Dec 2022 13:33:35 +0800
Subject: [PATCH] =?UTF-8?q?=E6=B4=BB=E5=8A=A8=E9=A2=84=E7=BA=A6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/activity/book.vue | 3 +-
pages/activity/index.vue | 5 +--
pages/activity/info.vue | 73 ++++++++++++++++++++++++++++++++++++----
utils/util.js | 2 +-
4 files changed, 73 insertions(+), 10 deletions(-)
diff --git a/pages/activity/book.vue b/pages/activity/book.vue
index f07a67f..53bda34 100644
--- a/pages/activity/book.vue
+++ b/pages/activity/book.vue
@@ -332,7 +332,8 @@
onLoad(options) {
this.type = options.type;
this.form.type = (options.type == 'user' ? 2 : 1);
- this.form.activity_id = parseInt(options.activity_id);
+ this.form.activity_id = parseInt(options.activity_id);
+ this.form.activity_number_id = parseInt(options.activity_number_id);
var that = this;
wx.getStorage({
key: 'activityinfo',
diff --git a/pages/activity/index.vue b/pages/activity/index.vue
index e44af05..5503f8d 100644
--- a/pages/activity/index.vue
+++ b/pages/activity/index.vue
@@ -21,7 +21,7 @@
{{isUnde(item.type_name)}}
-
+
已约满
@@ -110,7 +110,8 @@
url: "info?id=" + obj.id
})
},
- loadActivity() {
+ loadActivity() {
+ console.log("aaa")
var that = this;
var nt = new Date();
that.isloading = true;
diff --git a/pages/activity/info.vue b/pages/activity/info.vue
index 83e4376..2ea81ae 100644
--- a/pages/activity/info.vue
+++ b/pages/activity/info.vue
@@ -64,7 +64,26 @@
-
+
+
@@ -85,6 +105,11 @@
longitude: "",
list: {},
topSwiperIndex: 0,
+ chooseNum: "",
+ numbers: [],
+ showNumbers: false,
+ teamType:"",
+ activity_number_id:""
}
},
onLoad(options) {
@@ -118,12 +143,22 @@
name: this.list.name,
address: this.list.address
})
+ },
+ 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)
+ uni.navigateTo({
+ url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id
+ })
},
tobook(type) {
-
- uni.navigateTo({
- url: "book?type=" + type + "&activity_id=" + this.id
- })
+ this.showNumbers = true
+ this.teamType = type
},
loadActiveInfo() {
var that = this;
@@ -137,7 +172,16 @@
},
utilSuccess: function(res) {
res.isCanBook = that.$moment(nt).isBefore(res.end_plan);
- that.list = res;
+ that.list = res;
+ let numberArr = []
+ 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){
+ m.disabled = true
+ }
+ numberArr.push(m)
+ }
+ that.numbers = numberArr
wx.setStorage({
key: 'activityinfo',
data: res,
@@ -212,6 +256,23 @@
box-shadow: 2px 3px 10px 0px rgba(107, 94, 77, 0.3);
padding: 22rpx 25rpx;
box-sizing: border-box;
+ /* background: linear-gradient(0deg, #ffffff 85%, #E4C8A2); */
+ }
+ .mpopup{
+ margin-top:0rpx;
+ min-height:200rpx
+
+ }
+ .mpopup-title{
+ padding:20rpx 0
+ }
+ .numbers {
+ /* min-height: 300rpx; */
+ padding: 60rpx 40rpx;
+ }
+
+ .numbers .u-radio {
+ margin-bottom: 40rpx
}
swiper {
diff --git a/utils/util.js b/utils/util.js
index e9d644b..5e9128b 100755
--- a/utils/util.js
+++ b/utils/util.js
@@ -1,6 +1,6 @@
import md5 from "./md5.min";
const HOSTARR = {
- 'development': 'https://leyiyuyue.szgmbwg.org.cn',
+ 'development': 'http://leyitest.ali251.langye.net',
'production': 'https://leyiyuyue.szgmbwg.org.cn'
}; // 审核状态