e3fcabea by simon

默认提交

1 parent 97275c2a
......@@ -2,7 +2,7 @@ let ENV_CONFIG = require('./env/index');
const APPID = ''
/** ====每次发布版本记得修改此环境配置==== */
const ENV = 'Dev'; // Dev Prod
const ENV = 'Prod'; // Dev Prod
const NET_CONFIG = ENV_CONFIG[ENV];
const MOCKAPI = ENV_CONFIG.mockApi;
......
......@@ -62,6 +62,7 @@ $contentWidth:690px;
&-ele {
display: flex;
align-items: center;
font-size: 22px;
@extend .bb;
......@@ -77,12 +78,12 @@ $contentWidth:690px;
color: #333333;
padding-left: 24px;
font-size: 20px;
font-size: 24px;
.t1 {
margin-left: 20px;
margin-top: 36px;
align-self: flex-start;
align-self: center;
}
......
......@@ -34,7 +34,8 @@
<view class="desc">
<view bindtap="queryAuctionRecordLast" class="refresh-btn">刷新价格</view>
<view class="desc-tit">{{productInfo.auctionName}}</view>
<view class="desc-t1">{{productInfo.auctionDescription}}</view>
<!-- <view class="desc-t1">{{productInfo.auctionDescription}}</view> -->
<text class="desc-t1">{{productInfo.auctionDescription}}</text>
<view class="desc-t1">活动区域:{{productInfo.district}}</view>
</view>
<!-- 线 -->
......
......@@ -7,7 +7,7 @@ let app = getApp();
Page({
data: {
authorizeVisible: false,
signTipsCompVisible:false,
signTipsCompVisible: false,
isInit: false,
total: 0,
page: 1,
......@@ -71,7 +71,7 @@ Page({
title: curData.auctionName
}
})
} else if(curData.isCanDetail == 2){
} else if (curData.isCanDetail == 2) {
this.setData({
signTipsCompVisible: true,
})
......@@ -148,7 +148,6 @@ Page({
this.toVipLoginHandler();
break;
// 暂不验证
case "_evt_not_verify":
this.hideMask();
......
......@@ -18,6 +18,7 @@ Page({
userInfo: {}, //用户信息
code: "", // 手输入码 / 扫出的奖金码
memberCode: "", // 扫出的用户码
isVerify: true, // 是否已经认证
},
onShareAppMessage() {},
showAuth() {
......@@ -49,7 +50,13 @@ Page({
this.queryProduct();
this.queryBanner();
if (m || c) {
let sessionId = app.store.getItem('sessionId');
if (!sessionId) {
this.setData({
isVerify: false
})
}
if (m || c || sessionId) {
this.initData();
}
},
......@@ -65,8 +72,21 @@ Page({
memberCode,
code
} = this.data;
if (memberCode) {
app.globalData.tlMemberCode = memberCode;
}
// 如果存在扫码参数,则需要拉用户身份(未授权的情况下 要拉授权)
this.queryMember().then((result) => {
let {
auditStatus
} = result;
if (auditStatus != "authorization") {
// 未认证用户
this.setData({
isVerify: false
})
}
// 扫用户码
this.queryScanPersonQrcode().then((result2) => {
// 查询奖金码
......@@ -101,6 +121,43 @@ Page({
console.log("officialAccountErrorFuc:", evt)
},
/**
* 检查验证修改
*/
checkVerify() {
let auditStatus = this.data.userInfo && this.data.userInfo.auditStatus || "";
if (auditStatus == "authorization") {
// 已经验证 去修改页,查看审核
this.toVipVerifyHandler();
} else if (auditStatus == "unauthorized") {
// 待验证 去修改页,查看审核
this.toVipVerifyHandler();
} else {
// 未验证 去编辑页,填写表单
this.toVipLoginHandler();
}
},
/**
* 去验证
*/
toVipLoginHandler() {
app.router.push({
path: "vipLogin"
})
},
/**
* 查看审核
*/
toVipVerifyHandler() {
app.router.push({
path: "vipVerify"
})
},
/**
* 请求产品
*/
......@@ -154,7 +211,7 @@ Page({
this.setData({
userInfo: result
})
resolve();
resolve(result);
})
});
},
......
......@@ -67,7 +67,7 @@ $contentWidth:670px;
height: 40px;
}
.icon-search{
.icon-search {
width: 36px;
height: 36px;
opacity: .6;
......@@ -79,7 +79,7 @@ $contentWidth:670px;
margin-left: 4px;
}
.t1{
.t1 {
font-size: 22px;
margin: 0 12px 0;
color: #808080;
......@@ -124,6 +124,7 @@ $contentWidth:670px;
// 产品
.product {
position: relative;
width: $contentWidth;
margin: 0 auto;
margin-top: 62px;
......@@ -172,3 +173,10 @@ $contentWidth:670px;
}
}
}
.verify-btn {
@include cb(100px, 48px, 24px);
position: absolute;
right: 0;
top: 4px;
}
......
......@@ -34,6 +34,7 @@
</swiper>
</view>
<view class="product">
<view bindtap="toVipLoginHandler" wx:if="{{!isVerify}}" class="verify-btn">去认证</view>
<view class="product-title">产品推荐{{codeStr}}</view>
<view class="product-list">
<!-- for循环 -->
......
......@@ -77,12 +77,12 @@ $contentWidth:690px;
color: #333333;
padding-left: 24px;
font-size: 20px;
font-size: 24px;
.t1 {
margin-left: 20px;
margin-top: 36px;
align-self: flex-start;
// margin-top: 36px;
align-self: center;
}
......
......@@ -34,7 +34,8 @@
<!-- 描述 -->
<view class="desc">
<view class="desc-tit">{{productInfo.seckillName}}</view>
<view class="desc-t1">{{productInfo.seckillDescription}}</view>
<!-- <view class="desc-t1">{{productInfo.seckillDescription}}</view> -->
<text class="desc-t1">{{productInfo.seckillDescription}}</text>
<view class="desc-t1">
秒杀数量:{{productInfo.minNum == productInfo.maxNum ? productInfo.minNum+'个' : productInfo.minNum+' - '+productInfo.maxNum+'个'}}
</view>
......
......@@ -7,7 +7,7 @@ let app = getApp();
Page({
data: {
authorizeVisible: false,
signTipsCompVisible:false,
signTipsCompVisible: false,
isInit: false,
total: 0,
page: 1,
......@@ -73,7 +73,7 @@ Page({
code: curData.seckillCode,
}
})
} else if(curData.isCanDetail == 2){
} else if (curData.isCanDetail == 2) {
this.setData({
signTipsCompVisible: true,
})
......@@ -148,7 +148,6 @@ Page({
this.hideMask();
break;
// 隐藏弹窗
case "_evt_hide_mask":
this.hideMask();
......
......@@ -275,12 +275,11 @@ Page({
*/
checkVerify() {
let auditStatus = this.data.userInfo && this.data.userInfo.auditStatus || "";
// console.log("@checkVerify || auditStatus:", auditStatus);
if (auditStatus == "authorization") {
// 已经验证 去修改页,查看审核
this.toVipVerifyHandler();
} else if (auditStatus == "unauthorized") {
// 已经验证 去修改页,查看审核
// 验证 去修改页,查看审核
this.toVipVerifyHandler();
} else {
// 未验证 去编辑页,填写表单
......
......@@ -7,6 +7,7 @@ let app = getApp();
Page({
data: {
authorizeVisible: false,
userInfo: {},
// form start
name: "",
shopName: "",
......@@ -43,6 +44,16 @@ Page({
this.initData();
},
initData() {
this.queryMember().then((result) => {
let auditStatus = this.data.userInfo && this.data.userInfo.auditStatus || "";
// console.log("viplogin - auditStatus:", auditStatus);
if (auditStatus == "authorization" || auditStatus == "unauthorized") {
// 未验证和待验证
app.router.push({
openType: "redirect",
path: "vipVerify"
})
} else {
this.getProvince();
this.getMemberType().then((result) => {
app.post({
......@@ -63,8 +74,30 @@ Page({
})
})
})
}
})
},
/**
* 获取会员信息
*/
queryMember() {
return new Promise((resolve, reject) => {
app.post({
url: app.api.member,
data: {}
}).then((result) => {
this.setData({
userInfo: result
})
resolve(result);
})
});
},
/**
* 获取用户类型
......