默认提交
Showing
10 changed files
with
102 additions
and
33 deletions
... | @@ -49,28 +49,26 @@ App({ | ... | @@ -49,28 +49,26 @@ App({ |
49 | this.globalData.barHeight = height; | 49 | this.globalData.barHeight = height; |
50 | this.share(); | 50 | this.share(); |
51 | 51 | ||
52 | // let uuid = store.getItem("aldstat_uuid"); | 52 | let _this = this; |
53 | // console.log("uuid222:", uuid); | ||
54 | // store.setItem("uuid", uuid); | ||
55 | // console.log("uuid:", uuid); | ||
56 | // wx.aldstat.sendOpenid(uuid); | ||
57 | |||
58 | // 阿拉丁 | 53 | // 阿拉丁 |
59 | // wx.login({ | 54 | wx.login({ |
60 | // success: function (res) { | 55 | success: function (res) { |
61 | // wx.request({ | 56 | _this.post({ |
62 | // url: "", | 57 | sid: false, |
63 | // data: { | 58 | url: api.openid, |
64 | // jscode: res.code | 59 | data: { |
65 | // }, | 60 | code: res.code |
66 | // success: function (res) { | 61 | } |
67 | // //..... | 62 | }).then((result) => { |
68 | // //调用上传OpenID | 63 | wx.aldstat.sendOpenid(result); |
69 | // wx.aldstat.sendOpenid(uuid); | 64 | wx.login({ |
70 | // } | 65 | success(res2) { |
71 | // }) | 66 | store.setItem('wxcode2', res2.code); |
72 | // } | 67 | } |
73 | // }) | 68 | }); |
69 | }) | ||
70 | } | ||
71 | }) | ||
74 | }, | 72 | }, |
75 | globalData: { | 73 | globalData: { |
76 | share: false, | 74 | share: false, | ... | ... |
1 | module.exports = { | 1 | module.exports = { |
2 | login: "/login", // post 通过wxcode换取sessionId | 2 | login: "/login", // post 通过wxcode换取sessionId |
3 | openid: "/openid", // post 通过wxcode换取sessionId | ||
3 | register: '/register', // post 注册(用户授权) | 4 | register: '/register', // post 注册(用户授权) |
4 | 5 | ||
5 | // dataList: '/dataList', // 测试接口 | 6 | // dataList: '/dataList', // 测试接口 | ... | ... |
... | @@ -32,7 +32,6 @@ Page({ | ... | @@ -32,7 +32,6 @@ Page({ |
32 | // type: 0, // 0单人 1组队 | 32 | // type: 0, // 0单人 1组队 |
33 | // 个人信息修改 | 33 | // 个人信息修改 |
34 | updateUserInfoDialogVisible: false, | 34 | updateUserInfoDialogVisible: false, |
35 | joinRoomDialogVisibleUnAuth: false, | ||
36 | updateUserInfo: {}, // 需要更新的用户数据 | 35 | updateUserInfo: {}, // 需要更新的用户数据 |
37 | files: [], // 上传文件列表 | 36 | files: [], // 上传文件列表 |
38 | 37 | ||
... | @@ -81,7 +80,11 @@ Page({ | ... | @@ -81,7 +80,11 @@ Page({ |
81 | shareType = res.target.dataset.data || ""; | 80 | shareType = res.target.dataset.data || ""; |
82 | console.log("shareType:", shareType); | 81 | console.log("shareType:", shareType); |
83 | if (shareType) { | 82 | if (shareType) { |
83 | console.log("shareType222:",shareType); | ||
84 | title = `${ownerMember.memberName}邀请您组队发祝福!体验今年最火爆的拜年方式` | 84 | title = `${ownerMember.memberName}邀请您组队发祝福!体验今年最火爆的拜年方式` |
85 | wx.aldstat.sendEvent('拜年页分享', { | ||
86 | '分享': '邀请分享' | ||
87 | }); | ||
85 | } else {} | 88 | } else {} |
86 | 89 | ||
87 | let act = res.target.dataset.act || ""; | 90 | let act = res.target.dataset.act || ""; |
... | @@ -100,6 +103,10 @@ Page({ | ... | @@ -100,6 +103,10 @@ Page({ |
100 | let path = `pages/blessing/blessing?c=${detailData.blessCode}&m=${memberCode}&t=${shareType}`; | 103 | let path = `pages/blessing/blessing?c=${detailData.blessCode}&m=${memberCode}&t=${shareType}`; |
101 | console.log("share path:", path); | 104 | console.log("share path:", path); |
102 | 105 | ||
106 | wx.aldstat.sendEvent('拜年页分享', { | ||
107 | '分享': '普通分享' | ||
108 | }); | ||
109 | |||
103 | return { | 110 | return { |
104 | title, | 111 | title, |
105 | path, | 112 | path, |
... | @@ -231,6 +238,10 @@ Page({ | ... | @@ -231,6 +238,10 @@ Page({ |
231 | } | 238 | } |
232 | }); | 239 | }); |
233 | console.log("memberCode:", app.store.getItem("memberCode")); | 240 | console.log("memberCode:", app.store.getItem("memberCode")); |
241 | |||
242 | wx.aldstat.sendEvent('进入页面', { | ||
243 | '页面名字': '拜年详情页' | ||
244 | }); | ||
234 | }, | 245 | }, |
235 | 246 | ||
236 | /** | 247 | /** |
... | @@ -288,6 +299,34 @@ Page({ | ... | @@ -288,6 +299,34 @@ Page({ |
288 | }) | 299 | }) |
289 | }, | 300 | }, |
290 | 301 | ||
302 | onShowMakeHandler() { | ||
303 | let { | ||
304 | detailData | ||
305 | } = this.data; | ||
306 | let _this = this; | ||
307 | wx.showModal({ | ||
308 | title: '提示', | ||
309 | content: '需要定制祝福才能邀请亲友哦~', | ||
310 | confirmText: "马上创建", | ||
311 | success(res) { | ||
312 | if (res.confirm) { | ||
313 | // 已授权 | ||
314 | app.post({ | ||
315 | url: app.api.blessMade, | ||
316 | data: { | ||
317 | blessCode: detailData.blessCode, | ||
318 | } | ||
319 | }).then((result) => { | ||
320 | this.queryBlessDetail().then((result) => { | ||
321 | this.showTips("定制祝福成功!马上邀请您的亲友吧!"); | ||
322 | }); | ||
323 | }).catch((err) => {}); | ||
324 | } else if (res.cancel) { | ||
325 | } | ||
326 | } | ||
327 | }) | ||
328 | }, | ||
329 | |||
291 | 330 | ||
292 | showTips(tips) { | 331 | showTips(tips) { |
293 | wx.showToast({ | 332 | wx.showToast({ |
... | @@ -900,7 +939,6 @@ Page({ | ... | @@ -900,7 +939,6 @@ Page({ |
900 | } = this.data; | 939 | } = this.data; |
901 | console.log("isAuth:", isAuth); | 940 | console.log("isAuth:", isAuth); |
902 | if (isAuth) { | 941 | if (isAuth) { |
903 | |||
904 | // 把房间变成自己 | 942 | // 把房间变成自己 |
905 | this.setData({ | 943 | this.setData({ |
906 | isJoin: false, | 944 | isJoin: false, |
... | @@ -977,6 +1015,7 @@ Page({ | ... | @@ -977,6 +1015,7 @@ Page({ |
977 | 1015 | ||
978 | // 授权操作 | 1016 | // 授权操作 |
979 | getUserInfo(e) { | 1017 | getUserInfo(e) { |
1018 | console.log("getUserInfo 1111111"); | ||
980 | let { | 1019 | let { |
981 | detailData | 1020 | detailData |
982 | } = this.data; | 1021 | } = this.data; |
... | @@ -1074,7 +1113,6 @@ Page({ | ... | @@ -1074,7 +1113,6 @@ Page({ |
1074 | app.store.setItem('sessionId', res2.sessionId); | 1113 | app.store.setItem('sessionId', res2.sessionId); |
1075 | app.store.setItem('memberCode', res2.memberCode); | 1114 | app.store.setItem('memberCode', res2.memberCode); |
1076 | } | 1115 | } |
1077 | console.log("1111"); | ||
1078 | this.queryBlessDetail().then((result) => { | 1116 | this.queryBlessDetail().then((result) => { |
1079 | this.onBlessMakeHandler(); | 1117 | this.onBlessMakeHandler(); |
1080 | }); | 1118 | }); | ... | ... |
... | @@ -41,15 +41,31 @@ | ... | @@ -41,15 +41,31 @@ |
41 | </view> | 41 | </view> |
42 | <!-- 邀请 房主或组队模式显示 --> | 42 | <!-- 邀请 房主或组队模式显示 --> |
43 | <view class="group-item" wx:if="{{options.t || ownerMember.mySelf == 1}}"> | 43 | <view class="group-item" wx:if="{{options.t || ownerMember.mySelf == 1}}"> |
44 | <button wx:if="{{!isAuth}}" open-type="getUserInfo" bindgetuserinfo="bindGetUserInfo" class="group-item-inv"> | 44 | <!-- 未授权 --> |
45 | <block wx:if="{{!isAuth}}"> | ||
46 | <!-- 未定制 --> | ||
47 | <button wx:if="{{detailData.customMade == 0}}" open-type="getUserInfo" bindgetuserinfo="getUserInfo3" class="group-item-inv"> | ||
45 | <image class="icon-inv" mode="widthFix" src="../../image/icon/icon-inv.png" /> | 48 | <image class="icon-inv" mode="widthFix" src="../../image/icon/icon-inv.png" /> |
46 | </button> | 49 | </button> |
47 | <button wx:else data-data="join" open-type="share" class="group-item-inv"> | 50 | <!-- 已定制 --> |
51 | <button wx:else open-type="getUserInfo" bindgetuserinfo="bindGetUserInfo" class="group-item-inv"> | ||
48 | <image class="icon-inv" mode="widthFix" src="../../image/icon/icon-inv.png" /> | 52 | <image class="icon-inv" mode="widthFix" src="../../image/icon/icon-inv.png" /> |
49 | </button> | 53 | </button> |
50 | <!-- <button open-type="getUserInfo" bindgetuserinfo="bindGetUserInfo" class="btn btn1"> | 54 | </block> |
51 | 邀亲友组团拜年 | 55 | <block wx:else> |
52 | </button> --> | 56 | <!-- 未定制 --> |
57 | <block wx:if="{{detailData.customMade == 0}}"> | ||
58 | <button bindtap="onBlessMakeHandler" class="group-item-inv"> | ||
59 | <image class="icon-inv" mode="widthFix" src="../../image/icon/icon-inv.png" /> | ||
60 | </button> | ||
61 | </block> | ||
62 | <!-- 已定制 --> | ||
63 | <block wx:else> | ||
64 | <button data-data="join" open-type="share" class="group-item-inv"> | ||
65 | <image class="icon-inv" mode="widthFix" src="../../image/icon/icon-inv.png" /> | ||
66 | </button> | ||
67 | </block> | ||
68 | </block> | ||
53 | </view> | 69 | </view> |
54 | </view> | 70 | </view> |
55 | <!-- 更多 --> | 71 | <!-- 更多 --> |
... | @@ -156,9 +172,10 @@ | ... | @@ -156,9 +172,10 @@ |
156 | </block> | 172 | </block> |
157 | <!-- 已授权 --> | 173 | <!-- 已授权 --> |
158 | <block wx:else> | 174 | <block wx:else> |
159 | <button data-data="join" data-act="made" open-type="share" class="btn btn1"> | 175 | <button bindtap="onBlessMakeHandler" class="btn btn1">邀亲友组团拜年</button> |
176 | <!-- <button data-data="join" data-act="made" open-type="share" class="btn btn1"> | ||
160 | 邀亲友组团拜年 | 177 | 邀亲友组团拜年 |
161 | </button> | 178 | </button> --> |
162 | <button wx:if="{{!isAuth}}" open-type="getUserInfo" bindgetuserinfo="getUserInfo3" class="btn btn2"> | 179 | <button wx:if="{{!isAuth}}" open-type="getUserInfo" bindgetuserinfo="getUserInfo3" class="btn btn2"> |
163 | 定制我的祝福 | 180 | 定制我的祝福 |
164 | </button> | 181 | </button> |
... | @@ -253,7 +270,7 @@ | ... | @@ -253,7 +270,7 @@ |
253 | <image class="portrait-inner" mode="scaleToFill" src="{{ownerMember.memberHead}}" /> | 270 | <image class="portrait-inner" mode="scaleToFill" src="{{ownerMember.memberHead}}" /> |
254 | </view> | 271 | </view> |
255 | <view class="nickname">{{ownerMember.memberName}}</view> | 272 | <view class="nickname">{{ownerMember.memberName}}</view> |
256 | <view class="t1">邀请你一起加入组队送祝福!</view> | 273 | <view class="t1">邀请你一起加入组队送祝福!2</view> |
257 | </view> | 274 | </view> |
258 | </van-dialog> | 275 | </van-dialog> |
259 | <van-popup class="poster-popup" show="{{ authorizeVisible }}"> | 276 | <van-popup class="poster-popup" show="{{ authorizeVisible }}"> | ... | ... |
... | @@ -53,6 +53,9 @@ Page({ | ... | @@ -53,6 +53,9 @@ Page({ |
53 | options | 53 | options |
54 | }) | 54 | }) |
55 | this.initData(); | 55 | this.initData(); |
56 | wx.aldstat.sendEvent('进入页面', { | ||
57 | '页面名字': '首页' | ||
58 | }); | ||
56 | }, | 59 | }, |
57 | initData() { | 60 | initData() { |
58 | this.queryTabList().then((result) => { | 61 | this.queryTabList().then((result) => { | ... | ... |
... | @@ -45,6 +45,9 @@ Page({ | ... | @@ -45,6 +45,9 @@ Page({ |
45 | }); | 45 | }); |
46 | console.log("tempOptions:", tempOptions); | 46 | console.log("tempOptions:", tempOptions); |
47 | this.initData(); | 47 | this.initData(); |
48 | wx.aldstat.sendEvent('进入页面', { | ||
49 | '页面名字': '个人列表页' | ||
50 | }); | ||
48 | }, | 51 | }, |
49 | initData() { | 52 | initData() { |
50 | this.resetPage(); | 53 | this.resetPage(); | ... | ... |
... | @@ -57,6 +57,9 @@ Page({ | ... | @@ -57,6 +57,9 @@ Page({ |
57 | action: "reword_page", | 57 | action: "reword_page", |
58 | primaryCode: "", | 58 | primaryCode: "", |
59 | }); | 59 | }); |
60 | wx.aldstat.sendEvent('进入页面', { | ||
61 | '页面名字': '打赏页' | ||
62 | }); | ||
60 | }, | 63 | }, |
61 | onShow() { | 64 | onShow() { |
62 | // this.checkAuth(); | 65 | // this.checkAuth(); | ... | ... |
1 | exports.app_key = "eb6daf8e1ce2e5e29de64d5ec1286fbc"; //请在此行填写从阿拉丁后台获取的appkey | 1 | exports.app_key = "eb6daf8e1ce2e5e29de64d5ec1286fbc"; //请在此行填写从阿拉丁后台获取的appkey |
2 | exports.getLocation = false; //默认不获取用户坐标位置 | 2 | exports.getLocation = false; //默认不获取用户坐标位置 |
3 | exports.plugin = false; //您的小程序中是否使用了插件。根据是否启用插件会有不同的接入方式,请参考文档文档。 | 3 | exports.plugin = false; //您的小程序中是否使用了插件。根据是否启用插件会有不同的接入方式,请参考文档文档。 |
4 | exports.useOpen = false; //默认不启用,是否启用openid计算,开启后必须上传openid,否则数据不会上报。 | 4 | exports.useOpen = true; //默认不启用,是否启用openid计算,开启后必须上传openid,否则数据不会上报。 | ... | ... |
-
Please register or sign in to post a comment