新手指引,福利,合作伙伴
This commit is contained in:
parent
6c7e23af54
commit
73ebcf34c4
@ -6,7 +6,11 @@ export default {
|
||||
getConfig:()=>request.get('/api/config'),
|
||||
community:{
|
||||
list:(data)=>request.get('/api/community',data),
|
||||
detail:(community_id)=>request.get(`/api/community/${community_id}`)
|
||||
detail:(community_id)=>request.get(`/api/community/${community_id}`),
|
||||
/**
|
||||
*data:{community_id,latitude,longitude}
|
||||
* */
|
||||
wxGroup:(community_id,data)=>request.get(`/api/community/${community_id}/qrcode`,data)
|
||||
},
|
||||
address:{
|
||||
list(commityId){
|
||||
|
||||
BIN
assets/icon/help/join-group.png
Normal file
BIN
assets/icon/help/join-group.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.2 KiB |
BIN
assets/icon/help/newbie.png
Normal file
BIN
assets/icon/help/newbie.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.6 KiB |
BIN
assets/icon/help/share.png
Normal file
BIN
assets/icon/help/share.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
@ -54,7 +54,13 @@ Page({
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
navToHowToUse(){
|
||||
if(this.data.appConfig&&this.data.appConfig.url_how_to_use){
|
||||
wx.navigateTo({
|
||||
url: `/pages/browser/index?url=${encodeURIComponent(this.data.appConfig.url_how_to_use)}`,
|
||||
})
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
|
||||
@ -71,13 +71,31 @@
|
||||
<button class="button" size="mini">一键登录</button>
|
||||
</navigator>
|
||||
</view> -->
|
||||
<navigator url="/pages/my/promation/wx-group/index?communityId={{currentCommunity.id}}"
|
||||
<view class="action-bar">
|
||||
<view bind:tap="navToHowToUse" class="item left">
|
||||
<image src="/assets/icon/help/newbie.png" class="icon"/>
|
||||
<view class="title">新手指南</view>
|
||||
<view class="sub-title">使用流程</view>
|
||||
</view>
|
||||
<navigator class="item"
|
||||
url="/pages/my/promation/wx-group/index?communityId={{currentCommunity.id}}">
|
||||
<image src="/assets/icon/help/join-group.png" class="icon"/>
|
||||
<view class="title">加福利群</view>
|
||||
<view class="sub-title">领优惠券</view>
|
||||
</navigator>
|
||||
<button class="item right share" open-type="share">
|
||||
<image src="/assets/icon/help/share.png" class="icon"/>
|
||||
<view class="title">邀请有礼</view>
|
||||
<view class="sub-title">赠送鸡蛋</view>
|
||||
</button>
|
||||
</view>
|
||||
<!-- <navigator url="/pages/my/promation/wx-group/index?communityId={{currentCommunity.id}}"
|
||||
class="promotion-panel" wx:if="{{currentCommunity.id}}" wx:if="{{appConfig&&appConfig.join_group_title}}">
|
||||
<view class="title right-arrow">
|
||||
{{appConfig.join_group_title}}
|
||||
</view>
|
||||
<view class="sub-title">{{appConfig.join_group_desc}}</view>
|
||||
</navigator>
|
||||
</navigator> -->
|
||||
</view>
|
||||
<page-container show="{{isShowOrderConfirm}}" round close-on-slide-down
|
||||
bind:enter="enterPageContainer" bind:leave="leavePageContainer" wx:if="{{isShowOrderConfirm}}">
|
||||
|
||||
@ -111,6 +111,34 @@
|
||||
.order-button{
|
||||
margin:40rpx 20rpx!important;
|
||||
}
|
||||
.action-bar{
|
||||
display: flex;
|
||||
background-color: #fff;
|
||||
text-align: center;
|
||||
margin:36rpx 20rpx;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
.action-bar .item{
|
||||
flex:1;
|
||||
padding:34rpx 40rpx 30rpx 40rpx
|
||||
}
|
||||
.action-bar .share{
|
||||
background-color: #fff;
|
||||
}
|
||||
.action-bar .title{
|
||||
font-size: 28rpx;
|
||||
font-weight: 500;
|
||||
margin-top:26rpx;
|
||||
color: var(--main-font-color);
|
||||
}
|
||||
.action-bar .sub-title{
|
||||
font-size: 24rpx;
|
||||
color: #888888;
|
||||
margin-top:20rpx;
|
||||
}
|
||||
.action-bar .icon{
|
||||
width:52rpx;height:52rpx;
|
||||
}
|
||||
|
||||
.promotion-panel{
|
||||
border: 1rpx solid rgba(255, 195, 0, 0.5);
|
||||
|
||||
@ -42,6 +42,11 @@ Page({
|
||||
// bgHeight:'100%'
|
||||
// });
|
||||
},
|
||||
applyPartnert(){
|
||||
wx.navigateTo({
|
||||
url: `/pages/browser/index?url=${encodeURIComponent(this.data.appConfig.url_partner_apply)}`,
|
||||
})
|
||||
},
|
||||
shareFriend(){
|
||||
|
||||
},
|
||||
|
||||
@ -67,4 +67,11 @@
|
||||
<view class="cell-ft"></view>
|
||||
</button>
|
||||
</view>
|
||||
<view class="recruit-view">
|
||||
<view class="title">
|
||||
<view class="text">招募城市合伙人</view>
|
||||
<button class="button" type="primary" size="mini" bind:tap="applyPartnert">立即申请</button>
|
||||
</view>
|
||||
<view class="sub-title">人人都有金饭碗, 钱多事好离家近</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
@ -96,3 +96,34 @@
|
||||
.cell.is-button:hover{
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.recruit-view{
|
||||
box-shadow: 0px 3px 6px 2px rgba(0, 0, 0, 0.04);
|
||||
background: linear-gradient(270deg, #FCF7E8 34%, #FCF1CE 76%);
|
||||
margin:30rpx 20rpx;
|
||||
border-radius: 20rpx;
|
||||
color: #DFAB00;
|
||||
padding:30rpx 30rpx 30rpx 40rpx;
|
||||
}
|
||||
.recruit-view .title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.recruit-view .title .button{
|
||||
font-size: 26rpx;
|
||||
font-weight: normal;
|
||||
background: linear-gradient(180deg, #FFE285 0%, #FFC91B 100%);
|
||||
box-shadow: 0px 3px 4px 0px rgba(196, 149, 0, 0.2);
|
||||
padding:14rpx 26rpx;
|
||||
line-height: 1;
|
||||
color: #664E00;
|
||||
}
|
||||
.recruit-view .title .text{
|
||||
font-size: 42rpx;
|
||||
flex:1
|
||||
}
|
||||
.recruit-view .sub-title{
|
||||
font-size: 29rpx;
|
||||
margin-top:26rpx;
|
||||
font-style: italic;
|
||||
}
|
||||
@ -1,5 +1,6 @@
|
||||
import commonApi from '../../../../api/common';
|
||||
import {getStatusNavBarHeight} from '../../../../utils/util'
|
||||
import {getStatusNavBarHeight} from '../../../../utils/util';
|
||||
const app = getApp();
|
||||
Page({
|
||||
|
||||
/**
|
||||
@ -8,23 +9,52 @@ Page({
|
||||
data: {
|
||||
detail:{},
|
||||
navbarHeight:getStatusNavBarHeight(),
|
||||
test:''
|
||||
communityId:'',
|
||||
positioning:false,
|
||||
positioningError:false,
|
||||
detailPosition:{},
|
||||
qrcodeLoading:false
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad(options) {
|
||||
this.data.communityId = options.communityId;
|
||||
this.setData({
|
||||
navbarHeight:getStatusNavBarHeight()
|
||||
})
|
||||
commonApi.community.detail(options.communityId).then((data)=>{
|
||||
commonApi.community.detail(this.data.communityId).then((data)=>{
|
||||
this.setData({
|
||||
detail:data
|
||||
})
|
||||
})
|
||||
this.getWxGroupQrcode();
|
||||
},
|
||||
getWxGroupQrcode(){
|
||||
this.setData({
|
||||
positioning:true,
|
||||
qrcodeLoading:true
|
||||
})
|
||||
app.getLocation().then((data)=>{
|
||||
this.setData({
|
||||
positioning:false,
|
||||
positioningError:false
|
||||
})
|
||||
commonApi.community.wxGroup(this.data.communityId,{latitude:data.latitude,longitude:data.longitude}).then((res)=>{
|
||||
this.setData({
|
||||
detailPosition:res,
|
||||
qrcodeLoading:false
|
||||
})
|
||||
})
|
||||
}).catch(()=>{
|
||||
this.setData({
|
||||
positioning:false,
|
||||
qrcodeLoading:false,
|
||||
positioningError:true
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
|
||||
@ -18,8 +18,18 @@
|
||||
</view>
|
||||
<view class="bottom">
|
||||
<view class="qrcode-area">
|
||||
<image src="{{detail.optimized_qy_group_qrcode}}" class="image" show-menu-by-longpress/>
|
||||
<view class="weui-loading" wx:if="{{qrcodeLoading}}"></view>
|
||||
<view class="error" wx:elif="{{positioningError||!detailPosition.show_qrcode}}">
|
||||
<view bind:tap="getWxGroupQrcode" class="retry" wx:if="{{positioningError}}">
|
||||
定位失败
|
||||
</view>
|
||||
<view class="tips">点击图中二维码识别</view>
|
||||
<view wx:else>超出服务距离</view>
|
||||
<view>无法显示二维码</view>
|
||||
</view>
|
||||
<image wx:else class="image" show-menu-by-longpress
|
||||
src="{{detailPosition.community.optimized_qy_group_qrcode}}"/>
|
||||
|
||||
</view>
|
||||
<view class="tips" wx:if="{{detailPosition&&detailPosition.show_qrcode}}">点击图中二维码识别</view>
|
||||
</view>
|
||||
</view>
|
||||
@ -58,10 +58,20 @@ page{
|
||||
text-align: center;
|
||||
border-radius: 30rpx;
|
||||
border:20rpx solid rgba(254, 196, 0, 0.15);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 36rpx;
|
||||
color: rgba(153, 153, 153, 0.8);
|
||||
line-height: 66rpx;
|
||||
}
|
||||
.qrcode-area .image{
|
||||
width:100%;height:100%;
|
||||
}
|
||||
.qrcode-area .retry{
|
||||
text-decoration: underline;
|
||||
color: red;
|
||||
}
|
||||
.bottom .tips{
|
||||
font-size: 36rpx;
|
||||
font-weight: 500;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user