正在显示
49 个修改的文件
包含
1131 行增加
和
649 行删除
@@ -12,6 +12,7 @@ | @@ -12,6 +12,7 @@ | ||
12 | "pages/my/chargePhoneNum/chargePhoneNum", | 12 | "pages/my/chargePhoneNum/chargePhoneNum", |
13 | "pages/my/myCard/myCard", | 13 | "pages/my/myCard/myCard", |
14 | "pages/my/groupBuyDetail/groupBuyDetail", | 14 | "pages/my/groupBuyDetail/groupBuyDetail", |
15 | + "pages/my/groupBuyDetail2/groupBuyDetail2", | ||
15 | "pages/my/buyCard/buyCard", | 16 | "pages/my/buyCard/buyCard", |
16 | "pages/my/protocol/protocol", | 17 | "pages/my/protocol/protocol", |
17 | "pages/my/groupBupShare/groupBupShare", | 18 | "pages/my/groupBupShare/groupBupShare", |
@@ -5,68 +5,97 @@ Page({ | @@ -5,68 +5,97 @@ Page({ | ||
5 | * 页面的初始数据 | 5 | * 页面的初始数据 |
6 | */ | 6 | */ |
7 | data: { | 7 | data: { |
8 | - | 8 | + punchState: true, |
9 | + address: '' | ||
9 | }, | 10 | }, |
10 | //打卡申诉 | 11 | //打卡申诉 |
11 | - punchApply(){ | 12 | + punchApply() { |
12 | wx.navigateTo({ | 13 | wx.navigateTo({ |
13 | url: 'punchAppeal/punchAppeal', | 14 | url: 'punchAppeal/punchAppeal', |
14 | }) | 15 | }) |
15 | }, | 16 | }, |
16 | - | 17 | + //打卡 |
18 | + punch() { | ||
19 | + var that = this | ||
20 | + wx.getLocation({ | ||
21 | + type: 'wgs84', | ||
22 | + success: function(res) { | ||
23 | + var latitude = res.latitude | ||
24 | + var longitude = res.longitude | ||
25 | + var speed = res.speed | ||
26 | + var accuracy = res.accuracy | ||
27 | + that.setData({ | ||
28 | + address: '天津市', | ||
29 | + punchState: false | ||
30 | + }) | ||
31 | + }, | ||
32 | + }) | ||
33 | + // wx.chooseLocation({ | ||
34 | + // success: function(res) { | ||
35 | + // console.log(res) | ||
36 | + // var latitude = res.latitude | ||
37 | + // var longitude = res.longitude | ||
38 | + // var address = res.address | ||
39 | + // that.setData({ | ||
40 | + // address: address, | ||
41 | + // punchState:false | ||
42 | + // }) | ||
43 | + // }, | ||
44 | + // }) | ||
45 | + }, | ||
17 | /** | 46 | /** |
18 | * 生命周期函数--监听页面加载 | 47 | * 生命周期函数--监听页面加载 |
19 | */ | 48 | */ |
20 | - onLoad: function (options) { | 49 | + onLoad: function(options) { |
21 | 50 | ||
22 | }, | 51 | }, |
23 | 52 | ||
24 | /** | 53 | /** |
25 | * 生命周期函数--监听页面初次渲染完成 | 54 | * 生命周期函数--监听页面初次渲染完成 |
26 | */ | 55 | */ |
27 | - onReady: function () { | 56 | + onReady: function() { |
28 | 57 | ||
29 | }, | 58 | }, |
30 | 59 | ||
31 | /** | 60 | /** |
32 | * 生命周期函数--监听页面显示 | 61 | * 生命周期函数--监听页面显示 |
33 | */ | 62 | */ |
34 | - onShow: function () { | 63 | + onShow: function() { |
35 | 64 | ||
36 | }, | 65 | }, |
37 | 66 | ||
38 | /** | 67 | /** |
39 | * 生命周期函数--监听页面隐藏 | 68 | * 生命周期函数--监听页面隐藏 |
40 | */ | 69 | */ |
41 | - onHide: function () { | 70 | + onHide: function() { |
42 | 71 | ||
43 | }, | 72 | }, |
44 | 73 | ||
45 | /** | 74 | /** |
46 | * 生命周期函数--监听页面卸载 | 75 | * 生命周期函数--监听页面卸载 |
47 | */ | 76 | */ |
48 | - onUnload: function () { | 77 | + onUnload: function() { |
49 | 78 | ||
50 | }, | 79 | }, |
51 | 80 | ||
52 | /** | 81 | /** |
53 | * 页面相关事件处理函数--监听用户下拉动作 | 82 | * 页面相关事件处理函数--监听用户下拉动作 |
54 | */ | 83 | */ |
55 | - onPullDownRefresh: function () { | 84 | + onPullDownRefresh: function() { |
56 | 85 | ||
57 | }, | 86 | }, |
58 | 87 | ||
59 | /** | 88 | /** |
60 | * 页面上拉触底事件的处理函数 | 89 | * 页面上拉触底事件的处理函数 |
61 | */ | 90 | */ |
62 | - onReachBottom: function () { | 91 | + onReachBottom: function() { |
63 | 92 | ||
64 | }, | 93 | }, |
65 | 94 | ||
66 | /** | 95 | /** |
67 | * 用户点击右上角分享 | 96 | * 用户点击右上角分享 |
68 | */ | 97 | */ |
69 | - onShareAppMessage: function () { | 98 | + onShareAppMessage: function() { |
70 | 99 | ||
71 | } | 100 | } |
72 | }) | 101 | }) |
@@ -3,11 +3,12 @@ | @@ -3,11 +3,12 @@ | ||
3 | <view class='circle_large'> | 3 | <view class='circle_large'> |
4 | <view class='circle_middle'> | 4 | <view class='circle_middle'> |
5 | <view class='circle_small'> | 5 | <view class='circle_small'> |
6 | - <text wx:if='{{}}'>一键打卡</text> | ||
7 | - <text class='iconfont icon-dui'></text> | 6 | + <text wx:if='{{punchState}}' bindtap='punch'>一键打卡</text> |
7 | + <text class='iconfont icon-dui' wx:else></text> | ||
8 | </view> | 8 | </view> |
9 | </view> | 9 | </view> |
10 | </view> | 10 | </view> |
11 | - <view class='punch_info'>当前:未获取</view> | 11 | + <view class='punch_info' wx:if="{{address==''}}">当前:未获取</view> |
12 | + <view class='punch_info' wx:else>当前:{{address}}</view> | ||
12 | <view class='punch_btn' bindtap='punchApply'>打卡申诉</view> | 13 | <view class='punch_btn' bindtap='punchApply'>打卡申诉</view> |
13 | </view> | 14 | </view> |
@@ -42,9 +42,11 @@ | @@ -42,9 +42,11 @@ | ||
42 | font-size: 90rpx; | 42 | font-size: 90rpx; |
43 | } | 43 | } |
44 | .punch_info{ | 44 | .punch_info{ |
45 | + width: 600rpx; | ||
45 | font-size: 32rpx; | 46 | font-size: 32rpx; |
46 | color: #FFFFFF; | 47 | color: #FFFFFF; |
47 | margin-top: 60rpx; | 48 | margin-top: 60rpx; |
49 | + text-align: center; | ||
48 | } | 50 | } |
49 | .punch_btn { | 51 | .punch_btn { |
50 | width: 200rpx; | 52 | width: 200rpx; |
@@ -54,10 +54,10 @@ Page({ | @@ -54,10 +54,10 @@ Page({ | ||
54 | }, | 54 | }, |
55 | }) | 55 | }) |
56 | }, | 56 | }, |
57 | -//跳转申诉详情页 | ||
58 | - listDetail(){ | 57 | + //跳转申诉详情页 |
58 | + listDetail() { | ||
59 | wx.navigateTo({ | 59 | wx.navigateTo({ |
60 | - url:'../punchAppealDetail/punchAppealDetail', | 60 | + url: '../punchAppealDetail/punchAppealDetail', |
61 | }) | 61 | }) |
62 | }, | 62 | }, |
63 | /** | 63 | /** |
@@ -2,6 +2,7 @@ | @@ -2,6 +2,7 @@ | ||
2 | 2 | ||
3 | page { | 3 | page { |
4 | background: #f5f5f5; | 4 | background: #f5f5f5; |
5 | + overflow: hidden; | ||
5 | } | 6 | } |
6 | 7 | ||
7 | .tab_box { | 8 | .tab_box { |
@@ -58,6 +59,7 @@ page { | @@ -58,6 +59,7 @@ page { | ||
58 | width: 100%; | 59 | width: 100%; |
59 | font-size: 28rpx; | 60 | font-size: 28rpx; |
60 | padding: 30rpx; | 61 | padding: 30rpx; |
62 | + box-sizing: border-box; | ||
61 | color: #6e6e6e; | 63 | color: #6e6e6e; |
62 | } | 64 | } |
63 | 65 |
@@ -13,6 +13,20 @@ Page({ | @@ -13,6 +13,20 @@ Page({ | ||
13 | url: '../punchAppealDetail2/punchAppealDetail2', | 13 | url: '../punchAppealDetail2/punchAppealDetail2', |
14 | }) | 14 | }) |
15 | }, | 15 | }, |
16 | + //上传图片 | ||
17 | + uploadImg() { | ||
18 | + wx.chooseImage({ | ||
19 | + success: function (res) { | ||
20 | + console.log(res) | ||
21 | + const tempFilePaths = res.tempFilePaths | ||
22 | + wx.uploadFile({ | ||
23 | + url: '', | ||
24 | + filePath: 'tempFilePaths[0]', | ||
25 | + name: 'file', | ||
26 | + }) | ||
27 | + }, | ||
28 | + }) | ||
29 | + }, | ||
16 | /** | 30 | /** |
17 | * 生命周期函数--监听页面加载 | 31 | * 生命周期函数--监听页面加载 |
18 | */ | 32 | */ |
@@ -7,60 +7,74 @@ Page({ | @@ -7,60 +7,74 @@ Page({ | ||
7 | data: { | 7 | data: { |
8 | 8 | ||
9 | }, | 9 | }, |
10 | + //上传图片 | ||
11 | + uploadImg() { | ||
12 | + wx.chooseImage({ | ||
13 | + success: function(res) { | ||
14 | + console.log(res) | ||
15 | + const tempFilePaths = res.tempFilePaths | ||
16 | + wx.uploadFile({ | ||
17 | + url: '', | ||
18 | + filePath: 'tempFilePaths[0]', | ||
19 | + name: 'file', | ||
20 | + }) | ||
21 | + }, | ||
22 | + }) | ||
23 | + }, | ||
10 | 24 | ||
11 | /** | 25 | /** |
12 | * 生命周期函数--监听页面加载 | 26 | * 生命周期函数--监听页面加载 |
13 | */ | 27 | */ |
14 | - onLoad: function (options) { | 28 | + onLoad: function(options) { |
15 | 29 | ||
16 | }, | 30 | }, |
17 | 31 | ||
18 | /** | 32 | /** |
19 | * 生命周期函数--监听页面初次渲染完成 | 33 | * 生命周期函数--监听页面初次渲染完成 |
20 | */ | 34 | */ |
21 | - onReady: function () { | 35 | + onReady: function() { |
22 | 36 | ||
23 | }, | 37 | }, |
24 | 38 | ||
25 | /** | 39 | /** |
26 | * 生命周期函数--监听页面显示 | 40 | * 生命周期函数--监听页面显示 |
27 | */ | 41 | */ |
28 | - onShow: function () { | 42 | + onShow: function() { |
29 | 43 | ||
30 | }, | 44 | }, |
31 | 45 | ||
32 | /** | 46 | /** |
33 | * 生命周期函数--监听页面隐藏 | 47 | * 生命周期函数--监听页面隐藏 |
34 | */ | 48 | */ |
35 | - onHide: function () { | 49 | + onHide: function() { |
36 | 50 | ||
37 | }, | 51 | }, |
38 | 52 | ||
39 | /** | 53 | /** |
40 | * 生命周期函数--监听页面卸载 | 54 | * 生命周期函数--监听页面卸载 |
41 | */ | 55 | */ |
42 | - onUnload: function () { | 56 | + onUnload: function() { |
43 | 57 | ||
44 | }, | 58 | }, |
45 | 59 | ||
46 | /** | 60 | /** |
47 | * 页面相关事件处理函数--监听用户下拉动作 | 61 | * 页面相关事件处理函数--监听用户下拉动作 |
48 | */ | 62 | */ |
49 | - onPullDownRefresh: function () { | 63 | + onPullDownRefresh: function() { |
50 | 64 | ||
51 | }, | 65 | }, |
52 | 66 | ||
53 | /** | 67 | /** |
54 | * 页面上拉触底事件的处理函数 | 68 | * 页面上拉触底事件的处理函数 |
55 | */ | 69 | */ |
56 | - onReachBottom: function () { | 70 | + onReachBottom: function() { |
57 | 71 | ||
58 | }, | 72 | }, |
59 | 73 | ||
60 | /** | 74 | /** |
61 | * 用户点击右上角分享 | 75 | * 用户点击右上角分享 |
62 | */ | 76 | */ |
63 | - onShareAppMessage: function () { | 77 | + onShareAppMessage: function() { |
64 | 78 | ||
65 | } | 79 | } |
66 | }) | 80 | }) |
@@ -13,14 +13,14 @@ | @@ -13,14 +13,14 @@ | ||
13 | </view> | 13 | </view> |
14 | </view> | 14 | </view> |
15 | 15 | ||
16 | - <view class="jiexi">解析长图</view> | ||
17 | - <view class="footer"> | ||
18 | - <view class="service" bindtap="clickAgreeBtn"> | ||
19 | - <view class="agree_box"> | ||
20 | - <view class="agree_btn" wx:if="{{is_agree}}"></view> | ||
21 | - </view> | ||
22 | - <text>服务协议</text> | ||
23 | - </view> | ||
24 | - <view class="order_btn">去预约</view> | 16 | + <view class="jiexi">解析长图</view> |
17 | + <view class="footer" wx:if="{{is_the_week}}"> | ||
18 | + <view class="service" bindtap="clickAgreeBtn" bindtap='serviceProtocol'> | ||
19 | + <view class="agree_box"> | ||
20 | + <view class="agree_btn" wx:if="{{is_agree}}"></view> | ||
21 | + </view> | ||
22 | + <text>服务协议</text> | ||
25 | </view> | 23 | </view> |
24 | + <view class="order_btn" bindtap='goAppointment'>去预约</view> | ||
25 | + </view> | ||
26 | </view> | 26 | </view> |
@@ -5,131 +5,135 @@ const months = [] | @@ -5,131 +5,135 @@ const months = [] | ||
5 | const days = [] | 5 | const days = [] |
6 | 6 | ||
7 | for (let i = 1990; i <= date.getFullYear(); i++) { | 7 | for (let i = 1990; i <= date.getFullYear(); i++) { |
8 | - years.push(i) | 8 | + years.push(i) |
9 | } | 9 | } |
10 | 10 | ||
11 | -for (let i = 1 ; i <= 12; i++) { | ||
12 | - months.push(i) | 11 | +for (let i = 1; i <= 12; i++) { |
12 | + months.push(i) | ||
13 | } | 13 | } |
14 | 14 | ||
15 | -for (let i = 1 ; i <= 31; i++) { | ||
16 | - days.push(i) | 15 | +for (let i = 1; i <= 31; i++) { |
16 | + days.push(i) | ||
17 | } | 17 | } |
18 | 18 | ||
19 | Page({ | 19 | Page({ |
20 | 20 | ||
21 | - /** | ||
22 | - * 页面的初始数据 | ||
23 | - */ | ||
24 | - data: { | ||
25 | - name: '', | ||
26 | - sex: ['男','女'], | ||
27 | - city: ['北京市','天津市','河北省'], | ||
28 | - years: years, | ||
29 | - year: date.getFullYear(), | ||
30 | - months: months, | ||
31 | - month: 2, | ||
32 | - days: days, | ||
33 | - day: 2, | ||
34 | - value: [9999, 1, 1], | ||
35 | - }, | ||
36 | - inputName(e) { | ||
37 | - this.setData({name: e.detail.value}); | ||
38 | - }, | ||
39 | - //选择性别 | ||
40 | - sexPickerChange: function(e) { | ||
41 | - console.log('picker发送选择改变,携带值为', e.detail.value) | ||
42 | - this.setData({ | ||
43 | - sex_index: e.detail.value, | ||
44 | - is_sex_change: true, | ||
45 | - }) | ||
46 | - }, | ||
47 | - //选择生日 | ||
48 | - birthPickerChange: function(e) { | ||
49 | - console.log('picker发送选择改变,携带值为', e.detail.value) | ||
50 | - this.setData({ | ||
51 | - birth_date: e.detail.value, | ||
52 | - is_birth_change: true, | ||
53 | - }) | ||
54 | - // const val = e.detail.value; | ||
55 | - // this.setData({ | ||
56 | - // year: this.data.years[val[0]], | ||
57 | - // month: this.data.months[val[1]], | ||
58 | - // day: this.data.days[val[2]] | ||
59 | - // }) | ||
60 | - }, | ||
61 | - //选择城市 | ||
62 | - cityPickerChange: function(e) { | ||
63 | - console.log('picker发送选择改变,携带值为', e.detail.value) | ||
64 | - this.setData({ | ||
65 | - city_index: e.detail.value, | ||
66 | - is_city_change: true, | ||
67 | - }) | ||
68 | - }, | ||
69 | - //保存 | ||
70 | - clickSave() { | ||
71 | - if(this.data.name === '') { | ||
72 | - wx.showToast({ | ||
73 | - title: '请填写学员姓名', | ||
74 | - icon: 'none' | ||
75 | - }) | ||
76 | - }else { | ||
77 | - wx.navigateBack({delta: 1}) | ||
78 | - } | ||
79 | - }, | ||
80 | - /** | ||
81 | - * 生命周期函数--监听页面加载 | ||
82 | - */ | ||
83 | - onLoad: function (options) { | ||
84 | - | ||
85 | - }, | ||
86 | - | ||
87 | - /** | ||
88 | - * 生命周期函数--监听页面初次渲染完成 | ||
89 | - */ | ||
90 | - onReady: function () { | ||
91 | - | ||
92 | - }, | ||
93 | - | ||
94 | - /** | ||
95 | - * 生命周期函数--监听页面显示 | ||
96 | - */ | ||
97 | - onShow: function () { | ||
98 | - | ||
99 | - }, | ||
100 | - | ||
101 | - /** | ||
102 | - * 生命周期函数--监听页面隐藏 | ||
103 | - */ | ||
104 | - onHide: function () { | ||
105 | - | ||
106 | - }, | ||
107 | - | ||
108 | - /** | ||
109 | - * 生命周期函数--监听页面卸载 | ||
110 | - */ | ||
111 | - onUnload: function () { | ||
112 | - | ||
113 | - }, | ||
114 | - | ||
115 | - /** | ||
116 | - * 页面相关事件处理函数--监听用户下拉动作 | ||
117 | - */ | ||
118 | - onPullDownRefresh: function () { | ||
119 | - | ||
120 | - }, | ||
121 | - | ||
122 | - /** | ||
123 | - * 页面上拉触底事件的处理函数 | ||
124 | - */ | ||
125 | - onReachBottom: function () { | ||
126 | - | ||
127 | - }, | ||
128 | - | ||
129 | - /** | ||
130 | - * 用户点击右上角分享 | ||
131 | - */ | ||
132 | - onShareAppMessage: function () { | ||
133 | - | 21 | + /** |
22 | + * 页面的初始数据 | ||
23 | + */ | ||
24 | + data: { | ||
25 | + name: '', | ||
26 | + sex: ['男', '女'], | ||
27 | + city: ['北京市', '天津市', '河北省'], | ||
28 | + years: years, | ||
29 | + year: date.getFullYear(), | ||
30 | + months: months, | ||
31 | + month: 2, | ||
32 | + days: days, | ||
33 | + day: 2, | ||
34 | + value: [9999, 1, 1], | ||
35 | + }, | ||
36 | + inputName(e) { | ||
37 | + this.setData({ | ||
38 | + name: e.detail.value | ||
39 | + }); | ||
40 | + }, | ||
41 | + //选择性别 | ||
42 | + sexPickerChange: function(e) { | ||
43 | + console.log('picker发送选择改变,携带值为', e.detail.value) | ||
44 | + this.setData({ | ||
45 | + sex_index: e.detail.value, | ||
46 | + is_sex_change: true, | ||
47 | + }) | ||
48 | + }, | ||
49 | + //选择生日 | ||
50 | + birthPickerChange: function(e) { | ||
51 | + console.log('picker发送选择改变,携带值为', e.detail.value) | ||
52 | + this.setData({ | ||
53 | + birth_date: e.detail.value, | ||
54 | + is_birth_change: true, | ||
55 | + }) | ||
56 | + // const val = e.detail.value; | ||
57 | + // this.setData({ | ||
58 | + // year: this.data.years[val[0]], | ||
59 | + // month: this.data.months[val[1]], | ||
60 | + // day: this.data.days[val[2]] | ||
61 | + // }) | ||
62 | + }, | ||
63 | + //选择城市 | ||
64 | + cityPickerChange: function(e) { | ||
65 | + console.log('picker发送选择改变,携带值为', e.detail.value) | ||
66 | + this.setData({ | ||
67 | + city_index: e.detail.value, | ||
68 | + is_city_change: true, | ||
69 | + }) | ||
70 | + }, | ||
71 | + //保存 | ||
72 | + clickSave() { | ||
73 | + if (this.data.name === '') { | ||
74 | + wx.showToast({ | ||
75 | + title: '请填写学员姓名', | ||
76 | + icon: 'none' | ||
77 | + }) | ||
78 | + } else { | ||
79 | + wx.navigateTo({ | ||
80 | + url: '../../../my/myProfile/myProfile', | ||
81 | + }) | ||
134 | } | 82 | } |
83 | + }, | ||
84 | + /** | ||
85 | + * 生命周期函数--监听页面加载 | ||
86 | + */ | ||
87 | + onLoad: function(options) { | ||
88 | + | ||
89 | + }, | ||
90 | + | ||
91 | + /** | ||
92 | + * 生命周期函数--监听页面初次渲染完成 | ||
93 | + */ | ||
94 | + onReady: function() { | ||
95 | + | ||
96 | + }, | ||
97 | + | ||
98 | + /** | ||
99 | + * 生命周期函数--监听页面显示 | ||
100 | + */ | ||
101 | + onShow: function() { | ||
102 | + | ||
103 | + }, | ||
104 | + | ||
105 | + /** | ||
106 | + * 生命周期函数--监听页面隐藏 | ||
107 | + */ | ||
108 | + onHide: function() { | ||
109 | + | ||
110 | + }, | ||
111 | + | ||
112 | + /** | ||
113 | + * 生命周期函数--监听页面卸载 | ||
114 | + */ | ||
115 | + onUnload: function() { | ||
116 | + | ||
117 | + }, | ||
118 | + | ||
119 | + /** | ||
120 | + * 页面相关事件处理函数--监听用户下拉动作 | ||
121 | + */ | ||
122 | + onPullDownRefresh: function() { | ||
123 | + | ||
124 | + }, | ||
125 | + | ||
126 | + /** | ||
127 | + * 页面上拉触底事件的处理函数 | ||
128 | + */ | ||
129 | + onReachBottom: function() { | ||
130 | + | ||
131 | + }, | ||
132 | + | ||
133 | + /** | ||
134 | + * 用户点击右上角分享 | ||
135 | + */ | ||
136 | + onShareAppMessage: function() { | ||
137 | + | ||
138 | + } | ||
135 | }) | 139 | }) |
@@ -54,57 +54,59 @@ Page({ | @@ -54,57 +54,59 @@ Page({ | ||
54 | */ | 54 | */ |
55 | onLoad: function (options) { | 55 | onLoad: function (options) { |
56 | 56 | ||
57 | - }, | 57 | + }, |
58 | 58 | ||
59 | - /** | ||
60 | - * 生命周期函数--监听页面初次渲染完成 | ||
61 | - */ | ||
62 | - onReady: function () { | 59 | + /** |
60 | + * 生命周期函数--监听页面初次渲染完成 | ||
61 | + */ | ||
62 | + onReady: function() { | ||
63 | 63 | ||
64 | - }, | 64 | + }, |
65 | 65 | ||
66 | - /** | ||
67 | - * 生命周期函数--监听页面显示 | ||
68 | - */ | ||
69 | - onShow: function () { | ||
70 | - const self = this; | ||
71 | - setTimeout(function () { | ||
72 | - self.setData({show: true}) | ||
73 | - },500) | ||
74 | - }, | 66 | + /** |
67 | + * 生命周期函数--监听页面显示 | ||
68 | + */ | ||
69 | + onShow: function() { | ||
70 | + const self = this; | ||
71 | + setTimeout(function() { | ||
72 | + self.setData({ | ||
73 | + show: true | ||
74 | + }) | ||
75 | + }, 500) | ||
76 | + }, | ||
75 | 77 | ||
76 | - /** | ||
77 | - * 生命周期函数--监听页面隐藏 | ||
78 | - */ | ||
79 | - onHide: function () { | 78 | + /** |
79 | + * 生命周期函数--监听页面隐藏 | ||
80 | + */ | ||
81 | + onHide: function() { | ||
80 | 82 | ||
81 | - }, | 83 | + }, |
82 | 84 | ||
83 | - /** | ||
84 | - * 生命周期函数--监听页面卸载 | ||
85 | - */ | ||
86 | - onUnload: function () { | 85 | + /** |
86 | + * 生命周期函数--监听页面卸载 | ||
87 | + */ | ||
88 | + onUnload: function() { | ||
87 | 89 | ||
88 | - }, | 90 | + }, |
89 | 91 | ||
90 | - /** | ||
91 | - * 页面相关事件处理函数--监听用户下拉动作 | ||
92 | - */ | ||
93 | - onPullDownRefresh: function () { | 92 | + /** |
93 | + * 页面相关事件处理函数--监听用户下拉动作 | ||
94 | + */ | ||
95 | + onPullDownRefresh: function() { | ||
94 | 96 | ||
95 | - }, | 97 | + }, |
96 | 98 | ||
97 | - /** | ||
98 | - * 页面上拉触底事件的处理函数 | ||
99 | - */ | ||
100 | - onReachBottom: function () { | 99 | + /** |
100 | + * 页面上拉触底事件的处理函数 | ||
101 | + */ | ||
102 | + onReachBottom: function() { | ||
101 | 103 | ||
102 | - }, | 104 | + }, |
103 | 105 | ||
104 | - /** | ||
105 | - * 用户点击右上角分享 | ||
106 | - */ | ||
107 | - onShareAppMessage: function () { | 106 | + /** |
107 | + * 用户点击右上角分享 | ||
108 | + */ | ||
109 | + onShareAppMessage: function() { | ||
108 | 110 | ||
109 | - } | 111 | + } |
110 | }) | 112 | }) |
1 | <!--pages/index/confirm-appointment-info/confirm-appointment-info.wxml--> | 1 | <!--pages/index/confirm-appointment-info/confirm-appointment-info.wxml--> |
2 | <view class="content"> | 2 | <view class="content"> |
3 | - <view class="tips {{show?'active':''}}"> | ||
4 | - <!--<view>--> | ||
5 | - <view class="iconfont icon-jinggao"></view> | ||
6 | - <text>请在15分钟内确认预约,超时系统将自动取消!</text> | ||
7 | - <!--</view>--> | ||
8 | - </view> | ||
9 | - <view class="time"> | ||
10 | - <view class="line"></view> | ||
11 | - <text>预约时间 : </text> | ||
12 | - <text class="date-time">2018年10月10号 10:00-11:30</text> | ||
13 | - </view> | 3 | + <view class="tips {{show?'active':''}}"> |
4 | + <!--<view>--> | ||
5 | + <view class="iconfont icon-jinggao"></view> | ||
6 | + <text>请在15分钟内确认预约,超时系统将自动取消!</text> | ||
7 | + <!--</view>--> | ||
8 | + </view> | ||
9 | + <view class="time"> | ||
10 | + <view class="line"></view> | ||
11 | + <text>预约时间 : </text> | ||
12 | + <text class="date-time">2018年10月10号 10:00-11:30</text> | ||
13 | + </view> | ||
14 | 14 | ||
15 | - <view class="address"> | ||
16 | - <view class="time"> | ||
17 | - <view class="line"></view> | ||
18 | - <text>预约地址 :</text> | ||
19 | - </view> | ||
20 | - <view class="address-detail"> | ||
21 | - <!--<text>--> | ||
22 | - 朝阳区万寿路5号楼马兰大厦B座301念读书馆内朝阳区读书馆内朝阳区万寿路5号楼马兰大厦B座301念读书万寿路5号楼马兰大厦B座301念读书 | ||
23 | - <!--</text>--> | ||
24 | - </view> | 15 | + <view class="address"> |
16 | + <view class="time"> | ||
17 | + <view class="line"></view> | ||
18 | + <text>预约地址 :</text> | ||
25 | </view> | 19 | </view> |
26 | - <view class="phone-num"> | ||
27 | - <view class="line"></view> | ||
28 | - <text>预约电话 :</text> | ||
29 | - <text class="phone">188****8888</text> | 20 | + <view class="address-detail"> |
21 | + <!--<text>--> | ||
22 | + 朝阳区万寿路5号楼马兰大厦B座301念读书馆内朝阳区读书馆内朝阳区万寿路5号楼马兰大厦B座301念读书万寿路5号楼马兰大厦B座301念读书 | ||
23 | + <!--</text>--> | ||
30 | </view> | 24 | </view> |
31 | - <view class="children-name"> | ||
32 | - <view class="left-name"> | ||
33 | - <view class="line"></view> | ||
34 | - <text>学员姓名</text> | ||
35 | - </view> | ||
36 | - <image src="../../../images/add_btn.png" bindtap="addStudent"></image> | 25 | + </view> |
26 | + <view class="phone-num"> | ||
27 | + <view class="line"></view> | ||
28 | + <text>预约电话 :</text> | ||
29 | + <text class="phone">188****8888</text> | ||
30 | + </view> | ||
31 | + <view class="children-name"> | ||
32 | + <view class="left-name"> | ||
33 | + <view class="line"></view> | ||
34 | + <text>学员姓名</text> | ||
37 | </view> | 35 | </view> |
38 | - <view class="name-box"> | ||
39 | - <view class="check-box" wx:for="{{children}}" wx:key="index" bindtap="chooseChildren" | ||
40 | - data-index="{{index}}"> | ||
41 | - <view class="name {{item.is_choose?'change-color':''}}">{{item.name}}</view> | ||
42 | - <image src="../../../images/choose_icon.png" wx:if="{{item.is_choose}}" class="check-icon"></image> | ||
43 | - </view> | 36 | + <image src="../../../images/add_btn.png" bindtap="addStudent"></image> |
37 | + </view> | ||
38 | + <view class="name-box"> | ||
39 | + <view class="check-box" wx:for="{{children}}" wx:key="index" bindtap="chooseChildren" data-index="{{index}}"> | ||
40 | + <view class="name {{item.is_choose?'change-color':''}}">{{item.name}}</view> | ||
41 | + <image src="../../../images/choose_icon.png" wx:if="{{item.is_choose}}" class="check-icon"></image> | ||
44 | </view> | 42 | </view> |
43 | + </view> | ||
45 | 44 | ||
46 | <view class="footer"> | 45 | <view class="footer"> |
47 | <view class="confirm_btn" bindtap="submit"> | 46 | <view class="confirm_btn" bindtap="submit"> |
@@ -5,122 +5,215 @@ Page({ | @@ -5,122 +5,215 @@ Page({ | ||
5 | * 页面的初始数据 | 5 | * 页面的初始数据 |
6 | */ | 6 | */ |
7 | data: { | 7 | data: { |
8 | - array: ['北京市', '天津市', '上海市', '河北省'], | ||
9 | - currentCity: '北京市', | ||
10 | - is_change: false, | ||
11 | - show_submit_btn: false, | ||
12 | - areaTest: [ | ||
13 | - {area: '朝阳区', list: [{id: 1,name: '798实验室'},{id: 2,name:'木鱼湖实验室'},{id: 3,name:'南锣鼓巷实验室'}]}, | ||
14 | - {area: '东城区', list: [{id: 4,name: '798实验室'},{id: 5,name:'木鱼湖实验室'},{id: 6,name:'南锣鼓巷实验室'}]}, | ||
15 | - {area: '西城区', list: [{id: 7,name: '798实验室'},{id: 11,name:'木鱼湖实验室'},{id: 8,name:'南锣鼓巷实验室'}]}, | ||
16 | - {area: '昌平区', list: [{id: 9,name: '798实验室'},{id: 12,name:'木鱼湖实验室'},{id: 10,name:'南锣鼓巷实验室'}]}, | ||
17 | - ], | ||
18 | - test: {title: '798实验室,本实验室分为三个阶段,第一阶段由家长和孩子共同完成,第二阶段由孩子独立完成。家长在旁边指导,第三阶段巴拉巴拉', | ||
19 | - list:[{week:'周六',date: '10月20日',time:'10:00 — 11:30',rest: 6}, | ||
20 | - {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 0}, | ||
21 | - {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
22 | - {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 0}, | ||
23 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
24 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
25 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
26 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
27 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
28 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
29 | - // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
30 | - // {week:'周六',date: '10月20日',time:'10:00 — 11:30',rest: 6} | ||
31 | - ]}, | ||
32 | - }, | ||
33 | - //选择城市 | ||
34 | - bindPickerChange: function(e) { | ||
35 | - console.log('picker发送选择改变,携带值为', e.detail.value) | ||
36 | - this.setData({ | ||
37 | - index: e.detail.value, | ||
38 | - is_change: true, | ||
39 | - }) | ||
40 | - }, | ||
41 | - //选择实验室 | ||
42 | - chooseTest(e) { | ||
43 | - console.log(e.currentTarget.dataset.index); | ||
44 | - const current = e.currentTarget.dataset.index; | ||
45 | - const current_id = e.currentTarget.dataset.id; | ||
46 | - this.setData({currentTest: current,currentId: current_id}) | ||
47 | - }, | ||
48 | - //选择时段 | ||
49 | - chooseTime(e) { | ||
50 | - console.log(e.currentTarget.dataset.index); | ||
51 | - const current = e.currentTarget.dataset.index; | ||
52 | - this.setData({currentTime: current}) | ||
53 | - }, | ||
54 | - //点击单人预约 | ||
55 | - singleAppointment() { | ||
56 | - this.setData({show_submit_btn: true}) | ||
57 | - }, | ||
58 | - //点击双人预约 | ||
59 | - doubleAppointment() { | ||
60 | - this.setData({show_submit_btn: true}) | ||
61 | - }, | ||
62 | - submit() { | ||
63 | - wx.navigateTo({url: '/pages/index/confirm-appointment-info/confirm-appointment-info'}) | 8 | + array: ['北京市', '天津市', '上海市', '河北省'], |
9 | + currentCity: '北京市', | ||
10 | + is_change: false, | ||
11 | + show_submit_btn: false, | ||
12 | + areaTest: [{ | ||
13 | + area: '朝阳区', | ||
14 | + list: [{ | ||
15 | + id: 1, | ||
16 | + name: '798实验室' | ||
17 | + }, { | ||
18 | + id: 2, | ||
19 | + name: '木鱼湖实验室' | ||
20 | + }, { | ||
21 | + id: 3, | ||
22 | + name: '南锣鼓巷实验室' | ||
23 | + }] | ||
24 | + }, | ||
25 | + { | ||
26 | + area: '东城区', | ||
27 | + list: [{ | ||
28 | + id: 4, | ||
29 | + name: '798实验室' | ||
30 | + }, { | ||
31 | + id: 5, | ||
32 | + name: '木鱼湖实验室' | ||
33 | + }, { | ||
34 | + id: 6, | ||
35 | + name: '南锣鼓巷实验室' | ||
36 | + }] | ||
37 | + }, | ||
38 | + { | ||
39 | + area: '西城区', | ||
40 | + list: [{ | ||
41 | + id: 7, | ||
42 | + name: '798实验室' | ||
43 | + }, { | ||
44 | + id: 11, | ||
45 | + name: '木鱼湖实验室' | ||
46 | + }, { | ||
47 | + id: 8, | ||
48 | + name: '南锣鼓巷实验室' | ||
49 | + }] | ||
50 | + }, | ||
51 | + { | ||
52 | + area: '昌平区', | ||
53 | + list: [{ | ||
54 | + id: 9, | ||
55 | + name: '798实验室' | ||
56 | + }, { | ||
57 | + id: 12, | ||
58 | + name: '木鱼湖实验室' | ||
59 | + }, { | ||
60 | + id: 10, | ||
61 | + name: '南锣鼓巷实验室' | ||
62 | + }] | ||
63 | + }, | ||
64 | + ], | ||
65 | + test: { | ||
66 | + title: '798实验室,本实验室分为三个阶段,第一阶段由家长和孩子共同完成,第二阶段由孩子独立完成。家长在旁边指导,第三阶段巴拉巴拉', | ||
67 | + list: [{ | ||
68 | + week: '周六', | ||
69 | + date: '10月20日', | ||
70 | + time: '10:00 — 11:30', | ||
71 | + rest: 6 | ||
72 | + }, | ||
73 | + { | ||
74 | + week: '周日', | ||
75 | + date: '10月21日', | ||
76 | + time: '15:00 — 16:30', | ||
77 | + rest: 0 | ||
78 | + }, | ||
79 | + { | ||
80 | + week: '周日', | ||
81 | + date: '10月21日', | ||
82 | + time: '15:00 — 16:30', | ||
83 | + rest: 6 | ||
84 | + }, | ||
85 | + { | ||
86 | + week: '周日', | ||
87 | + date: '10月21日', | ||
88 | + time: '15:00 — 16:30', | ||
89 | + rest: 0 | ||
90 | + }, | ||
91 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
92 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
93 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
94 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
95 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
96 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
97 | + // {week:'周日',date: '10月21日',time:'15:00 — 16:30',rest: 6}, | ||
98 | + // {week:'周六',date: '10月20日',time:'10:00 — 11:30',rest: 6} | ||
99 | + ] | ||
64 | }, | 100 | }, |
101 | + }, | ||
102 | + | ||
103 | + //选择城市 | ||
104 | + bindPickerChange: function(e) { | ||
105 | + console.log('picker发送选择改变,携带值为', e.detail.value) | ||
106 | + this.setData({ | ||
107 | + index: e.detail.value, | ||
108 | + is_change: true, | ||
109 | + }) | ||
110 | + }, | ||
111 | + | ||
112 | + //选择实验室 | ||
113 | + chooseTest(e) { | ||
114 | + console.log(e.currentTarget.dataset.index); | ||
115 | + const current = e.currentTarget.dataset.index; | ||
116 | + const current_id = e.currentTarget.dataset.id; | ||
117 | + this.setData({ | ||
118 | + currentTest: current, | ||
119 | + currentId: current_id | ||
120 | + }) | ||
121 | + }, | ||
122 | + | ||
123 | + //选择时段 | ||
124 | + chooseTime(e) { | ||
125 | + console.log(e.currentTarget.dataset.index); | ||
126 | + const current = e.currentTarget.dataset.index; | ||
127 | + this.setData({ | ||
128 | + currentTime: current | ||
129 | + }) | ||
130 | + }, | ||
131 | + | ||
132 | + //点击单人预约 | ||
133 | + singleAppointment() { | ||
134 | + // this.setData({ | ||
135 | + // show_submit_btn: true | ||
136 | + // }) | ||
137 | + wx.navigateTo({ | ||
138 | + url: '/pages/index/confirm-appointment-info/confirm-appointment-info' | ||
139 | + }) | ||
140 | + }, | ||
141 | + | ||
142 | + //点击双人预约 | ||
143 | + doubleAppointment() { | ||
144 | + // this.setData({ | ||
145 | + // show_submit_btn: true | ||
146 | + // }) | ||
147 | + wx.navigateTo({ | ||
148 | + url: '/pages/index/confirm-appointment-info/confirm-appointment-info' | ||
149 | + }) | ||
150 | + }, | ||
151 | + | ||
152 | + submit() { | ||
153 | + wx.navigateTo({ | ||
154 | + url: '/pages/index/confirm-appointment-info/confirm-appointment-info' | ||
155 | + }) | ||
156 | + }, | ||
157 | + | ||
65 | /** | 158 | /** |
66 | * 生命周期函数--监听页面加载 | 159 | * 生命周期函数--监听页面加载 |
67 | */ | 160 | */ |
68 | - onLoad: function (options) { | ||
69 | - this.data.areaTest.forEach((v,i)=>{ | ||
70 | - Object.keys(v).forEach(v=>{ | ||
71 | - console.log(v)//取到了key | ||
72 | - console.log(this.data.areaTest[i][v])//取到了值 | ||
73 | - }) | 161 | + onLoad: function(options) { |
162 | + this.data.areaTest.forEach((v, i) => { | ||
163 | + Object.keys(v).forEach(v => { | ||
164 | + console.log(v) //取到了key | ||
165 | + console.log(this.data.areaTest[i][v]) //取到了值 | ||
74 | }) | 166 | }) |
75 | - // console.log(this.data.areaTest); | 167 | + }) |
168 | + // console.log(this.data.areaTest); | ||
76 | }, | 169 | }, |
77 | 170 | ||
78 | /** | 171 | /** |
79 | * 生命周期函数--监听页面初次渲染完成 | 172 | * 生命周期函数--监听页面初次渲染完成 |
80 | */ | 173 | */ |
81 | - onReady: function () { | 174 | + onReady: function() { |
82 | 175 | ||
83 | }, | 176 | }, |
84 | 177 | ||
85 | /** | 178 | /** |
86 | * 生命周期函数--监听页面显示 | 179 | * 生命周期函数--监听页面显示 |
87 | */ | 180 | */ |
88 | - onShow: function () { | 181 | + onShow: function() { |
89 | 182 | ||
90 | }, | 183 | }, |
91 | 184 | ||
92 | /** | 185 | /** |
93 | * 生命周期函数--监听页面隐藏 | 186 | * 生命周期函数--监听页面隐藏 |
94 | */ | 187 | */ |
95 | - onHide: function () { | 188 | + onHide: function() { |
96 | 189 | ||
97 | }, | 190 | }, |
98 | 191 | ||
99 | /** | 192 | /** |
100 | * 生命周期函数--监听页面卸载 | 193 | * 生命周期函数--监听页面卸载 |
101 | */ | 194 | */ |
102 | - onUnload: function () { | 195 | + onUnload: function() { |
103 | 196 | ||
104 | }, | 197 | }, |
105 | 198 | ||
106 | /** | 199 | /** |
107 | * 页面相关事件处理函数--监听用户下拉动作 | 200 | * 页面相关事件处理函数--监听用户下拉动作 |
108 | */ | 201 | */ |
109 | - onPullDownRefresh: function () { | 202 | + onPullDownRefresh: function() { |
110 | 203 | ||
111 | }, | 204 | }, |
112 | 205 | ||
113 | /** | 206 | /** |
114 | * 页面上拉触底事件的处理函数 | 207 | * 页面上拉触底事件的处理函数 |
115 | */ | 208 | */ |
116 | - onReachBottom: function () { | 209 | + onReachBottom: function() { |
117 | 210 | ||
118 | }, | 211 | }, |
119 | 212 | ||
120 | /** | 213 | /** |
121 | * 用户点击右上角分享 | 214 | * 用户点击右上角分享 |
122 | */ | 215 | */ |
123 | - onShareAppMessage: function () { | 216 | + onShareAppMessage: function() { |
124 | 217 | ||
125 | } | 218 | } |
126 | }) | 219 | }) |
@@ -33,6 +33,7 @@ Page({ | @@ -33,6 +33,7 @@ Page({ | ||
33 | currentSwiper: e.detail.current | 33 | currentSwiper: e.detail.current |
34 | }) | 34 | }) |
35 | }, | 35 | }, |
36 | + //首次登录小程序,跳转到认证手机页面 | ||
36 | goPhoneCode() { | 37 | goPhoneCode() { |
37 | wx.navigateTo({url: '/pages/index/phone-code/phone-code'}) | 38 | wx.navigateTo({url: '/pages/index/phone-code/phone-code'}) |
38 | }, | 39 | }, |
1 | <!--index.wxml--> | 1 | <!--index.wxml--> |
2 | <view class="container"> | 2 | <view class="container"> |
3 | <!--蒙层--> | 3 | <!--蒙层--> |
4 | - <view class="modal" wx:if="{{!hasPhone}}" bindtap="goPhoneCode"></view> | 4 | + <view class="modal" wx:if="{{!hasPhone}}" bindtap="goPhoneCode"></view> |
5 | 5 | ||
6 | - <!--轮播图--> | 6 | + <!--轮播图--> |
7 | <view class="wrap"> | 7 | <view class="wrap"> |
8 | - <swiper autoplay="{{autoplay}}" interval="{{interval}}" duration="{{duration}}" circular="true" | ||
9 | - bindchange="swiperChange"> | 8 | + <swiper autoplay="{{autoplay}}" interval="{{interval}}" duration="{{duration}}" circular="true" bindchange="swiperChange"> |
10 | <block wx:for="{{imgUrls}}" wx:key="index"> | 9 | <block wx:for="{{imgUrls}}" wx:key="index"> |
11 | <swiper-item> | 10 | <swiper-item> |
12 | <navigator url="{{item.url}}" hover-class="navigator-hover"> | 11 | <navigator url="{{item.url}}" hover-class="navigator-hover"> |
13 | <view class="index_top"> | 12 | <view class="index_top"> |
14 | - <image src="{{item.url}}" class="slide-image" mode="aspectFill"/> | 13 | + <image src="{{item.url}}" class="slide-image" mode="aspectFill" /> |
15 | </view> | 14 | </view> |
16 | </navigator> | 15 | </navigator> |
17 | </swiper-item> | 16 | </swiper-item> |
@@ -24,17 +23,59 @@ | @@ -24,17 +23,59 @@ | ||
24 | </view> | 23 | </view> |
25 | </view> | 24 | </view> |
26 | 25 | ||
27 | - <!--购买--> | 26 | + <!--购买--> |
28 | <view class="btn-box" bindtap="goBuyCard"> | 27 | <view class="btn-box" bindtap="goBuyCard"> |
29 | <view class="buy-btn"> | 28 | <view class="buy-btn"> |
30 | <text>点击图片可跳转到购买页</text> | 29 | <text>点击图片可跳转到购买页</text> |
31 | </view> | 30 | </view> |
32 | </view> | 31 | </view> |
33 | 32 | ||
34 | - <!--实验列表--> | ||
35 | - <import src="/templates/templates.wxml" /> | ||
36 | - <view class="past_template"> | ||
37 | - <template is="this-experiment" data="{{this_week_test_info}}"></template> | ||
38 | - <template is="past-experiment" data="{{...past_test_info}}"></template> | 33 | + <!--实验列表--> |
34 | + <!--<import src="/templates/templates.wxml" />--> | ||
35 | + <!--<view class="past_template">--> | ||
36 | + <!--<template is="experiment" data="{{...this_week_test_info}}"></template>--> | ||
37 | + <!--<template is="experiment" data="{{...past_test_info}}"></template>--> | ||
38 | + <!--</view>--> | ||
39 | + <!-- <import src="/templates/templates.wxml" /> --> | ||
40 | + <view class="past_template"> | ||
41 | + <!-- <template is="experiment" data="{{...this_week_test_info}}"></template> | ||
42 | + <template is="experiment" data="{{...past_test_info}}"></template> --> | ||
43 | + <view class='experiment_box'> | ||
44 | + <view class="title_box"> | ||
45 | + <view class="line"></view> | ||
46 | + <text>本周实验</text> | ||
47 | + <!-- <text>往期实验</text> --> | ||
48 | + </view> | ||
49 | + <view wx:for="{{info}}" wx:key="index" data-index="{{index}}" bindtap="goTestDetail" data-is_the_week='{{true}}'> | ||
50 | + <view class="test_box"> | ||
51 | + <view class="time">{{item.time}}</view> | ||
52 | + <view class="img_box"> | ||
53 | + <image src="{{item.url}}"></image> | ||
54 | + </view> | ||
55 | + </view> | ||
56 | + <view class="order_box"> | ||
57 | + <text catchtap="goAppointment" data-index="{{index}}">前往预约</text> | ||
58 | + </view> | ||
59 | + </view> | ||
39 | </view> | 60 | </view> |
40 | -</view> | 61 | + |
62 | + | ||
63 | + <view class='experiment_box'> | ||
64 | + <view class="title_box" bindtap="goTestDetail" data-is_the_week='{{false}}'> | ||
65 | + <view class="line"></view> | ||
66 | + <text>往期实验</text> | ||
67 | + </view> | ||
68 | + <view wx:for="{{info}}" wx:key="index" data-index="{{index}}" bindtap="goTestDetail" data-is_the_week='{{false}}'> | ||
69 | + <view class="test_box"> | ||
70 | + <view class="time">{{item.time}}</view> | ||
71 | + <view class="img_box"> | ||
72 | + <image src="{{item.url}}"></image> | ||
73 | + </view> | ||
74 | + </view> | ||
75 | + <view class="order_box"> | ||
76 | + <text>查看</text> | ||
77 | + </view> | ||
78 | + </view> | ||
79 | + </view> | ||
80 | + </view> | ||
81 | +</view> |
@@ -6,88 +6,94 @@ Page({ | @@ -6,88 +6,94 @@ Page({ | ||
6 | * 页面的初始数据 | 6 | * 页面的初始数据 |
7 | */ | 7 | */ |
8 | data: { | 8 | data: { |
9 | - fun_id: 2, | ||
10 | - time: '获取验证码', //倒计时 | ||
11 | - currentTime: 61 | 9 | + fun_id: 2, |
10 | + time: '获取验证码', //倒计时 | ||
11 | + currentTime: 61 | ||
12 | }, | 12 | }, |
13 | - getCode: function (options) { | ||
14 | - var that = this; | ||
15 | - var currentTime = that.data.currentTime; | ||
16 | - interval = setInterval(function () { | ||
17 | - currentTime--; | ||
18 | - that.setData({ | ||
19 | - time: currentTime + '秒' | ||
20 | - }) | ||
21 | - if (currentTime <= 0) { | ||
22 | - clearInterval(interval); | ||
23 | - that.setData({ | ||
24 | - time: '重新发送', | ||
25 | - currentTime: 61, | ||
26 | - disabled: false | ||
27 | - }) | ||
28 | - } | ||
29 | - }, 1000) | ||
30 | - }, | ||
31 | - getVerificationCode() { | ||
32 | - this.getCode(); | ||
33 | - var that = this; | 13 | + getCode: function(options) { |
14 | + var that = this; | ||
15 | + var currentTime = that.data.currentTime; | ||
16 | + interval = setInterval(function() { | ||
17 | + currentTime--; | ||
34 | that.setData({ | 18 | that.setData({ |
35 | - disabled: true | 19 | + time: currentTime + '秒' |
36 | }) | 20 | }) |
21 | + if (currentTime <= 0) { | ||
22 | + clearInterval(interval); | ||
23 | + that.setData({ | ||
24 | + time: '重新发送', | ||
25 | + currentTime: 61, | ||
26 | + disabled: false | ||
27 | + }) | ||
28 | + } | ||
29 | + }, 1000) | ||
30 | + }, | ||
31 | + getVerificationCode() { | ||
32 | + this.getCode(); | ||
33 | + var that = this; | ||
34 | + that.setData({ | ||
35 | + disabled: true | ||
36 | + }) | ||
37 | + }, | ||
38 | + //确认 | ||
39 | + confirm() { | ||
40 | + wx.switchTab({ | ||
41 | + url: '../../index/index' | ||
42 | + }) | ||
37 | }, | 43 | }, |
38 | /** | 44 | /** |
39 | * 生命周期函数--监听页面加载 | 45 | * 生命周期函数--监听页面加载 |
40 | */ | 46 | */ |
41 | - onLoad: function (options) { | 47 | + onLoad: function(options) { |
42 | 48 | ||
43 | }, | 49 | }, |
44 | 50 | ||
45 | /** | 51 | /** |
46 | * 生命周期函数--监听页面初次渲染完成 | 52 | * 生命周期函数--监听页面初次渲染完成 |
47 | */ | 53 | */ |
48 | - onReady: function () { | 54 | + onReady: function() { |
49 | 55 | ||
50 | }, | 56 | }, |
51 | 57 | ||
52 | /** | 58 | /** |
53 | * 生命周期函数--监听页面显示 | 59 | * 生命周期函数--监听页面显示 |
54 | */ | 60 | */ |
55 | - onShow: function () { | 61 | + onShow: function() { |
56 | 62 | ||
57 | }, | 63 | }, |
58 | 64 | ||
59 | /** | 65 | /** |
60 | * 生命周期函数--监听页面隐藏 | 66 | * 生命周期函数--监听页面隐藏 |
61 | */ | 67 | */ |
62 | - onHide: function () { | 68 | + onHide: function() { |
63 | 69 | ||
64 | }, | 70 | }, |
65 | 71 | ||
66 | /** | 72 | /** |
67 | * 生命周期函数--监听页面卸载 | 73 | * 生命周期函数--监听页面卸载 |
68 | */ | 74 | */ |
69 | - onUnload: function () { | 75 | + onUnload: function() { |
70 | 76 | ||
71 | }, | 77 | }, |
72 | 78 | ||
73 | /** | 79 | /** |
74 | * 页面相关事件处理函数--监听用户下拉动作 | 80 | * 页面相关事件处理函数--监听用户下拉动作 |
75 | */ | 81 | */ |
76 | - onPullDownRefresh: function () { | 82 | + onPullDownRefresh: function() { |
77 | 83 | ||
78 | }, | 84 | }, |
79 | 85 | ||
80 | /** | 86 | /** |
81 | * 页面上拉触底事件的处理函数 | 87 | * 页面上拉触底事件的处理函数 |
82 | */ | 88 | */ |
83 | - onReachBottom: function () { | 89 | + onReachBottom: function() { |
84 | 90 | ||
85 | }, | 91 | }, |
86 | 92 | ||
87 | /** | 93 | /** |
88 | * 用户点击右上角分享 | 94 | * 用户点击右上角分享 |
89 | */ | 95 | */ |
90 | - onShareAppMessage: function () { | 96 | + onShareAppMessage: function() { |
91 | 97 | ||
92 | } | 98 | } |
93 | }) | 99 | }) |
@@ -19,7 +19,7 @@ Page({ | @@ -19,7 +19,7 @@ Page({ | ||
19 | * 生命周期函数--监听页面加载 | 19 | * 生命周期函数--监听页面加载 |
20 | */ | 20 | */ |
21 | onLoad: function (options) { | 21 | onLoad: function (options) { |
22 | - | 22 | + this.setData({currentTab: +options.currentTab}) |
23 | }, | 23 | }, |
24 | 24 | ||
25 | /** | 25 | /** |
@@ -33,7 +33,7 @@ Page({ | @@ -33,7 +33,7 @@ Page({ | ||
33 | * 生命周期函数--监听页面显示 | 33 | * 生命周期函数--监听页面显示 |
34 | */ | 34 | */ |
35 | onShow: function () { | 35 | onShow: function () { |
36 | - | 36 | + console.log('show',this.data.currentTab) |
37 | }, | 37 | }, |
38 | 38 | ||
39 | /** | 39 | /** |
1 | <!--pages/my/all-appointment/all-appointment.wxml--> | 1 | <!--pages/my/all-appointment/all-appointment.wxml--> |
2 | <view class="content"> | 2 | <view class="content"> |
3 | - <!--tab--> | ||
4 | - <view class="tab-box"> | ||
5 | - <view wx:for="{{tab}}" wx:key="index" bindtap="changeTab" data-index="{{index}}" | ||
6 | - class="{{currentTab == index?'change-color':''}}">{{item}}</view> | ||
7 | - </view> | ||
8 | - | ||
9 | - <!--预约列表--> | ||
10 | - <view class="list-box"> | ||
11 | - <view class="order-box"> | ||
12 | - | ||
13 | - <view class="head"> | ||
14 | - <text class="number">预约单号:000120180208</text> | ||
15 | - <text class="appointment-state" wx:if="{{currentTab === 1}}" style="color: #FC5B63;">待确认</text> | ||
16 | - <text class="appointment-state" wx:if="{{currentTab === 2}}">已预约</text> | ||
17 | - <text class="appointment-state" wx:if="{{currentTab === 3}}" style="color: #464646;">已取消</text> | ||
18 | - <text class="appointment-state" wx:if="{{currentTab === 4}}" style="color: #C3C3C3;">已结束</text> | ||
19 | - </view> | ||
20 | - | ||
21 | - <view class="section"> | ||
22 | - <image src="../../../images/red_line.png" wx:if="{{currentTab === 1}}" class="blue-line"></image> | ||
23 | - <image src="../../../images/blue_line.png" wx:if="{{currentTab === 2}}" class="blue-line"></image> | ||
24 | - <image src="../../../images/deep_grey_line.png" wx:if="{{currentTab === 3}}" class="blue-line"></image> | ||
25 | - <image src="../../../images/grey_line.png" wx:if="{{currentTab === 4}}" class="blue-line"></image> | ||
26 | - | ||
27 | - <view class="right-box"> | ||
28 | - <view class="right-top-box"> | ||
29 | - <view class="iconfont icon-dingwei"></view> | ||
30 | - <view class="address">北京市朝阳区万寿路马兰大厦B座北京市朝阳区万寿路马兰大厦B座</view> | ||
31 | - </view> | ||
32 | - | ||
33 | - <view class="right-bottom-box"> | ||
34 | - <view class="iconfont icon-shangwutubiao"></view> | ||
35 | - <view class="date-box"> | ||
36 | - <view class="date">预约日期:2018.09.02 10:00-11:30</view> | ||
37 | - | ||
38 | - <view class="not_confirm" wx:if="{{currentTab === 1}}"> | ||
39 | - <view class="go-cancel">取消</view> | ||
40 | - <view class="go-confirm">去确认</view> | ||
41 | - </view> | ||
42 | - <view class="cancel" wx:if="{{currentTab === 2}}">取消</view> | ||
43 | - <view class="iconfont icon-quxiao" wx:if="{{currentTab === 3}}"></view> | ||
44 | - <view class="iconfont icon-jieshu" wx:if="{{currentTab === 4}}"></view> | ||
45 | - </view> | ||
46 | - </view> | ||
47 | - </view> | 3 | + <!--tab--> |
4 | + <view class="tab-box"> | ||
5 | + <view wx:for="{{tab}}" wx:key="index" bindtap="changeTab" data-index="{{index}}" class="{{currentTab == index?'change-color':''}}">{{item}}</view> | ||
6 | + </view> | ||
7 | + | ||
8 | + <!--预约列表--> | ||
9 | + <view class="list-box"> | ||
10 | + <view class="order-box"> | ||
11 | + | ||
12 | + <view class="head"> | ||
13 | + <text class="number">预约单号:000120180208</text> | ||
14 | + <text class="appointment-state" wx:if="{{currentTab === 1}}" style="color: #FC5B63;">待确认</text> | ||
15 | + <text class="appointment-state" wx:if="{{currentTab === 2}}">已预约</text> | ||
16 | + <text class="appointment-state" wx:if="{{currentTab === 3}}" style="color: #464646;">已取消</text> | ||
17 | + <text class="appointment-state" wx:if="{{currentTab === 4}}" style="color: #C3C3C3;">已结束</text> | ||
18 | + </view> | ||
19 | + | ||
20 | + <view class="section"> | ||
21 | + <image src="../../../images/red_line.png" wx:if="{{currentTab === 1}}" class="blue-line"></image> | ||
22 | + <image src="../../../images/blue_line.png" wx:if="{{currentTab === 2}}" class="blue-line"></image> | ||
23 | + <image src="../../../images/deep_grey_line.png" wx:if="{{currentTab === 3}}" class="blue-line"></image> | ||
24 | + <image src="../../../images/grey_line.png" wx:if="{{currentTab === 4}}" class="blue-line"></image> | ||
25 | + | ||
26 | + <view class="right-box"> | ||
27 | + <view class="right-top-box"> | ||
28 | + <view class="iconfont icon-dingwei"></view> | ||
29 | + <view class="address">北京市朝阳区万寿路马兰大厦B座北京市朝阳区万寿路马兰大厦B座</view> | ||
30 | + </view> | ||
31 | + | ||
32 | + <view class="right-bottom-box"> | ||
33 | + <view class="iconfont icon-shangwutubiao"></view> | ||
34 | + <view class="date-box"> | ||
35 | + <view class="date">预约日期:2018.09.02 10:00-11:30</view> | ||
36 | + | ||
37 | + <view class="not_confirm" wx:if="{{currentTab === 1}}"> | ||
38 | + <view class="go-cancel">取消</view> | ||
39 | + <view class="go-confirm">去确认</view> | ||
40 | + </view> | ||
41 | + <view class="cancel" wx:if="{{currentTab === 2}}">取消</view> | ||
42 | + <view class="iconfont icon-quxiao" wx:if="{{currentTab === 3}}"></view> | ||
43 | + <view class="iconfont icon-jieshu" wx:if="{{currentTab === 4}}"></view> | ||
48 | </view> | 44 | </view> |
45 | + </view> | ||
46 | + </view> | ||
47 | + </view> | ||
49 | 48 | ||
50 | 49 | ||
51 | - </view> | ||
52 | </view> | 50 | </view> |
51 | + </view> | ||
53 | </view> | 52 | </view> |
@@ -15,11 +15,11 @@ page { | @@ -15,11 +15,11 @@ page { | ||
15 | -moz-box-sizing: border-box; | 15 | -moz-box-sizing: border-box; |
16 | box-sizing: border-box; | 16 | box-sizing: border-box; |
17 | background-color: #fff; | 17 | background-color: #fff; |
18 | - /*border-bottom: 4rpx solid #3FA9F5;*/ | 18 | + /* border-bottom: 1rpx solid #ebebeb; */ |
19 | } | 19 | } |
20 | .tab-box view { | 20 | .tab-box view { |
21 | line-height: 80rpx; | 21 | line-height: 80rpx; |
22 | - /*position: relative;*/ | 22 | + position: relative; |
23 | } | 23 | } |
24 | .change-color { | 24 | .change-color { |
25 | color: #3FA9F5; | 25 | color: #3FA9F5; |
@@ -7,67 +7,97 @@ Page({ | @@ -7,67 +7,97 @@ Page({ | ||
7 | data: { | 7 | data: { |
8 | userlist: ['张三', '里斯'], | 8 | userlist: ['张三', '里斯'], |
9 | index: -1, | 9 | index: -1, |
10 | + pay_success: false, | ||
10 | }, | 11 | }, |
11 | //选择成员 | 12 | //选择成员 |
12 | userList(e) { | 13 | userList(e) { |
13 | this.setData({ | 14 | this.setData({ |
14 | index: e.detail.value | 15 | index: e.detail.value |
15 | }) | 16 | }) |
16 | - | 17 | + }, |
18 | + //添加学员 | ||
19 | + addUser() { | ||
20 | + wx.navigateTo({ | ||
21 | + url: '../../index/confirm-appointment-info/add-student/add-student', | ||
22 | + }) | ||
23 | + }, | ||
24 | + //服务协议 | ||
25 | + serviceProtocol() { | ||
26 | + wx.navigateTo({ | ||
27 | + url: '../protocol/protocol', | ||
28 | + }) | ||
29 | + }, | ||
30 | + //确认支付 | ||
31 | + confirmPay() { | ||
32 | + this.setData({pay_success: true}); | ||
33 | + this.changeState(); | ||
34 | + wx.navigateBack({ | ||
35 | + delta: 1 | ||
36 | + }) | ||
37 | + }, | ||
38 | + //更新上一页面的购买状态 | ||
39 | + changeState() { | ||
40 | + var pages = getCurrentPages(); | ||
41 | + if(pages.length > 1) { | ||
42 | + var beforePage = pages[pages.length - 2]//获取上一页面实例 | ||
43 | + if(this.data.pay_success) { | ||
44 | + beforePage.refreshModal() | ||
45 | + } | ||
46 | + } | ||
17 | }, | 47 | }, |
18 | /** | 48 | /** |
19 | * 生命周期函数--监听页面加载 | 49 | * 生命周期函数--监听页面加载 |
20 | */ | 50 | */ |
21 | - onLoad: function (options) { | 51 | + onLoad: function(options) { |
22 | 52 | ||
23 | }, | 53 | }, |
24 | 54 | ||
25 | /** | 55 | /** |
26 | * 生命周期函数--监听页面初次渲染完成 | 56 | * 生命周期函数--监听页面初次渲染完成 |
27 | */ | 57 | */ |
28 | - onReady: function () { | 58 | + onReady: function() { |
29 | 59 | ||
30 | }, | 60 | }, |
31 | 61 | ||
32 | /** | 62 | /** |
33 | * 生命周期函数--监听页面显示 | 63 | * 生命周期函数--监听页面显示 |
34 | */ | 64 | */ |
35 | - onShow: function () { | 65 | + onShow: function() { |
36 | 66 | ||
37 | }, | 67 | }, |
38 | 68 | ||
39 | /** | 69 | /** |
40 | * 生命周期函数--监听页面隐藏 | 70 | * 生命周期函数--监听页面隐藏 |
41 | */ | 71 | */ |
42 | - onHide: function () { | 72 | + onHide: function() { |
43 | 73 | ||
44 | }, | 74 | }, |
45 | 75 | ||
46 | /** | 76 | /** |
47 | * 生命周期函数--监听页面卸载 | 77 | * 生命周期函数--监听页面卸载 |
48 | */ | 78 | */ |
49 | - onUnload: function () { | 79 | + onUnload: function() { |
50 | 80 | ||
51 | }, | 81 | }, |
52 | 82 | ||
53 | /** | 83 | /** |
54 | * 页面相关事件处理函数--监听用户下拉动作 | 84 | * 页面相关事件处理函数--监听用户下拉动作 |
55 | */ | 85 | */ |
56 | - onPullDownRefresh: function () { | 86 | + onPullDownRefresh: function() { |
57 | 87 | ||
58 | }, | 88 | }, |
59 | 89 | ||
60 | /** | 90 | /** |
61 | * 页面上拉触底事件的处理函数 | 91 | * 页面上拉触底事件的处理函数 |
62 | */ | 92 | */ |
63 | - onReachBottom: function () { | 93 | + onReachBottom: function() { |
64 | 94 | ||
65 | }, | 95 | }, |
66 | 96 | ||
67 | /** | 97 | /** |
68 | * 用户点击右上角分享 | 98 | * 用户点击右上角分享 |
69 | */ | 99 | */ |
70 | - onShareAppMessage: function () { | 100 | + onShareAppMessage: function() { |
71 | 101 | ||
72 | } | 102 | } |
73 | }) | 103 | }) |
@@ -14,7 +14,7 @@ | @@ -14,7 +14,7 @@ | ||
14 | </picker> | 14 | </picker> |
15 | <view class='iconfont icon-daosanjiao'></view> | 15 | <view class='iconfont icon-daosanjiao'></view> |
16 | </view> | 16 | </view> |
17 | - <view class='add_box'> | 17 | + <view class='add_box' bindtap='addUser'> |
18 | <text class='iconfont icon-jia'></text> | 18 | <text class='iconfont icon-jia'></text> |
19 | <text>添加学员</text> | 19 | <text>添加学员</text> |
20 | </view> | 20 | </view> |
@@ -22,10 +22,10 @@ | @@ -22,10 +22,10 @@ | ||
22 | <view class='service_info_box'> | 22 | <view class='service_info_box'> |
23 | <text class='iconfont icon-xuanzhong'></text> | 23 | <text class='iconfont icon-xuanzhong'></text> |
24 | <text>我已阅读并同意畅玩卡</text> | 24 | <text>我已阅读并同意畅玩卡</text> |
25 | - <text class='service_info'>服务协议</text> | 25 | + <text class='service_info' bindtap='serviceProtocol'>服务协议</text> |
26 | </view> | 26 | </view> |
27 | <view class='service_btn_box'> | 27 | <view class='service_btn_box'> |
28 | <view>需支付:¥288.00</view> | 28 | <view>需支付:¥288.00</view> |
29 | - <view class='pay_btn'>确定</view> | 29 | + <view class='pay_btn' bindtap='confirmPay'>确定</view> |
30 | </view> | 30 | </view> |
31 | </view> | 31 | </view> |
1 | /* pages/buyCard/buyCard.wxss */ | 1 | /* pages/buyCard/buyCard.wxss */ |
2 | @import '../groupBuy/groupBuy.wxss'; | 2 | @import '../groupBuy/groupBuy.wxss'; |
3 | @import '../charge/charge.wxss'; | 3 | @import '../charge/charge.wxss'; |
4 | +.long_img{ | ||
5 | + width: 100%; | ||
6 | + min-height: 1500rpx; | ||
7 | +} | ||
4 | .add_person_box { | 8 | .add_person_box { |
5 | display: flex; | 9 | display: flex; |
6 | align-items: center; | 10 | align-items: center; |
@@ -2,14 +2,14 @@ | @@ -2,14 +2,14 @@ | ||
2 | 2 | ||
3 | .content_box { | 3 | .content_box { |
4 | width: 100%; | 4 | width: 100%; |
5 | - height: 100%; | 5 | + min-height: 2000rpx; |
6 | background: #e0e0e0; | 6 | background: #e0e0e0; |
7 | font-size: 32rpx; | 7 | font-size: 32rpx; |
8 | color: #000; | 8 | color: #000; |
9 | padding: 30rpx; | 9 | padding: 30rpx; |
10 | - position: fixed; | 10 | + /* position: fixed; |
11 | top: 0; | 11 | top: 0; |
12 | - left: 0; | 12 | + left: 0; */ |
13 | text-align: center; | 13 | text-align: center; |
14 | /* display: flex; | 14 | /* display: flex; |
15 | align-items: center; | 15 | align-items: center; |
@@ -8,13 +8,14 @@ Page({ | @@ -8,13 +8,14 @@ Page({ | ||
8 | userlist: ['张三', '里斯'], | 8 | userlist: ['张三', '里斯'], |
9 | index: -1, | 9 | index: -1, |
10 | }, | 10 | }, |
11 | + | ||
11 | //选择成员 | 12 | //选择成员 |
12 | userList(e) { | 13 | userList(e) { |
13 | this.setData({ | 14 | this.setData({ |
14 | - index:e.detail.value | 15 | + index: e.detail.value |
15 | }) | 16 | }) |
16 | - | ||
17 | }, | 17 | }, |
18 | + | ||
18 | //兑换并绑定按钮 | 19 | //兑换并绑定按钮 |
19 | chargeBtn() { | 20 | chargeBtn() { |
20 | wx.showModal({ | 21 | wx.showModal({ |
@@ -25,6 +26,13 @@ Page({ | @@ -25,6 +26,13 @@ Page({ | ||
25 | }) | 26 | }) |
26 | }, | 27 | }, |
27 | 28 | ||
29 | + //添加学员 | ||
30 | + addUser() { | ||
31 | + wx.navigateTo({ | ||
32 | + url: '../../index/confirm-appointment-info/add-student/add-student', | ||
33 | + }) | ||
34 | + }, | ||
35 | + | ||
28 | /** | 36 | /** |
29 | * 生命周期函数--监听页面加载 | 37 | * 生命周期函数--监听页面加载 |
30 | */ | 38 | */ |
@@ -21,7 +21,7 @@ | @@ -21,7 +21,7 @@ | ||
21 | </picker> | 21 | </picker> |
22 | <view class='iconfont icon-daosanjiao'></view> | 22 | <view class='iconfont icon-daosanjiao'></view> |
23 | </view> | 23 | </view> |
24 | - <view class='add_box'> | 24 | + <view class='add_box' bindtap='addUser'> |
25 | <text class='iconfont icon-jia'></text> | 25 | <text class='iconfont icon-jia'></text> |
26 | <text>添加学员</text> | 26 | <text>添加学员</text> |
27 | </view> | 27 | </view> |
@@ -49,7 +49,9 @@ page { | @@ -49,7 +49,9 @@ page { | ||
49 | } | 49 | } |
50 | 50 | ||
51 | .icon-jia { | 51 | .icon-jia { |
52 | - display: inline-block; | 52 | + display: flex; |
53 | + align-items: center; | ||
54 | + justify-content: center; | ||
53 | width: 34rpx; | 55 | width: 34rpx; |
54 | height: 34rpx; | 56 | height: 34rpx; |
55 | background: #3fa9f5; | 57 | background: #3fa9f5; |
@@ -2,7 +2,7 @@ | @@ -2,7 +2,7 @@ | ||
2 | <view class='content_box'> | 2 | <view class='content_box'> |
3 | <view class='banner_box'> | 3 | <view class='banner_box'> |
4 | <view class='head_img'> | 4 | <view class='head_img'> |
5 | - <image src='../../images/head.png'></image> | 5 | + <image src='../../../images/head.png'></image> |
6 | </view> | 6 | </view> |
7 | <view>微信昵称</view> | 7 | <view>微信昵称</view> |
8 | </view> | 8 | </view> |
@@ -5,74 +5,103 @@ Page({ | @@ -5,74 +5,103 @@ Page({ | ||
5 | * 页面的初始数据 | 5 | * 页面的初始数据 |
6 | */ | 6 | */ |
7 | data: { | 7 | data: { |
8 | - current:0 | 8 | + current: 0, |
9 | + chargenum: "2059788797", | ||
9 | }, | 10 | }, |
10 | -//tab切换 | ||
11 | - tabCharge(e){ | ||
12 | - var index=e.currentTarget.dataset.current | ||
13 | - var current=this.data.current | ||
14 | - if(index==current){ | ||
15 | - return false | ||
16 | - }else{ | ||
17 | - this.setData({ | ||
18 | - current:index | 11 | + |
12 | + //tab切换 | ||
13 | + tabCharge(e) { | ||
14 | + var index = e.currentTarget.dataset.current | ||
15 | + var current = this.data.current | ||
16 | + if (index == current) { | ||
17 | + return false | ||
18 | + } else { | ||
19 | + this.setData({ | ||
20 | + current: index | ||
21 | + }) | ||
22 | + } | ||
23 | + }, | ||
24 | + | ||
25 | + //服务协议 | ||
26 | + serviceProtocol() { | ||
27 | + wx.navigateTo({ | ||
28 | + url: '../protocol/protocol', | ||
19 | }) | 29 | }) |
20 | - } | ||
21 | - }, | 30 | + }, |
31 | + | ||
32 | + //查看详情 | ||
33 | + listDetail() { | ||
34 | + wx.navigateTo({ | ||
35 | + url: '../groupBuyDetail/groupBuyDetail', | ||
36 | + }) | ||
37 | + }, | ||
38 | + | ||
39 | + // 长按复制 | ||
40 | + copy: function(e) { | ||
41 | + var that = this; | ||
42 | + wx.setClipboardData({ | ||
43 | + data: that.data.chargenum, | ||
44 | + success: function(res) { | ||
45 | + wx.showToast({ | ||
46 | + title: '复制成功', | ||
47 | + }); | ||
48 | + } | ||
49 | + }); | ||
50 | + }, | ||
22 | 51 | ||
23 | /** | 52 | /** |
24 | * 生命周期函数--监听页面加载 | 53 | * 生命周期函数--监听页面加载 |
25 | */ | 54 | */ |
26 | - onLoad: function (options) { | 55 | + onLoad: function(options) { |
27 | 56 | ||
28 | }, | 57 | }, |
29 | 58 | ||
30 | /** | 59 | /** |
31 | * 生命周期函数--监听页面初次渲染完成 | 60 | * 生命周期函数--监听页面初次渲染完成 |
32 | */ | 61 | */ |
33 | - onReady: function () { | 62 | + onReady: function() { |
34 | 63 | ||
35 | }, | 64 | }, |
36 | 65 | ||
37 | /** | 66 | /** |
38 | * 生命周期函数--监听页面显示 | 67 | * 生命周期函数--监听页面显示 |
39 | */ | 68 | */ |
40 | - onShow: function () { | 69 | + onShow: function() { |
41 | 70 | ||
42 | }, | 71 | }, |
43 | 72 | ||
44 | /** | 73 | /** |
45 | * 生命周期函数--监听页面隐藏 | 74 | * 生命周期函数--监听页面隐藏 |
46 | */ | 75 | */ |
47 | - onHide: function () { | 76 | + onHide: function() { |
48 | 77 | ||
49 | }, | 78 | }, |
50 | 79 | ||
51 | /** | 80 | /** |
52 | * 生命周期函数--监听页面卸载 | 81 | * 生命周期函数--监听页面卸载 |
53 | */ | 82 | */ |
54 | - onUnload: function () { | 83 | + onUnload: function() { |
55 | 84 | ||
56 | }, | 85 | }, |
57 | 86 | ||
58 | /** | 87 | /** |
59 | * 页面相关事件处理函数--监听用户下拉动作 | 88 | * 页面相关事件处理函数--监听用户下拉动作 |
60 | */ | 89 | */ |
61 | - onPullDownRefresh: function () { | 90 | + onPullDownRefresh: function() { |
62 | 91 | ||
63 | }, | 92 | }, |
64 | 93 | ||
65 | /** | 94 | /** |
66 | * 页面上拉触底事件的处理函数 | 95 | * 页面上拉触底事件的处理函数 |
67 | */ | 96 | */ |
68 | - onReachBottom: function () { | 97 | + onReachBottom: function() { |
69 | 98 | ||
70 | }, | 99 | }, |
71 | 100 | ||
72 | /** | 101 | /** |
73 | * 用户点击右上角分享 | 102 | * 用户点击右上角分享 |
74 | */ | 103 | */ |
75 | - onShareAppMessage: function () { | 104 | + onShareAppMessage: function() { |
76 | 105 | ||
77 | } | 106 | } |
78 | }) | 107 | }) |
@@ -13,14 +13,14 @@ | @@ -13,14 +13,14 @@ | ||
13 | <block wx:if='{{current==0}}'> | 13 | <block wx:if='{{current==0}}'> |
14 | <view class='content_box'> | 14 | <view class='content_box'> |
15 | <view class='item_list' wx:for='{{[1,2,3]}}' wx:key=''> | 15 | <view class='item_list' wx:for='{{[1,2,3]}}' wx:key=''> |
16 | - <view class='list_title_box'> | 16 | + <view class='list_title_box' bindtap='listDetail'> |
17 | <view>查看详情</view> | 17 | <view>查看详情</view> |
18 | <view class='iconfont icon-fanhui'></view> | 18 | <view class='iconfont icon-fanhui'></view> |
19 | </view> | 19 | </view> |
20 | <view class='list_info_box'> | 20 | <view class='list_info_box'> |
21 | <view class='info_item'> | 21 | <view class='info_item'> |
22 | <view class='info_box'> | 22 | <view class='info_box'> |
23 | - <image src='../../../images/start-logo.png'></image> | 23 | + <image src='../../../images/logo.png'></image> |
24 | <view class='info_label'>发起人</view> | 24 | <view class='info_label'>发起人</view> |
25 | </view> | 25 | </view> |
26 | <view class='info_time'> | 26 | <view class='info_time'> |
@@ -30,7 +30,7 @@ | @@ -30,7 +30,7 @@ | ||
30 | </view> | 30 | </view> |
31 | <view class='info_item'> | 31 | <view class='info_item'> |
32 | <view class='info_box'> | 32 | <view class='info_box'> |
33 | - <image src='../../../images/start-logo.png'></image> | 33 | + <image src='../../../images/logo.png'></image> |
34 | <view class='info_label'>发起人</view> | 34 | <view class='info_label'>发起人</view> |
35 | </view> | 35 | </view> |
36 | <view class='info_time'> | 36 | <view class='info_time'> |
@@ -62,7 +62,7 @@ | @@ -62,7 +62,7 @@ | ||
62 | <view class='user_info_box'> | 62 | <view class='user_info_box'> |
63 | <view class='user_info'> | 63 | <view class='user_info'> |
64 | <view class='info_box'> | 64 | <view class='info_box'> |
65 | - <image src='../../../images/start-logo.png'></image> | 65 | + <image src='../../../images/logo.png'></image> |
66 | <view class='info_label'>发起人</view> | 66 | <view class='info_label'>发起人</view> |
67 | </view> | 67 | </view> |
68 | <view>发起人姓名</view> | 68 | <view>发起人姓名</view> |
@@ -94,7 +94,7 @@ | @@ -94,7 +94,7 @@ | ||
94 | <view class='list_tab list_content' wx:for='{{[1,2,3]}}' wx:key=''> | 94 | <view class='list_tab list_content' wx:for='{{[1,2,3]}}' wx:key=''> |
95 | <view class='list_tab_item'>2018.10.10</view> | 95 | <view class='list_tab_item'>2018.10.10</view> |
96 | <view class='list_tab_item'>未兑换</view> | 96 | <view class='list_tab_item'>未兑换</view> |
97 | - <view class='list_tab_item'>2059788797</view> | 97 | + <view class='list_tab_item'><text selectable='true' bindlongtap='copy'>{{chargenum}}</text></view> |
98 | </view> | 98 | </view> |
99 | </view> | 99 | </view> |
100 | </view> | 100 | </view> |
@@ -120,7 +120,7 @@ | @@ -120,7 +120,7 @@ | ||
120 | <view class='service_info_box'> | 120 | <view class='service_info_box'> |
121 | <text class='iconfont icon-xuanzhong'></text> | 121 | <text class='iconfont icon-xuanzhong'></text> |
122 | <text>我已阅读并同意畅玩卡</text> | 122 | <text>我已阅读并同意畅玩卡</text> |
123 | - <text class='service_info'>服务协议</text> | 123 | + <text class='service_info' bindtap='serviceProtocol'>服务协议</text> |
124 | </view> | 124 | </view> |
125 | <view class='service_btn_box'> | 125 | <view class='service_btn_box'> |
126 | <view>单价:¥188.00</view> | 126 | <view>单价:¥188.00</view> |
@@ -2,6 +2,7 @@ | @@ -2,6 +2,7 @@ | ||
2 | 2 | ||
3 | page { | 3 | page { |
4 | background: #f5f5f5; | 4 | background: #f5f5f5; |
5 | + overflow: hidden; | ||
5 | } | 6 | } |
6 | 7 | ||
7 | .banner_img { | 8 | .banner_img { |
@@ -22,6 +23,7 @@ page { | @@ -22,6 +23,7 @@ page { | ||
22 | height: 80rpx; | 23 | height: 80rpx; |
23 | background: #fff; | 24 | background: #fff; |
24 | padding: 0 40rpx; | 25 | padding: 0 40rpx; |
26 | + box-sizing: border-box; | ||
25 | font-size: 32rpx; | 27 | font-size: 32rpx; |
26 | color: #464646; | 28 | color: #464646; |
27 | display: flex; | 29 | display: flex; |
@@ -50,10 +52,10 @@ page { | @@ -50,10 +52,10 @@ page { | ||
50 | align-items: center; | 52 | align-items: center; |
51 | justify-content: space-between; | 53 | justify-content: space-between; |
52 | padding: 0 22rpx; | 54 | padding: 0 22rpx; |
55 | + box-sizing: border-box; | ||
53 | font-size: 30rpx; | 56 | font-size: 30rpx; |
54 | color: #464646; | 57 | color: #464646; |
55 | text-align: center; | 58 | text-align: center; |
56 | - box-sizing: border-box; | ||
57 | } | 59 | } |
58 | 60 | ||
59 | .tab_item { | 61 | .tab_item { |
@@ -77,7 +79,6 @@ page { | @@ -77,7 +79,6 @@ page { | ||
77 | 79 | ||
78 | .content_box { | 80 | .content_box { |
79 | margin-top: 20rpx; | 81 | margin-top: 20rpx; |
80 | - /* padding-bottom: 100rpx; */ | ||
81 | } | 82 | } |
82 | 83 | ||
83 | .null_box { | 84 | .null_box { |
@@ -89,6 +90,7 @@ page { | @@ -89,6 +90,7 @@ page { | ||
89 | margin-bottom: 20rpx; | 90 | margin-bottom: 20rpx; |
90 | background: #fff; | 91 | background: #fff; |
91 | padding: 0 20rpx; | 92 | padding: 0 20rpx; |
93 | + box-sizing: border-box; | ||
92 | } | 94 | } |
93 | 95 | ||
94 | .list_title_box { | 96 | .list_title_box { |
@@ -98,6 +100,7 @@ page { | @@ -98,6 +100,7 @@ page { | ||
98 | font-size: 28rpx; | 100 | font-size: 28rpx; |
99 | color: #464646; | 101 | color: #464646; |
100 | padding: 10rpx 0; | 102 | padding: 10rpx 0; |
103 | + box-sizing: border-box; | ||
101 | border-bottom: 1rpx solid rgba(0, 0, 0, 0.1); | 104 | border-bottom: 1rpx solid rgba(0, 0, 0, 0.1); |
102 | } | 105 | } |
103 | 106 | ||
@@ -109,6 +112,7 @@ page { | @@ -109,6 +112,7 @@ page { | ||
109 | display: flex; | 112 | display: flex; |
110 | align-items: flex-start; | 113 | align-items: flex-start; |
111 | padding: 20rpx 20rpx; | 114 | padding: 20rpx 20rpx; |
115 | + box-sizing: border-box; | ||
112 | } | 116 | } |
113 | 117 | ||
114 | .info_item { | 118 | .info_item { |
@@ -208,6 +212,7 @@ page { | @@ -208,6 +212,7 @@ page { | ||
208 | align-items: flex-start; | 212 | align-items: flex-start; |
209 | justify-content: space-between; | 213 | justify-content: space-between; |
210 | padding-bottom: 20rpx; | 214 | padding-bottom: 20rpx; |
215 | + box-sizing: border-box; | ||
211 | } | 216 | } |
212 | 217 | ||
213 | .user_info { | 218 | .user_info { |
@@ -227,7 +232,9 @@ page { | @@ -227,7 +232,9 @@ page { | ||
227 | } | 232 | } |
228 | 233 | ||
229 | .state_box { | 234 | .state_box { |
235 | + padding-top: 35rpx; | ||
230 | text-align: right; | 236 | text-align: right; |
237 | + box-sizing: border-box; | ||
231 | } | 238 | } |
232 | 239 | ||
233 | .bottom_box { | 240 | .bottom_box { |
@@ -269,8 +276,6 @@ page { | @@ -269,8 +276,6 @@ page { | ||
269 | bottom: -28rpx; | 276 | bottom: -28rpx; |
270 | left: 50%; | 277 | left: 50%; |
271 | transform: translateX(-50%); | 278 | transform: translateX(-50%); |
272 | - /* padding: 2rpx 8rpx; | ||
273 | - box-sizing: border-box; */ | ||
274 | background: rgba(252, 91, 99, 1); | 279 | background: rgba(252, 91, 99, 1); |
275 | border-radius: 10rpx; | 280 | border-radius: 10rpx; |
276 | font-size: 18rpx; | 281 | font-size: 18rpx; |
@@ -283,6 +288,7 @@ page { | @@ -283,6 +288,7 @@ page { | ||
283 | .list_content { | 288 | .list_content { |
284 | border: 0 !important; | 289 | border: 0 !important; |
285 | padding: 15rpx 0 !important; | 290 | padding: 15rpx 0 !important; |
291 | + box-sizing: border-box; | ||
286 | } | 292 | } |
287 | 293 | ||
288 | .list_content .list_tab_item { | 294 | .list_content .list_tab_item { |
@@ -339,6 +345,7 @@ page { | @@ -339,6 +345,7 @@ page { | ||
339 | font-size: 30rpx !important; | 345 | font-size: 30rpx !important; |
340 | color: #464646 !important; | 346 | color: #464646 !important; |
341 | padding-left: 20rpx !important; | 347 | padding-left: 20rpx !important; |
348 | + box-sizing: border-box; | ||
342 | background: #fff !important; | 349 | background: #fff !important; |
343 | } | 350 | } |
344 | 351 |
@@ -5,62 +5,70 @@ Page({ | @@ -5,62 +5,70 @@ Page({ | ||
5 | * 页面的初始数据 | 5 | * 页面的初始数据 |
6 | */ | 6 | */ |
7 | data: { | 7 | data: { |
8 | + isFolded: true, | ||
9 | + }, | ||
10 | + //查看全部 | ||
11 | + listMore(e) { | ||
12 | + console.log(e) | ||
13 | + this.setData({ | ||
14 | + isFolded: !this.data.isFolded, | ||
15 | + }) | ||
8 | 16 | ||
9 | }, | 17 | }, |
10 | 18 | ||
11 | /** | 19 | /** |
12 | * 生命周期函数--监听页面加载 | 20 | * 生命周期函数--监听页面加载 |
13 | */ | 21 | */ |
14 | - onLoad: function (options) { | 22 | + onLoad: function(options) { |
15 | 23 | ||
16 | }, | 24 | }, |
17 | 25 | ||
18 | /** | 26 | /** |
19 | * 生命周期函数--监听页面初次渲染完成 | 27 | * 生命周期函数--监听页面初次渲染完成 |
20 | */ | 28 | */ |
21 | - onReady: function () { | 29 | + onReady: function() { |
22 | 30 | ||
23 | }, | 31 | }, |
24 | 32 | ||
25 | /** | 33 | /** |
26 | * 生命周期函数--监听页面显示 | 34 | * 生命周期函数--监听页面显示 |
27 | */ | 35 | */ |
28 | - onShow: function () { | 36 | + onShow: function() { |
29 | 37 | ||
30 | }, | 38 | }, |
31 | 39 | ||
32 | /** | 40 | /** |
33 | * 生命周期函数--监听页面隐藏 | 41 | * 生命周期函数--监听页面隐藏 |
34 | */ | 42 | */ |
35 | - onHide: function () { | 43 | + onHide: function() { |
36 | 44 | ||
37 | }, | 45 | }, |
38 | 46 | ||
39 | /** | 47 | /** |
40 | * 生命周期函数--监听页面卸载 | 48 | * 生命周期函数--监听页面卸载 |
41 | */ | 49 | */ |
42 | - onUnload: function () { | 50 | + onUnload: function() { |
43 | 51 | ||
44 | }, | 52 | }, |
45 | 53 | ||
46 | /** | 54 | /** |
47 | * 页面相关事件处理函数--监听用户下拉动作 | 55 | * 页面相关事件处理函数--监听用户下拉动作 |
48 | */ | 56 | */ |
49 | - onPullDownRefresh: function () { | 57 | + onPullDownRefresh: function() { |
50 | 58 | ||
51 | }, | 59 | }, |
52 | 60 | ||
53 | /** | 61 | /** |
54 | * 页面上拉触底事件的处理函数 | 62 | * 页面上拉触底事件的处理函数 |
55 | */ | 63 | */ |
56 | - onReachBottom: function () { | 64 | + onReachBottom: function() { |
57 | 65 | ||
58 | }, | 66 | }, |
59 | 67 | ||
60 | /** | 68 | /** |
61 | * 用户点击右上角分享 | 69 | * 用户点击右上角分享 |
62 | */ | 70 | */ |
63 | - onShareAppMessage: function () { | 71 | + onShareAppMessage: function() { |
64 | 72 | ||
65 | } | 73 | } |
66 | }) | 74 | }) |
1 | <!--pages/groupBuyDetail/groupBuyDetail.wxml--> | 1 | <!--pages/groupBuyDetail/groupBuyDetail.wxml--> |
2 | 2 | ||
3 | <view class='banner_img'> | 3 | <view class='banner_img'> |
4 | - <image src='../../images/banner.jpg'></image> | 4 | + <image src='../../../images/banner.jpg'></image> |
5 | </view> | 5 | </view> |
6 | <view class='content_box'> | 6 | <view class='content_box'> |
7 | <view class='item_list' wx:for='{{[1]}}' wx:key=''> | 7 | <view class='item_list' wx:for='{{[1]}}' wx:key=''> |
8 | - <view class='list_title_box'> | ||
9 | - <view>查看详情</view> | 8 | + <view class='list_title_box' bindtap='listMore'> |
9 | + <view>查看全部</view> | ||
10 | <view class='iconfont icon-fanhui'></view> | 10 | <view class='iconfont icon-fanhui'></view> |
11 | </view> | 11 | </view> |
12 | - <view class='list_info_box'> | ||
13 | - <view class='info_item' wx:for='{{[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,11,1,1,1,1,1,1,1,1,1,1,1,1,1]}}' wx:key=''> | 12 | + <view class="list_info_box {{isFolded?'hide':'show'}}" > |
13 | + <view class='info_item' wx:for='{{[1,1,1,1,1]}}' wx:key=''> | ||
14 | <view class='info_box'> | 14 | <view class='info_box'> |
15 | - <image src='../../images/start-logo.png'></image> | 15 | + <image src='../../../images/img1.png'></image> |
16 | <view class='info_label'>发起人</view> | 16 | <view class='info_label'>发起人</view> |
17 | </view> | 17 | </view> |
18 | <view class='info_time'> | 18 | <view class='info_time'> |
@@ -32,7 +32,7 @@ | @@ -32,7 +32,7 @@ | ||
32 | <view class='user_info_box'> | 32 | <view class='user_info_box'> |
33 | <view class='user_info'> | 33 | <view class='user_info'> |
34 | <view class='info_box'> | 34 | <view class='info_box'> |
35 | - <image src='../../images/start-logo.png'></image> | 35 | + <image src='../../../images/img1.png'></image> |
36 | <view class='info_label'>发起人</view> | 36 | <view class='info_label'>发起人</view> |
37 | </view> | 37 | </view> |
38 | <view>发起人姓名</view> | 38 | <view>发起人姓名</view> |
@@ -6,13 +6,13 @@ | @@ -6,13 +6,13 @@ | ||
6 | } | 6 | } |
7 | 7 | ||
8 | .service_btn_box { | 8 | .service_btn_box { |
9 | - background: linear-gradient(-78deg, rgba(255, 83, 2, 1), rgba(252, 116, 0, 1)); | ||
10 | - display: flex; | ||
11 | - align-items: center; | ||
12 | - justify-content: center; | ||
13 | - font-size: 36rpx; | ||
14 | - color: #fff; | ||
15 | - position: fixed; | 9 | + background: linear-gradient(-78deg, rgba(255, 83, 2, 1), rgba(252, 116, 0, 1)) !important; |
10 | + display: flex !important; | ||
11 | + align-items: center !important; | ||
12 | + justify-content: center !important; | ||
13 | + font-size: 36rpx !important; | ||
14 | + color: #fff !important; | ||
15 | + position: fixed !important; | ||
16 | bottom: 0; | 16 | bottom: 0; |
17 | left: 0; | 17 | left: 0; |
18 | } | 18 | } |
pages/my/groupBuyDetail2/groupBuyDetail2.js
0 → 100644
1 | +// pages/my/groupBuyDetail2/groupBuyDetail2.js | ||
2 | +Page({ | ||
3 | + | ||
4 | + /** | ||
5 | + * 页面的初始数据 | ||
6 | + */ | ||
7 | + data: { | ||
8 | + | ||
9 | + }, | ||
10 | + | ||
11 | + /** | ||
12 | + * 生命周期函数--监听页面加载 | ||
13 | + */ | ||
14 | + onLoad: function (options) { | ||
15 | + | ||
16 | + }, | ||
17 | + | ||
18 | + /** | ||
19 | + * 生命周期函数--监听页面初次渲染完成 | ||
20 | + */ | ||
21 | + onReady: function () { | ||
22 | + | ||
23 | + }, | ||
24 | + | ||
25 | + /** | ||
26 | + * 生命周期函数--监听页面显示 | ||
27 | + */ | ||
28 | + onShow: function () { | ||
29 | + | ||
30 | + }, | ||
31 | + | ||
32 | + /** | ||
33 | + * 生命周期函数--监听页面隐藏 | ||
34 | + */ | ||
35 | + onHide: function () { | ||
36 | + | ||
37 | + }, | ||
38 | + | ||
39 | + /** | ||
40 | + * 生命周期函数--监听页面卸载 | ||
41 | + */ | ||
42 | + onUnload: function () { | ||
43 | + | ||
44 | + }, | ||
45 | + | ||
46 | + /** | ||
47 | + * 页面相关事件处理函数--监听用户下拉动作 | ||
48 | + */ | ||
49 | + onPullDownRefresh: function () { | ||
50 | + | ||
51 | + }, | ||
52 | + | ||
53 | + /** | ||
54 | + * 页面上拉触底事件的处理函数 | ||
55 | + */ | ||
56 | + onReachBottom: function () { | ||
57 | + | ||
58 | + }, | ||
59 | + | ||
60 | + /** | ||
61 | + * 用户点击右上角分享 | ||
62 | + */ | ||
63 | + onShareAppMessage: function () { | ||
64 | + | ||
65 | + } | ||
66 | +}) |
1 | +{} |
1 | +/* pages/my/groupBuyDetail2/groupBuyDetail2.wxss */ |
1 | -// pages/my/my.js | ||
2 | -Page({ | ||
3 | - | ||
4 | - /** | ||
5 | - * 页面的初始数据 | ||
6 | - */ | ||
7 | - data: { | ||
8 | - | ||
9 | - }, | ||
10 | - //跳转我的预约 | ||
11 | - myAppointment() { | ||
12 | - | ||
13 | - }, | ||
14 | - //我的唱完卡 | ||
15 | - myCard() { | ||
16 | - wx.navigateTo({ | ||
17 | - url: 'myCard/myCard', | ||
18 | - }) | ||
19 | - }, | ||
20 | - //联系客服 | ||
21 | - contact() { | ||
22 | - wx.navigateTo({ | ||
23 | - url: 'serviceWeChat/serviceWeChat', | ||
24 | - }) | ||
25 | - }, | ||
26 | - /** | ||
27 | - * 生命周期函数--监听页面加载 | ||
28 | - */ | ||
29 | - onLoad: function(options) { | ||
30 | - | ||
31 | - }, | ||
32 | - | ||
33 | - /** | ||
34 | - * 生命周期函数--监听页面初次渲染完成 | ||
35 | - */ | ||
36 | - onReady: function() { | ||
37 | - | ||
38 | - }, | ||
39 | - | ||
40 | - /** | ||
41 | - * 生命周期函数--监听页面显示 | ||
42 | - */ | ||
43 | - onShow: function() { | ||
44 | - | ||
45 | - }, | ||
46 | - | ||
47 | - /** | ||
48 | - * 生命周期函数--监听页面隐藏 | ||
49 | - */ | ||
50 | - onHide: function() { | ||
51 | - | ||
52 | - }, | ||
53 | - | ||
54 | - /** | ||
55 | - * 生命周期函数--监听页面卸载 | ||
56 | - */ | ||
57 | - onUnload: function() { | ||
58 | - | ||
59 | - }, | ||
60 | - | ||
61 | - /** | ||
62 | - * 页面相关事件处理函数--监听用户下拉动作 | ||
63 | - */ | ||
64 | - onPullDownRefresh: function() { | ||
65 | - | ||
66 | - }, | ||
67 | - | ||
68 | - /** | ||
69 | - * 页面上拉触底事件的处理函数 | ||
70 | - */ | ||
71 | - onReachBottom: function() { | ||
72 | - | ||
73 | - }, | ||
74 | - | ||
75 | - /** | ||
76 | - * 用户点击右上角分享 | ||
77 | - */ | ||
78 | - onShareAppMessage: function() { | ||
79 | - | ||
80 | - } | ||
81 | -}) | ||
1 | + // pages/my/my.js | ||
2 | + Page({ | ||
3 | + | ||
4 | + /** | ||
5 | + * 页面的初始数据 | ||
6 | + */ | ||
7 | + data: { | ||
8 | + | ||
9 | + }, | ||
10 | + //兑换 | ||
11 | + charge() { | ||
12 | + wx.navigateTo({ | ||
13 | + url: '../my/charge/charge', | ||
14 | + }) | ||
15 | + }, | ||
16 | + //我的资料 | ||
17 | + myProfile(){ | ||
18 | + wx.navigateTo({ | ||
19 | + url: '../my/myProfile/myProfile', | ||
20 | + }) | ||
21 | + }, | ||
22 | + //跳转我的预约 | ||
23 | + myAppointment() { | ||
24 | + wx.navigateTo({ | ||
25 | + url: './all-appointment/all-appointment?currentTab=' + 0, | ||
26 | + }) | ||
27 | + }, | ||
28 | + goNotConfirm() { | ||
29 | + wx.navigateTo({ | ||
30 | + url: './all-appointment/all-appointment?currentTab=' + 1, | ||
31 | + }) | ||
32 | + }, | ||
33 | + goAppointed() { | ||
34 | + wx.navigateTo({ | ||
35 | + url: './all-appointment/all-appointment?currentTab=' + 2, | ||
36 | + }) | ||
37 | + }, | ||
38 | + goCanceled() { | ||
39 | + wx.navigateTo({ | ||
40 | + url: './all-appointment/all-appointment?currentTab=' + 3, | ||
41 | + }) | ||
42 | + }, | ||
43 | + goEnded() { | ||
44 | + wx.navigateTo({ | ||
45 | + url: './all-appointment/all-appointment?currentTab=' + 4, | ||
46 | + }) | ||
47 | + }, | ||
48 | + //我的唱完卡 | ||
49 | + myCard() { | ||
50 | + wx.navigateTo({ | ||
51 | + url: 'myCard/myCard', | ||
52 | + }) | ||
53 | + }, | ||
54 | + //联系客服 | ||
55 | + contact() { | ||
56 | + wx.navigateTo({ | ||
57 | + url: 'serviceWeChat/serviceWeChat', | ||
58 | + }) | ||
59 | + }, | ||
60 | + /** | ||
61 | + * 生命周期函数--监听页面加载 | ||
62 | + */ | ||
63 | + onLoad: function(options) { | ||
64 | + | ||
65 | + }, | ||
66 | + | ||
67 | + /** | ||
68 | + * 生命周期函数--监听页面初次渲染完成 | ||
69 | + */ | ||
70 | + onReady: function() { | ||
71 | + | ||
72 | + }, | ||
73 | + | ||
74 | + /** | ||
75 | + * 生命周期函数--监听页面显示 | ||
76 | + */ | ||
77 | + onShow: function() { | ||
78 | + | ||
79 | + }, | ||
80 | + | ||
81 | + /** | ||
82 | + * 生命周期函数--监听页面隐藏 | ||
83 | + */ | ||
84 | + onHide: function() { | ||
85 | + | ||
86 | + }, | ||
87 | + | ||
88 | + /** | ||
89 | + * 生命周期函数--监听页面卸载 | ||
90 | + */ | ||
91 | + onUnload: function() { | ||
92 | + | ||
93 | + }, | ||
94 | + | ||
95 | + /** | ||
96 | + * 页面相关事件处理函数--监听用户下拉动作 | ||
97 | + */ | ||
98 | + onPullDownRefresh: function() { | ||
99 | + | ||
100 | + }, | ||
101 | + | ||
102 | + /** | ||
103 | + * 页面上拉触底事件的处理函数 | ||
104 | + */ | ||
105 | + onReachBottom: function() { | ||
106 | + | ||
107 | + }, | ||
108 | + | ||
109 | + /** | ||
110 | + * 用户点击右上角分享 | ||
111 | + */ | ||
112 | + onShareAppMessage: function() { | ||
113 | + | ||
114 | + } | ||
115 | + }) |
@@ -10,7 +10,7 @@ | @@ -10,7 +10,7 @@ | ||
10 | <view class='phone_num'>139****0939</view> | 10 | <view class='phone_num'>139****0939</view> |
11 | </view> | 11 | </view> |
12 | </view> | 12 | </view> |
13 | - <view class='my_info_box'> | 13 | + <view class='my_info_box' bindtap='myProfile'> |
14 | <view class='iconfont icon-bianji2'></view> | 14 | <view class='iconfont icon-bianji2'></view> |
15 | <view>我的资料</view> | 15 | <view>我的资料</view> |
16 | </view> | 16 | </view> |
@@ -26,25 +26,25 @@ | @@ -26,25 +26,25 @@ | ||
26 | </view> | 26 | </view> |
27 | </view> | 27 | </view> |
28 | <view class='list_tab_box'> | 28 | <view class='list_tab_box'> |
29 | - <view class='tab_item'> | 29 | + <view class='tab_item' bindtap="goNotConfirm"> |
30 | <view class='list_img'> | 30 | <view class='list_img'> |
31 | <image src='../../images/my1.png'></image> | 31 | <image src='../../images/my1.png'></image> |
32 | </view> | 32 | </view> |
33 | <view>待确认</view> | 33 | <view>待确认</view> |
34 | </view> | 34 | </view> |
35 | - <view class='tab_item'> | 35 | + <view class='tab_item' bindtap="goAppointed"> |
36 | <view class='list_img'> | 36 | <view class='list_img'> |
37 | <image src='../../images/my1.png'></image> | 37 | <image src='../../images/my1.png'></image> |
38 | </view> | 38 | </view> |
39 | <view>已预约</view> | 39 | <view>已预约</view> |
40 | </view> | 40 | </view> |
41 | - <view class='tab_item'> | 41 | + <view class='tab_item' bindtap="goCanceled"> |
42 | <view class='list_img'> | 42 | <view class='list_img'> |
43 | <image src='../../images/my1.png'></image> | 43 | <image src='../../images/my1.png'></image> |
44 | </view> | 44 | </view> |
45 | <view>已取消</view> | 45 | <view>已取消</view> |
46 | </view> | 46 | </view> |
47 | - <view class='tab_item'> | 47 | + <view class='tab_item' bindtap="goEnded"> |
48 | <view class='list_img'> | 48 | <view class='list_img'> |
49 | <image src='../../images/my1.png'></image> | 49 | <image src='../../images/my1.png'></image> |
50 | </view> | 50 | </view> |
@@ -57,7 +57,7 @@ | @@ -57,7 +57,7 @@ | ||
57 | <view class='list_title'>我的畅玩卡</view> | 57 | <view class='list_title'>我的畅玩卡</view> |
58 | <view class='iconfont icon-fanhui'></view> | 58 | <view class='iconfont icon-fanhui'></view> |
59 | </view> | 59 | </view> |
60 | - <view class='info_box'> | 60 | + <view class='info_box' bindtap='charge'> |
61 | <view class='list_title'>兑换</view> | 61 | <view class='list_title'>兑换</view> |
62 | </view> | 62 | </view> |
63 | <view class='info_box' bindtap='contact'> | 63 | <view class='info_box' bindtap='contact'> |
1 | -// pages/MyProfile/MyProfile.js | ||
2 | -Page({ | ||
3 | - | ||
4 | - /** | ||
5 | - * 页面的初始数据 | ||
6 | - */ | ||
7 | - data: { | ||
8 | - | ||
9 | - }, | ||
10 | - | ||
11 | - /** | ||
12 | - * 生命周期函数--监听页面加载 | ||
13 | - */ | ||
14 | - onLoad: function (options) { | ||
15 | - | ||
16 | - }, | ||
17 | - | ||
18 | - /** | ||
19 | - * 生命周期函数--监听页面初次渲染完成 | ||
20 | - */ | ||
21 | - onReady: function () { | ||
22 | - | ||
23 | - }, | ||
24 | - | ||
25 | - /** | ||
26 | - * 生命周期函数--监听页面显示 | ||
27 | - */ | ||
28 | - onShow: function () { | ||
29 | - | ||
30 | - }, | ||
31 | - | ||
32 | - /** | ||
33 | - * 生命周期函数--监听页面隐藏 | ||
34 | - */ | ||
35 | - onHide: function () { | ||
36 | - | ||
37 | - }, | ||
38 | - | ||
39 | - /** | ||
40 | - * 生命周期函数--监听页面卸载 | ||
41 | - */ | ||
42 | - onUnload: function () { | ||
43 | - | ||
44 | - }, | ||
45 | - | ||
46 | - /** | ||
47 | - * 页面相关事件处理函数--监听用户下拉动作 | ||
48 | - */ | ||
49 | - onPullDownRefresh: function () { | ||
50 | - | ||
51 | - }, | ||
52 | - | ||
53 | - /** | ||
54 | - * 页面上拉触底事件的处理函数 | ||
55 | - */ | ||
56 | - onReachBottom: function () { | ||
57 | - | ||
58 | - }, | ||
59 | - | ||
60 | - /** | ||
61 | - * 用户点击右上角分享 | ||
62 | - */ | ||
63 | - onShareAppMessage: function () { | ||
64 | - | ||
65 | - } | ||
66 | -}) | ||
1 | + // pages/MyProfile/MyProfile.js | ||
2 | + Page({ | ||
3 | + | ||
4 | + /** | ||
5 | + * 页面的初始数据 | ||
6 | + */ | ||
7 | + data: { | ||
8 | + | ||
9 | + }, | ||
10 | + | ||
11 | + //跟换手机号 | ||
12 | + chargePhoneNum() { | ||
13 | + wx.navigateTo({ | ||
14 | + url: '../chargePhoneNum/chargePhoneNum', | ||
15 | + }) | ||
16 | + }, | ||
17 | + //添加学员 | ||
18 | + addUser() { | ||
19 | + wx.navigateTo({ | ||
20 | + url: '../../index/confirm-appointment-info/add-student/add-student', | ||
21 | + }) | ||
22 | + }, | ||
23 | + //编辑学员信息 | ||
24 | + editInfo() { | ||
25 | + wx.navigateTo({ | ||
26 | + url: '../../index/confirm-appointment-info/add-student/add-student', | ||
27 | + }) | ||
28 | + }, | ||
29 | + | ||
30 | + //续卡 | ||
31 | + renewalInfo() { | ||
32 | + wx.navigateTo({ | ||
33 | + url: '../myCard/myCard', | ||
34 | + }) | ||
35 | + }, | ||
36 | + | ||
37 | + //购卡 | ||
38 | + buyCard() { | ||
39 | + wx.navigateTo({ | ||
40 | + url: '../myCard/myCard', | ||
41 | + }) | ||
42 | + }, | ||
43 | + | ||
44 | + /** | ||
45 | + * 生命周期函数--监听页面加载 | ||
46 | + */ | ||
47 | + onLoad: function(options) { | ||
48 | + | ||
49 | + }, | ||
50 | + | ||
51 | + /** | ||
52 | + * 生命周期函数--监听页面初次渲染完成 | ||
53 | + */ | ||
54 | + onReady: function() { | ||
55 | + | ||
56 | + }, | ||
57 | + | ||
58 | + /** | ||
59 | + * 生命周期函数--监听页面显示 | ||
60 | + */ | ||
61 | + onShow: function() { | ||
62 | + | ||
63 | + }, | ||
64 | + | ||
65 | + /** | ||
66 | + * 生命周期函数--监听页面隐藏 | ||
67 | + */ | ||
68 | + onHide: function() { | ||
69 | + | ||
70 | + }, | ||
71 | + | ||
72 | + /** | ||
73 | + * 生命周期函数--监听页面卸载 | ||
74 | + */ | ||
75 | + onUnload: function() { | ||
76 | + | ||
77 | + }, | ||
78 | + | ||
79 | + /** | ||
80 | + * 页面相关事件处理函数--监听用户下拉动作 | ||
81 | + */ | ||
82 | + onPullDownRefresh: function() { | ||
83 | + | ||
84 | + }, | ||
85 | + | ||
86 | + /** | ||
87 | + * 页面上拉触底事件的处理函数 | ||
88 | + */ | ||
89 | + onReachBottom: function() { | ||
90 | + | ||
91 | + }, | ||
92 | + | ||
93 | + /** | ||
94 | + * 用户点击右上角分享 | ||
95 | + */ | ||
96 | + onShareAppMessage: function() { | ||
97 | + | ||
98 | + } | ||
99 | + }) |
@@ -9,17 +9,18 @@ | @@ -9,17 +9,18 @@ | ||
9 | </view> | 9 | </view> |
10 | <view class='info_box'> | 10 | <view class='info_box'> |
11 | <view>手机号:188*****888</view> | 11 | <view>手机号:188*****888</view> |
12 | - <view>更换手机号</view> | 12 | + <view class='info_content' bindtap='chargePhoneNum'>更换手机号</view> |
13 | </view> | 13 | </view> |
14 | <view class='title_box'> | 14 | <view class='title_box'> |
15 | <view class='list_title'>我的学员</view> | 15 | <view class='list_title'>我的学员</view> |
16 | - <view class='add_box'> | 16 | + <view class='add_box' bindtap='addUser'> |
17 | <text class='iconfont icon-jia'></text> | 17 | <text class='iconfont icon-jia'></text> |
18 | <text>添加学员</text> | 18 | <text>添加学员</text> |
19 | </view> | 19 | </view> |
20 | </view> | 20 | </view> |
21 | +<!-- 未绑定年卡,就需要显示为“购卡”;已有年卡就显示为“续卡” --> | ||
21 | <view class='box'> | 22 | <view class='box'> |
22 | - <view class='list_item' wx:for='{{[1,1]}}' wx:key=''> | 23 | + <view class='list_item'> |
23 | <view class='list_info'> | 24 | <view class='list_info'> |
24 | <text>姓名:男</text> | 25 | <text>姓名:男</text> |
25 | <text>性 别:男</text> | 26 | <text>性 别:男</text> |
@@ -29,11 +30,26 @@ | @@ -29,11 +30,26 @@ | ||
29 | <text>所在城市:北京</text> | 30 | <text>所在城市:北京</text> |
30 | </view> | 31 | </view> |
31 | <view class='list_label_box'> | 32 | <view class='list_label_box'> |
32 | - <view class='label_item edit_btn'>编辑学员信息</view> | ||
33 | - <view class='label_item renewal_btn'>续卡</view> | ||
34 | - <view class='label_item'>删除学员</view> | 33 | + <view class='label_item edit_btn' bindtap='editInfo'>编辑学员信息</view> |
34 | + <view class='label_item renewal_btn' bindtap='renewalInfo'>续卡</view> | ||
35 | + <view class='label_item' bindtap='delUser'>删除学员</view> | ||
35 | </view> | 36 | </view> |
36 | <view class='hint_info'>畅玩卡周期:2018.10.01-2019.10.01</view> | 37 | <view class='hint_info'>畅玩卡周期:2018.10.01-2019.10.01</view> |
37 | </view> | 38 | </view> |
38 | - | 39 | + <view class='list_item'> |
40 | + <view class='list_info'> | ||
41 | + <text>姓名:男</text> | ||
42 | + <text>性 别:男</text> | ||
43 | + </view> | ||
44 | + <view class='list_info'> | ||
45 | + <text>生日:2000.01.01</text> | ||
46 | + <text>所在城市:北京</text> | ||
47 | + </view> | ||
48 | + <view class='list_label_box'> | ||
49 | + <view class='label_item edit_btn' bindtap='editInfo'>编辑学员信息</view> | ||
50 | + <view class='label_item renewal_btn' bindtap='buyCard'>购卡</view> | ||
51 | + <view class='label_item' bindtap='delUser'>删除学员</view> | ||
52 | + </view> | ||
53 | + <view class='hint_info'>无绑定畅玩卡</view> | ||
54 | + </view> | ||
39 | </view> | 55 | </view> |
@@ -46,6 +46,13 @@ page { | @@ -46,6 +46,13 @@ page { | ||
46 | background: #fff; | 46 | background: #fff; |
47 | padding: 34rpx 40rpx; | 47 | padding: 34rpx 40rpx; |
48 | margin-top: 20rpx; | 48 | margin-top: 20rpx; |
49 | + font-size: 32rpx; | ||
50 | + color: #464646; | ||
51 | +} | ||
52 | + | ||
53 | +.info_content { | ||
54 | + font-size: 24rpx; | ||
55 | + color: #3fa9f5; | ||
49 | } | 56 | } |
50 | 57 | ||
51 | .title_box { | 58 | .title_box { |
@@ -56,7 +63,9 @@ page { | @@ -56,7 +63,9 @@ page { | ||
56 | } | 63 | } |
57 | 64 | ||
58 | .icon-jia { | 65 | .icon-jia { |
59 | - display: inline-block; | 66 | + display: flex; |
67 | + align-items: center; | ||
68 | + justify-content: center; | ||
60 | width: 34rpx; | 69 | width: 34rpx; |
61 | height: 34rpx; | 70 | height: 34rpx; |
62 | background: #3fa9f5; | 71 | background: #3fa9f5; |
@@ -97,8 +106,8 @@ page { | @@ -97,8 +106,8 @@ page { | ||
97 | .list_item { | 106 | .list_item { |
98 | width: 100%; | 107 | width: 100%; |
99 | background: #fff; | 108 | background: #fff; |
100 | - padding:0 20rpx; | ||
101 | - min-height: 210rpx; | 109 | + padding: 0 20rpx; |
110 | + min-height: 230rpx; | ||
102 | box-sizing: border-box; | 111 | box-sizing: border-box; |
103 | position: relative; | 112 | position: relative; |
104 | overflow: hidden; | 113 | overflow: hidden; |
@@ -110,11 +119,12 @@ page { | @@ -110,11 +119,12 @@ page { | ||
110 | display: flex; | 119 | display: flex; |
111 | align-items: center; | 120 | align-items: center; |
112 | justify-content: space-between; | 121 | justify-content: space-between; |
113 | - padding:10rpx 20rpx; | ||
114 | - border-bottom: 1rpx solid #DEDEDE; | 122 | + padding: 10rpx 20rpx; |
123 | + border-bottom: 1rpx solid #dedede; | ||
115 | } | 124 | } |
116 | - .list_info:nth-child(2){ | ||
117 | - border-bottom: 0rpx; | 125 | + |
126 | +.list_info:nth-child(2) { | ||
127 | + border-bottom: 0rpx; | ||
118 | } | 128 | } |
119 | 129 | ||
120 | .list_info text { | 130 | .list_info text { |
@@ -123,35 +133,41 @@ page { | @@ -123,35 +133,41 @@ page { | ||
123 | font-size: 28rpx; | 133 | font-size: 28rpx; |
124 | color: #6e6e6e; | 134 | color: #6e6e6e; |
125 | } | 135 | } |
126 | -.list_label_box{ | 136 | + |
137 | +.list_label_box { | ||
127 | display: flex; | 138 | display: flex; |
128 | align-items: center; | 139 | align-items: center; |
129 | justify-content: flex-end; | 140 | justify-content: flex-end; |
141 | + margin: 10rpx 0; | ||
130 | } | 142 | } |
131 | -.label_item{ | 143 | + |
144 | +.label_item { | ||
132 | width: 130rpx; | 145 | width: 130rpx; |
133 | height: 40rpx; | 146 | height: 40rpx; |
134 | - border: 1rpx solid #3FA9F5; | 147 | + border: 1rpx solid #3fa9f5; |
135 | border-radius: 10rpx; | 148 | border-radius: 10rpx; |
136 | font-size: 18rpx; | 149 | font-size: 18rpx; |
137 | - color: #3FA9F5; | 150 | + color: #3fa9f5; |
138 | display: flex; | 151 | display: flex; |
139 | align-items: center; | 152 | align-items: center; |
140 | justify-content: center; | 153 | justify-content: center; |
141 | margin-left: 30rpx; | 154 | margin-left: 30rpx; |
142 | } | 155 | } |
143 | -.edit_btn,.renewal_btn{ | ||
144 | - background: #3FA9F5; | 156 | + |
157 | +.edit_btn, .renewal_btn { | ||
158 | + background: #3fa9f5; | ||
145 | color: #fff; | 159 | color: #fff; |
146 | border: 0; | 160 | border: 0; |
147 | } | 161 | } |
148 | -.renewal_btn{ | ||
149 | - background: #FC5B63; | 162 | + |
163 | +.renewal_btn { | ||
164 | + background: #fc5b63; | ||
150 | } | 165 | } |
151 | -.hint_info{ | 166 | + |
167 | +.hint_info { | ||
152 | width: 100%; | 168 | width: 100%; |
153 | height: 40rpx; | 169 | height: 40rpx; |
154 | - background: #3FA9F5; | 170 | + background: #3fa9f5; |
155 | color: #fff; | 171 | color: #fff; |
156 | font-size: 18rpx; | 172 | font-size: 18rpx; |
157 | line-height: 40rpx; | 173 | line-height: 40rpx; |
@@ -159,4 +175,4 @@ page { | @@ -159,4 +175,4 @@ page { | ||
159 | position: absolute; | 175 | position: absolute; |
160 | bottom: 0; | 176 | bottom: 0; |
161 | left: 0; | 177 | left: 0; |
162 | -} | ||
178 | +} |
@@ -28,3 +28,15 @@ | @@ -28,3 +28,15 @@ | ||
28 | color: #6f6f6f; | 28 | color: #6f6f6f; |
29 | padding: 0 100rpx; | 29 | padding: 0 100rpx; |
30 | } | 30 | } |
31 | +.bottom_btn{ | ||
32 | + width: 500rpx; | ||
33 | + height: 88rpx; | ||
34 | + border-radius: 16rpx; | ||
35 | + background: #3FA9F5; | ||
36 | + font-size: 36rpx; | ||
37 | + color: #fff; | ||
38 | + display: flex; | ||
39 | + align-items: center; | ||
40 | + justify-content: center; | ||
41 | + margin: 40rpx auto 0 auto; | ||
42 | +} |
-
请 注册 或 登录 后发表评论