Commit bb102297 by 程南

2020.05.11版本

parent 1555f235
......@@ -43,7 +43,7 @@ App({
// console.log(err);
}
// this.loginSilently();
this.loginSilently();
},
loginSilently() {
......
......@@ -110,7 +110,9 @@
"pages/payCardInfo/payCardInfo",
"pages/moneyBuyCoupon/moneyBuyCoupon",
"pages/moneyBuyCouponInfo/moneyBuyCouponInfo",
"pages/moneyBuyCouponRecords/moneyBuyCouponRecords"
"pages/moneyBuyCouponRecords/moneyBuyCouponRecords",
"pages/TimelimitedSales/TimelimitedSales",
"pages/belongWithGuide/belongWithGuide"
]
},
{
......
......@@ -16,6 +16,9 @@
<template name="water-list">
<navigator hover-class="none" url="/pages/productDetail/productDetail?id={{productId}}">
<view class="item">
<image wx:if="{{isFlashSale}}" class="limited-icon" src="https://img3.bigaka.com/prd/3001/202005/20200508/3001a6dcdf69-369a-4f43-8757-60f071946ea8.png" />
<!-- 图片主图时 -->
<image class="item-img"
src="{{indexUrl}}"
......@@ -34,11 +37,20 @@
<view class="item-title">{{productName}}</view>
</view>
<view class="pro-price-wrap">
<view class="pro-plus-price">
<view class="pro-plus-price" wx:if="{{falshSaleActivityPrice}}">
<text>¥</text>
<text class="plus-price">{{utils.numberFormat(falshSaleActivityPrice / 100)}}</text>
<text class="sale-price">¥{{utils.numberFormat(minSalePrice / 100)}}</text>
</view>
<view class="pro-plus-price" wx:if="{{!falshSaleActivityPrice}}">
<text>¥</text>
<text class="plus-price">{{memberPrice ? utils.numberFormat(memberPrice / 100) : utils.numberFormat(minSalePrice / 100)}}</text>
<image wx:if="{{memberPrice}}" mode="widthFix" src="/assets/imgs/7_1_0/member-icon.png"></image>
</view>
<view class="pro-member-price" wx:if="{{plusPrice}}">
<text>¥</text>
<text class="member-price">{{utils.numberFormat(plusPrice / 100)}}</text>
......
......@@ -11,7 +11,22 @@
border-radius: 10rpx;
box-shadow: 0px 2px 5px 0px rgba(199, 199, 199, 0.5);
padding-bottom: 24rpx;
position: relative;
}
.sale-price{
color: rgba(170, 170, 170, 1);
font-size: 22rpx;
margin-left: 12rpx;
text-decoration: line-through;
}
.limited-icon{
position: absolute;
height: 36rpx;
width: 91rpx;
top: 0;
left: 0;
}
.item-ava{
width: 40rpx;
height: 40rpx;
......
<!--component/productListStyleTwo/productListStyleTwo.wxml-->
<!-- component/productListStyleTwo/productListStyleTwo.wxml -->
<wxs src="../../wxs/utils.wxs" module="utils" />
<block wx:for="{{imageData}}" wx:key="*this" wx:for-item="item">
<navigator hover-class="none" url="/pages/productDetail/productDetail?id={{item.productId}}">
<view class="hot-item border_box" >
<view class="hot-item border_box">
<view class="hot-img-box">
<image class="hot-img"
src="{{item.indexUrl}}"
mode="aspectFit" lazy-load
wx:if="{{!utils.isVideo(item.indexUrl)}}"/>
<video id="myVideo"
class="hot-img"
src="{{item.indexUrl}}"
muted
wx:if="{{utils.isVideo(item.indexUrl)}}"></video>
<image wx:if="{{item.isFlashSale}}" class="limited-icon" src="https://img3.bigaka.com/prd/3001/202005/20200508/3001a6dcdf69-369a-4f43-8757-60f071946ea8.png" />
<image class="hot-img" src="{{item.indexUrl}}" mode="aspectFit" lazy-load wx:if="{{!utils.isVideo(item.indexUrl)}}" />
<video id="myVideo" class="hot-img" src="{{item.indexUrl}}" muted wx:if="{{utils.isVideo(item.indexUrl)}}"></video>
</view>
<view class="hot-item-desc border_box">
<view class="item-name">{{item.productName}}</view>
<!-- <view class="item-desc">{{item.productStatusDesc}}</view>-->
<!-- <view class="item-desc">{{item.productStatusDesc}}</view> -->
<view class="item-vip-price weui-flex">
<text class="vip-sale-price border_box">
<text class="vip-sale-price border_box" wx:if="{{item.falshSaleActivityPrice}}">
¥{{utils.numberFormat(item.falshSaleActivityPrice / 100)}}<text class="sale-price">¥{{utils.numberFormat(item.minSalePrice / 100)}}</text>
</text>
<text class="vip-sale-price border_box" wx:if="{{!item.falshSaleActivityPrice}}">
¥{{item.memberPrice ? utils.numberFormat(item.memberPrice / 100) : utils.numberFormat(item.minSalePrice / 100)}}
</text>
<view class="" >
<image
class="item-vip"
src="https://img3.bigaka.com/prd/3001/202003/20200309/3001918ef881-b117-44da-8cfe-72e26f051e29.png"
mode="widthFix"
wx:if="{{item.memberPrice}}"
/>
<view class="">
<image class="item-vip" src="https://img3.bigaka.com/prd/3001/202003/20200309/3001918ef881-b117-44da-8cfe-72e26f051e29.png" mode="widthFix" wx:if="{{item.memberPrice}}" />
</view>
<!-- <text class="vip-original-price">¥189</text> -->
</view>
<view class="item-plus-price weui-flex" wx:if="{{item.plusPrice}}">
<text class="vip-plus-price vip-sale-price border_box">¥{{utils.numberFormat(item.plusPrice / 100)}}</text>
<text class="vip-plus-price vip-sale-price border_box">
¥{{utils.numberFormat(item.plusPrice / 100)}}
</text>
<view class="">
<image
class="item-plus"
src="https://img3.bigaka.com/prd/3001/202003/20200309/3001fce746fd-c6f9-4016-bc0a-9aee0ac93f7a.png"
mode="widthFix"
lazy-load="false"
/>
<image class="item-plus" src="https://img3.bigaka.com/prd/3001/202003/20200309/3001fce746fd-c6f9-4016-bc0a-9aee0ac93f7a.png" mode="widthFix" lazy-load="false" />
</view>
</view>
<view/>
<view />
</view>
</view>
</navigator>
</block>
\ No newline at end of file
......@@ -17,6 +17,22 @@
border-top-left-radius: 10rpx;
border-bottom-left-radius: 10rpx;
}
.sale-price{
color: rgba(170, 170, 170, 1);
font-size: 22rpx;
margin-left: 12rpx;
text-decoration: line-through;
}
.hot-img-box{
position: relative;
}
.limited-icon{
position: absolute;
height: 36rpx;
width: 91rpx;
top: 0;
left: 0;
}
.hot-item-desc {
margin-left: 28rpx;
margin-top: 33rpx;
......@@ -71,7 +87,7 @@
text-decoration: line-through;
}
.vip-plus-price {
color: #cb3c3c;
color: rgba(203, 60, 60, 1);
}
.buy-btn {
text-align: right;
......
<!--component/scrollDel/scrollDel.wxml-->
<!--<scroll-view scroll-y="{{isScroll}}" style='height:{{windowHeight}}px'>-->
<!-- component/scrollDel/scrollDel.wxml -->
<!-- <scroll-view scroll-y="{{isScroll}}" style='height:{{windowHeight}}px'> -->
<wxs src="../../wxs/utils.wxs" module="utils" />
<scroll-view scroll-y="{{isScroll}}">
<block class="cart-item" wx:key="item" wx:for="{{cartList}}">
<view data-index='{{index}}'
class="order-item cart-list"
bindtouchstart="drawStart"
bindtouchmove="drawMove"
bindtouchend="drawEnd"
style="right:{{item.right}}rpx">
<!--遮盖层 -->
<view data-index='{{index}}' class="order-item cart-list" bindtouchstart="drawStart" bindtouchmove="drawMove" bindtouchend="drawEnd" style="right:{{item.right}}rpx">
<!-- 遮盖层 -->
<view data-index="{{index}}" class="checke-item" catchtap="checkPro">
<icon size="18" type="{{item.checked ? 'success' : 'circle'}}" color="{{checkedColor}}" data-index="{{index}}" ></icon>
<icon size="18" type="{{item.checked ? 'success' : 'circle'}}" color="{{checkedColor}}" data-index="{{index}}"></icon>
</view>
<!-- bindtap="bindTapItem" data-id="{{item.id}}" -->
<!-- productStatus 0未发布1下架2上架3删除 -->
<view class="pro-info" bindtap="bindTapItem" data-id="{{item.productId}}"
style='border-bottom:{{index == (cartList.length -1) ? "none" : "1rpx solid #eeeeee" }};opacity:{{(item.productStatus == 0 || item.productStatus == 1 || item.productStatus == 3) ? 0.2 : 1}};'>
<image class="pro-img" src="{{item.skuImgUrl}}"
wx:if="{{!utils.isVideo(item.skuImgUrl)}}"
mode="widthFix"></image>
<video id="myVideo"
class="hot-img"
src="{{item.skuImgUrl}}"
muted
wx:if="{{utils.isVideo(item.skuImgUrl)}}"></video>
<view class="pro-info" bindtap="bindTapItem" data-id="{{item.productId}}" style='border-bottom:{{index == (cartList.length -1) ? "none" : "1rpx solid #eeeeee" }};opacity:{{(item.productStatus == 0 || item.productStatus == 1 || item.productStatus == 3) ? 0.2 : 1}};'>
<image wx:if="{{item.activityPrice}}" class="limited-icon" src="https://img3.bigaka.com/prd/3001/202005/20200508/3001a6dcdf69-369a-4f43-8757-60f071946ea8.png" />
<image class="pro-img" src="{{item.skuImgUrl}}" wx:if="{{!utils.isVideo(item.skuImgUrl)}}" mode="widthFix"></image>
<video id="myVideo" class="hot-img" src="{{item.skuImgUrl}}" muted wx:if="{{utils.isVideo(item.skuImgUrl)}}"></video>
<view class="pro-right-info">
<view class="pro-name">{{item.productName}}</view>
<view class="pro-sku">{{item.skuSpec}}</view>
<view class="pro-price">
<view class="price">¥{{item.price}}</view>
<view class="price">
<text >¥{{item.activityPrice?item.activityPrice:item.price}}</text>
<text class="sale-price" wx:if="{{item.activityPrice}}">¥{{item.price}}</text>
</view>
<view class="pro-num-edit">
<button class="redus-num" data-index="{{index}}" catchtap="minusNum">-</button>
<input class="pro-num-edit-input" disabled type="number"
data-index="{{index}}" catchtap bindblur="blurNum" bindinput="inputNum" value="{{item.count}}"></input>
<button class="add-num" data-index="{{index}}" catchtap="addNum">+</button>
<button class="redus-num" data-index="{{index}}" catchtap="minusNum">
-
</button>
<input class="pro-num-edit-input" disabled type="number" data-index="{{index}}" catchtap bindblur="blurNum" bindinput="inputNum" value="{{item.count}}"></input>
<button class="add-num" data-index="{{index}}" catchtap="addNum">
+
</button>
</view>
</view>
</view>
</view>
<view class="remove" data-index="{{index}}" data-skuId="{{item.skuId}}" bindtap="delItem">
删除
</view>
<view class="remove" data-index="{{index}}" data-skuId="{{item.skuId}}" bindtap="delItem">删除 </view>
</view>
</block>
</scroll-view>
\ No newline at end of file
......@@ -10,7 +10,7 @@
width: 132rpx;
height: 100%;
/* background-color: rgba(149, 149, 149, 1); */
background-color: var(--themecolor);
background-color: #cb3c3c;
color: white;
position: absolute;
top: 0;
......@@ -23,9 +23,26 @@
display: flex;
overflow: hidden;
}
.pro-info{
position: relative;
}
.sale-price{
color: rgba(170, 170, 170, 1);
font-size: 22rpx;
margin-left: 12rpx;
text-decoration: line-through;
}
.cart-item:last-child .pro-info{
border-bottom: none;
}
.limited-icon{
position: absolute;
height: 36rpx;
width: 91rpx;
top: 0;
left: 0;
}
.pro-info:last-child{
border-bottom: none;
......
......@@ -11,10 +11,6 @@ Component({
type: Boolean,
type: false
},
currentHasMobile : {
type: Boolean,
type: false
},
disableNum: { // 不能改变的数量
type: Number,
observer: '_disableNumChange',
......@@ -150,12 +146,6 @@ Component({
* 组件的方法列表
*/
methods: {
//获取手机号回调
getPhoneNumber(res = {}){
wxService.nextTick(() => {
this.triggerEvent('getMobile', res);
})
},
confirm() {
if (this.data.curSpec.length < 1){
wx.showToast({
......@@ -321,7 +311,7 @@ Component({
if (flag) {
this.setData({
skuStock: this.data.skuInfos[i].stock,
salePrice: this.data.skuInfos[i].salePrice,
salePrice: this.data.skuInfos[i].activityPrice ? this.data.skuInfos[i].activityPrice : this.data.skuInfos[i].salePrice ,
picUrl: this.data.skuInfos[i].picUrl,
skuId: this.data.skuInfos[i].skuId
})
......@@ -357,7 +347,7 @@ Component({
if (flag) {
skuStock = item.stock
skuId = item.skuId
salePrice = item.salePrice
salePrice = item.activityPrice ? item.activityPrice : item.salePrice
picUrl = item.picUrl
}
......
......@@ -81,27 +81,32 @@
</scroll-view>
<!-- 按钮状态 -->
<view wx:if="{{!currentHasMobile}}">
<!-- <button
bindgetuserinfo="_getUserInfo"
data-jflag="false"
open-type='getUserInfo'
<button
bindgetphonenumber="getPhoneNumber"
open-type='getPhoneNumber'
class="confirm-button {{isOutStock? 'out-stock': ''}}"
hover-class="btn-hover"
>
{{btnText}}
</button> -->
</button>
</view>
<view wx:else>
<button class="confirm-button {{isOutStock? 'out-stock': ''}}" bindtap="confirm">{{btnText}}</button>
</view>
<!-- <view wx:if="{{!currentHasUserInfo}}">
<button
bindgetphonenumber="getPhoneNumber"
open-type='getPhoneNumber'
bindgetuserinfo="_getUserInfo"
data-jflag="false"
open-type='getUserInfo'
class="confirm-button {{isOutStock? 'out-stock': ''}}"
hover-class="btn-hover"
>
{{btnText}}
</button>
</view>
<view wx:else>
<button class="confirm-button {{isOutStock? 'out-stock': ''}}" bindtap="confirm">{{btnText}}</button>
</view>
</view> -->
</view>
......@@ -99,7 +99,8 @@ Component({
})
},
handelToVipCode() {
wxService.router(`/pages/memberOfOwn/memberOfOwn`)
// wxService.router(`/pages/memberOfOwn/memberOfOwn`)
wxService.openCard();
},
handelToCart() {
wxService.router(`/pages/cart/cart`)
......
......@@ -6,7 +6,7 @@
// 修改 BRANCH_ID 为对应的商户id
// app.js 中brandId 修改为对应
const PROJECT_ENV = 'dev' // 生产 prod, 开发 dev, 测试 test , 测试门户 test_store, 预生产 pre
const PROJECT_ENV = 'test' // 生产 prod, 开发 dev, 测试 test , 测试门户 test_store, 预生产 pre
//仅生产环境时 配置 :
//3001 3001 , wx313ec36b710125d4 有直播
//2006 泰华 , wx40fec8944623c8b3 有直播
......@@ -25,7 +25,7 @@ const PROJECT_ENV = 'dev' // 生产 prod, 开发 dev, 测试 test , 测试门户
//2992 山东盛联微商城 wx53dedc202ae0d0c2
//2002 巴黎贝甜 wx21968cb3a486d4ab
const BRANCH_ID = 1001
const BRANCH_ID = 1002
const isMall = true
// const needMock = '' //
......@@ -82,127 +82,7 @@ const prod_brand_config = {
refundTips : '温馨提示:退货通过审核后需将清单随包裹一起寄回或纸条备注(订单号与退货商品款号)【请务必审核通过后24小时内填写寄回运单号,拒签到付/顺丰/EMS/天天快递 不影响二次销售】',//退货须知文本
//wx654ce96a7324e76f 小程序微信支付券
},
//泰华配置
2006: {
appId: 'wx40fec8944623c8b3', //商城小程序appid
storeAppId: 'wx833d5ece112fc3fd',//门户小程序appid
tunnelToken: '8724303981a00b56869f3d26f7a6c643',
brandId: 2006,
plusIsOpen: false,
contactUsIsOpen: isMall ? true : false,
canUseWechatAddress: false,//是否使用获取微信地址
contactUsPluginId: 'a6ea55b56eb09ced8f9aeeaa14383b52',
hasTrial: false,
isMall: isMall,
hasLiveVideo: true,//是否有直播功能
orderingMustOpenCard: true,
themeColor: '#cb3c3c',//主题颜色
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
isOpenSelfMention: true, // 是否开启门店自提
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【泰华微商城】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/30017df01559-a34f-4106-81a6-3e2ed7e6304c.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//多多一上
2007 : {
appId: 'wxf7bc302c51166dc0',
tunnelToken: '1ea3f0c0dd0c91ee54e546a99beafbfb',
brandId: 2007,
plusIsOpen: false,
themeColor: '#cb3c3c',//主题颜色
contactUsIsOpen: true,
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
canUseWechatAddress: false,//是否使用获取微信地址
contactUsPluginId: '78353bb39251a60b473f3d4ae81b1c39',
hasTrial: false,
isMall: isMall,
hasLiveVideo: true,//是否有直播功能
orderingMustOpenCard: true,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
isOpenSelfMention: false, // 是否开启门店自提
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【多多一上】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/30013df6a0c2-7f3f-4475-8657-5c0ac87e02de.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//雪岛书屋
2008 : {
appId: 'wx207f8a95bbc9d3ab',
tunnelToken: 'd93a5def7511da3d0f2d171d9c344e91',
brandId: 2008,
plusIsOpen: false,
contactUsIsOpen: false,
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
canUseWechatAddress: false,//是否使用获取微信地址
contactUsPluginId: '',
themeColor: '#cb3c3c',//主题颜色
hasTrial: false,
isMall: isMall,
hasLiveVideo: false,//是否有直播功能
orderingMustOpenCard: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isOpenSelfMention: false, // 是否开启门店自提
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【雪岛书屋】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001842823fb-2601-4b58-a648-79ad799ad425.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//苏州邻里
2003 : {
appId: 'wxe7770946f9d93d38',
tunnelToken: 'fde4fde168dd5aabe962643843c19290',
brandId: 2003,
plusIsOpen: false,
contactUsIsOpen: false,
contactUsPluginId: '',
themeColor: '#cb3c3c',//主题颜色
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
canUseWechatAddress: false,//是否使用获取微信地址
hasTrial: false,
hasLiveVideo: false,//是否有直播功能
isMall: isMall,
orderingMustOpenCard: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isOpenSelfMention: false, // 是否开启门店自提
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【苏州邻里】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001842823fb-2601-4b58-a648-79ad799ad425.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//拉如小程序
2009 : {
appId: 'wxa0db9cb42b1cbdc9',// 小程序AppID
tunnelToken: '2c626cb97cd05b635ae85ace7acb5608',//商户默认token
brandId: 2009,//商户ID
plusIsOpen: false,//下单和下单状态界面是否显示购买plus
contactUsIsOpen: false,//是否开启联系我
contactUsPluginId: '',//联系我们插件PluginID
hasTrial: false,// 是否有体验账号
hasLiveVideo: false,//是否有直播功能
themeColor: '#cb3c3c',//主题颜色
canUseWechatAddress: false,//是否使用获取微信地址
isMall: isMall,// 商城或门户 true 商城 false 门户
orderingMustOpenCard: false,//下单是否必须卡开
isOpenSelfMention: false, // 是否开启门店自提
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【LA RUTA DE VIA】',//分享海报上显示的小程序title
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001c17ed02e-7c2b-4b61-a81d-f8dcde3301df.jpg',//商户logo
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//热风
2010 : {
appId: 'wxe6d270a3e399ade9',
......@@ -226,202 +106,8 @@ const prod_brand_config = {
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001377a0bb9-8f7f-4b40-8966-9fc5f8a69cdd.png',
openRefundTips : true,//是否开启退货须知显示
refundTips : '温馨提示:退货通过审核后需将清单随包裹一起寄回或纸条备注(订单号与退货商品款号)【请务必审核通过后24小时内填写寄回运单号,拒签到付/顺丰/EMS/天天快递 不影响二次销售】',//退货须知文本
},
//悦芙媞
2012 : {
appId: 'wxfe14ebde4a6eea3d',
tunnelToken: '6293879e905cd6504386f5bbc8c61926',
brandId: 2012,
plusIsOpen: false,
contactUsIsOpen: true,
canUseWechatAddress: false,//是否使用获取微信地址
contactUsPluginId: '6d310b33ba27c784fb6872942a57711d',
hasTrial: false,
hasLiveVideo: true,//是否有直播功能
themeColor: '#cb3c3c',//主题颜色
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
isMall: isMall,
orderingMustOpenCard: true,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isOpenSelfMention: true, // 是否开启门店自提
isNeedGetLocation: true,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【悦芙媞微商城】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/30010a5f2325-9818-455d-a707-e8afc373701e.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//阿特里里
2013 : {
appId: '',
tunnelToken: 'ef7bf4d1adcf8ee5d57a2450255ecc27',
brandId: 2013,
plusIsOpen: false,
contactUsIsOpen: true,
contactUsPluginId: '',
hasTrial: false,
hasLiveVideo: false,//是否有直播功能
themeColor: '#cb3c3c',//主题颜色
isMall: isMall,
canUseWechatAddress: false,//是否使用获取微信地址
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
orderingMustOpenCard: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
isOpenSelfMention: false, // 是否开启门店自提
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【阿特里里微商城】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001842823fb-2601-4b58-a648-79ad799ad425.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//包鞋
2014: {
appId: '',
tunnelToken: 'd1637a225cfe0f61a72967a74a872a7f',
brandId: 2014,
plusIsOpen: false,
contactUsIsOpen: true,
contactUsPluginId: '',
hasLiveVideo: false,//是否有直播功能
hasTrial: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
canUseWechatAddress: false,//是否使用获取微信地址
isMall: isMall,
themeColor: '#cb3c3c',//主题颜色
orderingMustOpenCard: false,
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isOpenSelfMention: false, // 是否开启门店自提
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【包鞋微商城】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001842823fb-2601-4b58-a648-79ad799ad425.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//2015花在花园里
2015 : {
appId: 'wx8a35f9a57afd13e9',
tunnelToken: 'fa2816369abd2726d18b2a0dd51736f4',
brandId: 2015,
plusIsOpen: false,
contactUsIsOpen: false,
contactUsPluginId: '',
hasTrial: false,
isMall: isMall,
themeColor: '#cb3c3c',//主题颜色
canUseWechatAddress: false,//是否使用获取微信地址
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
orderingMustOpenCard: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
isOpenSelfMention: false, // 是否开启门店自提
hasLiveVideo : false,//是否有直播功能
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【花在花园里~】',
logo: 'https://img3.bigaka.com/prd/3001/202004/20200410/30019e5121d1-5e2c-49b6-b807-1dbf1481b361.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//阿吉豆
2016: {
appId: '',
tunnelToken: 'bac535a06a04adaa8e6660e22c64b257',
brandId: 2016,
plusIsOpen: false,
contactUsIsOpen: true,
contactUsPluginId: '',
hasTrial: false,
themeColor: '#cb3c3c',//主题颜色
isMall: isMall,
hasLiveVideo: false,//是否有直播功能
canUseWechatAddress: false,//是否使用获取微信地址
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
orderingMustOpenCard: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
isOpenSelfMention: false, // 是否开启门店自提
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【阿吉豆微商城】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001842823fb-2601-4b58-a648-79ad799ad425.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//【ACTREE】
2017: {
appId: 'wx2aae34874e88cdf5',
tunnelToken: '5b621e41ea6ed4ad302c5d07b8685c32',
brandId: 2017,
plusIsOpen: false,
contactUsIsOpen: true,//是否显示联系我插件
contactUsPluginId: 'fbe3bb6f88e7331ca719713910c164a2',//联系我插件
hasLiveVideo: false,//是否有直播功能
hasTrial: false,
themeColor: '#cb3c3c',//主题颜色
canUseWechatAddress: false,//是否使用获取微信地址
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
isMall: isMall,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
orderingMustOpenCard: true,
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isOpenSelfMention: false, // 是否开启门店自提
isNeedGetLocation: false,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【ACTREE】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001df8c09f7-8e9b-4901-8627-a533daf2bf8d.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//山东盛联微商城
2992 : {
appId: 'wx53dedc202ae0d0c2',
tunnelToken: 'f6c5031d172d94b6574293ef954a6f2d4e16657',
brandId: 2992,
plusIsOpen: true,
contactUsIsOpen: true,
contactUsPluginId: '50934d036dc2051758f4d934d7100b78',
hasTrial: false,
isMall: isMall,
themeColor: '#cb3c3c',//主题颜色
canUseWechatAddress: false,//是否使用获取微信地址
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
orderingMustOpenCard: true,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
isOpenSelfMention: true, // 是否开启门店自提
hasLiveVideo: false,//是否有直播功能
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: true,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【山东盛联微商城】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200331/3001edfaf8b7-0f9f-4d3e-8a74-73ed7398a4bc.jpg',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
},
//2002 巴黎贝甜
2002 : {
appId: 'wx21968cb3a486d4ab',
tunnelToken: '50a322b1d197d6213a2bbe75016da3d9',
brandId: 2002,
plusIsOpen: false,
contactUsIsOpen: false,
contactUsPluginId: '',
hasTrial: true,
themeColor: '#cb3c3c',//主题颜色
isMall: isMall,
canUseWechatAddress: false,//是否使用获取微信地址
touchPointStorageTime: 30 * 60 * 1000,//单位毫秒
orderingMustOpenCard: false,
canRefundDaysAfterDelivery: 15,//发货后多少天之内可显示申请退款按钮
isOpenSelfMention: true, // 是否开启门店自提
hasLiveVideo : false,//是否有直播功能
guiderCanScanQrcode: true,//导购是否有扫一扫功能
isNeedGetLocation: true,//是否开启小程序获取位置(提交订单时获取门店信息)
shareTitle: '【有一种甜叫巴黎贝甜~】',
logo: 'https://img3.bigaka.com/prd/3001/202003/20200318/3001c0647584-3656-45e9-ae60-c898d435113e.png',
openRefundTips : false,//是否开启退货须知显示
refundTips : '',//退货须知文本
//要跳转的外部小程序appid
// "wxa006e9b0a0ee1bfe", 外卖
// "wx39b5d8891f375d1c" 礼品卡
},
}
}
......
// pages/cart/cart.js
const app = getApp()
const wxService = require('../../utils/wxService')
const app = getApp()
wxService.page({
/**
......@@ -19,7 +19,7 @@ wxService.page({
checkAll: false,
checkedColor: app.globalData.themeColor,
shopCartTotalFee: 0, // 商品总价
invalidCarts : []
invalidCarts: []
},
/**
......@@ -48,8 +48,8 @@ wxService.page({
}
this.setData({
checkAll : false,
shopCartTotalFee : 0,
checkAll: false,
shopCartTotalFee: 0,
});
this.init()
......@@ -79,26 +79,30 @@ wxService.page({
//这里进行区分已经失效和未失效
// productStatus 0未发布1下架2上架3删除
let invalidCarts = [], validateCarts = [];
list.forEach(item=>{
list.forEach(item => {
if(item.activityPrice){
// item.price = (item.activityPrice/10/10).toFixed(2)
item.activityPrice = (item.activityPrice/10/10).toFixed(2)
}
item.checked = false;
if(item.productStatus == 2){
if (item.productStatus == 2) {
validateCarts.push(item);
}
else{
else {
invalidCarts.push(item);
}
});
this.setData({
cartList: validateCarts,
invalidCarts : invalidCarts,
checkAll : false,
shopCartTotalFee : 0,
invalidCarts: invalidCarts,
checkAll: false,
shopCartTotalFee: 0,
})
}
}
if(refresh){
if (refresh) {
wx.showToast({
title: '刷新成功',
});
......@@ -136,7 +140,7 @@ wxService.page({
addNumChange(e) {
this.addNum(e.detail)
},
addNum (e) { // 增加数量
addNum(e) { // 增加数量
var cartList = this.data.cartList
// var proNum = cartList[e.currentTarget.dataset.index].count
var proNum = cartList[e].count
......@@ -164,7 +168,7 @@ wxService.page({
blurNumChange(e) {
this.blurNum(e.detail)
},
blurNum (e) {
blurNum(e) {
var newNum = e.value
// var newNum = e.detail.value
var cartList = this.data.cartList
......@@ -233,7 +237,7 @@ wxService.page({
cartListData.filter(item => { // 选中的商品信息
return item.checked
}).map(item => {
if(!item.skuId) return false
if (!item.skuId) return false
let trolleySku2BuyObj = {
count: 0,
skuId: 0
......@@ -254,7 +258,7 @@ wxService.page({
// 去下单页 && 参数
let tradeDto = {
trolleySku2Buy:JSON.stringify(trolleySku2Buy)
trolleySku2Buy: JSON.stringify(trolleySku2Buy)
}
const parmas = tradeDto
......@@ -291,7 +295,7 @@ wxService.page({
},
// 输入商品数量
inputProNumber(cartPro){
inputProNumber(cartPro) {
wx.showLoading({
title: '加载中'
})
......@@ -316,12 +320,12 @@ wxService.page({
var cartList = this.data.cartList
var index = e;
let productStatus = cartList[index].productStatus;
if (productStatus == 0 || productStatus == 1 || productStatus == 3){
if (productStatus == 0 || productStatus == 1 || productStatus == 3) {
wx.showToast({
title: '此商品已下架或不存在',
icon : 'none'
icon: 'none'
});
return ;
return;
}
var checkAll = false
......@@ -333,9 +337,9 @@ wxService.page({
if (cartList.length === cartList.filter(function (item) {
return item.checked
}).length ) {
}).length) {
checkAll = true
}else {
} else {
checkAll = false
}
......@@ -349,23 +353,23 @@ wxService.page({
checkAll: function () { // 全选
var cartList = this.data.cartList || [];
let offLineProducts = [];
cartList.forEach((item,index) => {
if (item.productStatus == 0 || item.productStatus == 1 || item.productStatus == 3){
cartList.forEach((item, index) => {
if (item.productStatus == 0 || item.productStatus == 1 || item.productStatus == 3) {
offLineProducts.push(item.productName);
}
});
if (offLineProducts.length > 0){
if (offLineProducts.length > 0) {
let toastText = offLineProducts.join(',');
wx.showToast({
title: '您购物车中商品:' + toastText + ' 已下架或不存在!',
icon : 'none'
icon: 'none'
});
return ;
return;
}
if(!cartList.length) return false
if (!cartList.length) return false
if (this.data.checkAll) {
this.setData({
......@@ -394,8 +398,8 @@ wxService.page({
this.deletePro(e.detail)
},
//失效商品话滑动删除
delInvalidItemChange(e){
const {index, skuid} = e.detail;
delInvalidItemChange(e) {
const { index, skuid } = e.detail;
var self = this
wx.showModal({
title: '提示',
......@@ -415,7 +419,7 @@ wxService.page({
})
},
//清空失效商品
onTapEmptyInvlidCarts(){
onTapEmptyInvlidCarts() {
let self = this;
wx.showModal({
title: '提示',
......@@ -436,13 +440,13 @@ wxService.page({
title: '清除成功',
});
self.setData({
invalidCarts : [],
invalidCarts: [],
});
}).catch(err => {
wx.hideLoading();
wx.showToast({
title: '清除失败,请稍后再试',
icon : 'none'
icon: 'none'
});
})
}
......@@ -450,16 +454,16 @@ wxService.page({
});
},
//清空有效宝贝
onTapEmptyValidCarts(){
onTapEmptyValidCarts() {
let self = this;
let checked = self.data.cartList.filter(item => item.checked);
if(checked.length == 0){
if (checked.length == 0) {
wx.showToast({
title: '请先勾选需要删除的商品',
icon : 'none'
icon: 'none'
});
return ;
return;
}
wx.showModal({
......@@ -485,7 +489,7 @@ wxService.page({
wx.hideLoading();
wx.showToast({
title: '清除失败,请稍后再试',
icon : 'none'
icon: 'none'
});
});
}
......@@ -494,7 +498,7 @@ wxService.page({
},
//删除商品
deletePro(e) {
const {index, skuid} = e
const { index, skuid } = e
var self = this
wx.showModal({
title: '提示',
......
......@@ -412,7 +412,7 @@ wxService.page({
if(result == 0){
data.faceAmount = data.couponSetting.faceAmount;
data.postalDiscountPrice = '0.00';
data.couponSettingId = data.couponSetting.couponSettingId;
data.couponId = data.coupon.id;
this.data.currentPostalCoupon = data;
}else{
......@@ -1040,7 +1040,7 @@ wxService.page({
//处理包邮券信息
if(this.data.currentPostalCoupon){
params.postCouponSettingId = this.data.currentPostalCoupon.couponSettingId;
params.postCouponId = this.data.currentPostalCoupon.couponId;
}
let _this = this;
......
......@@ -172,6 +172,8 @@ wxService.page({
},
//跳转到我的购买优惠券记录
onTapToBuyCouponRecords(){
wx.navigateTo({
url: '/subPackageA/page/pages/moneyBuyCouponRecords/moneyBuyCouponRecords',
});
},
})
\ No newline at end of file
......@@ -18,9 +18,9 @@ wxService.page({
sec: '00',
ms: '0',
mergedAmount: 0,
totalGoodsPrice : 0,
canApplyRefund : true,
orderTopBg : orderTopBg,
totalGoodsPrice: 0,
canApplyRefund: true,
orderTopBg: orderTopBg,
},
/**
......@@ -35,17 +35,17 @@ wxService.page({
*/
onShow: function () {
const { id } = this.options;
if(id) {
if (id) {
this.setData({
id
},()=>{
}, () => {
this.getOrderDetail(id)
})
}
},
//跳转商品详情
onTapToProductInfo(e){
onTapToProductInfo(e) {
let sku = e.currentTarget.dataset.item;
let productId = sku.productId;
......@@ -65,7 +65,7 @@ wxService.page({
},
//获取订单详情
getOrderDetail(id){
getOrderDetail(id) {
wx.showLoading({
title: '加载中',
mask: true
......@@ -78,41 +78,53 @@ wxService.page({
wx.hideLoading();
//处理总数
let skuVOList = data.skuVOList ? data.skuVOList : [];
let sum = 0 ;
let sum = 0;
skuVOList.forEach(item => {
item.refundCount = item.refundCount ? item.refundCount : 0;
item.canRefundNum = (item.count - item.refundCount) >= 0 ? (item.count - item.refundCount) : 0;
sum = sum + item.price * item.count;
});
if(data.order.wechatCouponPrice){
data.order.wechatCouponPrice = data.order.wechatCouponPrice/10/10;
data.payAmount = (data.payAmount *1) - (data.order.wechatCouponPrice*1)
}
if(data.order.postCouponDisCount){
data.order.postCouponDisCount = data.order.postCouponDisCount/10/10;
}
//处理收货地址
if (data.logistic){
if (data.logistic) {
let receiverInfoArr = data.logistic.receiverInfo.split(',').reverse().filter(item => item);
data.logistic.receiverName = receiverInfoArr[1];
data.logistic.receiverMobile = receiverInfoArr[0];
data.logistic.receiverAddress = receiverInfoArr[2] + receiverInfoArr[3];
}
else{
else {
data.logistic = null;
}
// 处理积分抵扣
data.pointPayInfo = data.pointPayInfo ? data.pointPayInfo : {point:0,pointAmount:0};
data.pointPayInfo = data.pointPayInfo ? data.pointPayInfo : { point: 0, pointAmount: 0 };
data.payAmount = (data.payAmount *1) - (data.pointPayInfo.pointAmount*1);
//处理能不能退款
let canApplyRefund = true;
let filter = skuVOList.filter(c => c.canRefundNum > 0);
if (filter.length > 0){
if (filter.length > 0) {
canApplyRefund = true;
}
else{
else {
canApplyRefund = false;
}
if(data.status == 'N' || data.status == 'C'){
const { localNowTime} = this.data
if (data.status == 'N' || data.status == 'C') {
const { localNowTime } = this.data
data.localNowTime = localNowTime ? localNowTime : new Date().getTime();
data.createOrderTime = new Date(data.createTime.replace(/-/g,'/')).getTime() || [];
data.createOrderTime = new Date(data.createTime.replace(/-/g, '/')).getTime() || [];
data.countDownOrderTime = 7200000; // 2时(h)=7200000毫秒(ms)
// 订单倒计时 超多两小时 刷新当前页
data.orderCanRefund = true;
......@@ -122,11 +134,11 @@ wxService.page({
});
data.parcelList = [{
code : '',
supplierCode : '',
supplierName : '',
status : data.status,
sendOutList : data.skuVOList,
code: '',
supplierCode: '',
supplierName: '',
status: data.status,
sendOutList: data.skuVOList,
}];
this.calcuPackageProductCountAndTotalPrice(data);
......@@ -136,26 +148,26 @@ wxService.page({
totalGoodsPrice: this.data.totalGoodsPrice,
mergedAmount: data.mergedAmount || 0,
canApplyRefund: canApplyRefund
}, ()=>{
}, () => {
this.initCountDown(data.countDownOrderTime, data.createOrderTime, data.localNowTime)
});
}
else{
else {
let parcelList = data.parcelList ? data.parcelList : [];
if(parcelList.length == 0){
if (parcelList.length == 0) {
parcelList = [{
code : '--',
supplierCode : '--',
supplierName : '--',
status : data.status,
orderCanRefund : true,
deliverTime : '--',
sendOutList : data.skuVOList,
code: '--',
supplierCode: '--',
supplierName: '--',
status: data.status,
orderCanRefund: true,
deliverTime: '--',
sendOutList: data.skuVOList,
}]
data.parcelList = parcelList;
}
else{
else {
parcelList.forEach(item => {
item.code = item.code ? item.code : '--';
item.supplierCode = item.supplierCode ? item.supplierCode : '--';
......@@ -164,16 +176,16 @@ wxService.page({
item.deliverTime = item.deliverTime ? item.deliverTime : '';
//计算一下包裹能不能退货
let deliverTime = item.deliverTime ? item.deliverTime : null;
if(deliverTime){
if (deliverTime) {
let diffObj = utils.getDateDiff(deliverTime);
if (diffObj.days <= this.data.canRefundDaysAfterDelivery){
if (diffObj.days <= this.data.canRefundDaysAfterDelivery) {
item.orderCanRefund = true;
}
else{
else {
item.orderCanRefund = false;
}
}
else{
else {
item.orderCanRefund = true;
}
......@@ -181,7 +193,7 @@ wxService.page({
let sendOutList = [];
item.sendOutList.forEach(s => {
let filter = data.skuVOList.filter(f => f.skuId == s.skuId);
if(filter.length > 0){
if (filter.length > 0) {
sendOutList.push(filter[0]);
}
});
......@@ -206,14 +218,14 @@ wxService.page({
},
//计算包裹商品数量和价格
calcuPackageProductCountAndTotalPrice(data){
calcuPackageProductCountAndTotalPrice(data) {
let parcelList = data.parcelList;
parcelList.forEach(p => {
let totalCount = 0, totalPrice = 0 , totalCanRefundCount = 0;
let totalCount = 0, totalPrice = 0, totalCanRefundCount = 0;
p.sendOutList.forEach(s => {
totalCount = totalCount + s.count;
totalPrice = totalPrice + s.amount;
totalCanRefundCount = totalCanRefundCount + s.canRefundNum ;
totalCanRefundCount = totalCanRefundCount + s.canRefundNum;
});
p.totalCount = totalCount;
p.totalPrice = parseFloat(totalPrice).toFixed(2);
......@@ -222,7 +234,7 @@ wxService.page({
});
},
initCountDown(countDownOrderTime,startTime,localTime) {
initCountDown(countDownOrderTime, startTime, localTime) {
// 毫秒差 本地时间 - 创建时间
let countTimeSpan = localTime - startTime
......@@ -266,7 +278,7 @@ wxService.page({
if (result.min < 10) result.min = '0' + result.min;
if (result.hour < 10) result.hour = '0' + result.hour;
} else {
const {detail, id} = this.data
const { detail, id } = this.data
if (!this.getDetailLimitCount) {
this.getDetailLimitCount = 1
} else {
......@@ -306,7 +318,7 @@ wxService.page({
});
setTimeout(() => {
wx.navigateBack({
delta : 1
delta: 1
});
}, 500);
} else {
......@@ -410,28 +422,28 @@ wxService.page({
let obj = {
id: this.data.id,
logistic: {
supplierName : detail.supplierName,
code : detail.code,
supplierCode : detail.supplierCode,
supplierName: detail.supplierName,
code: detail.code,
supplierCode: detail.supplierCode,
},
status: detail.status,
}
let params = JSON.stringify(obj);
// // 退款申请
wxService.router(`/pages/logistics/logistics`).search({params});
wxService.router(`/pages/logistics/logistics`).search({ params });
},
// 申请退款
handelRequestRefund(e) {
let orderId = e.currentTarget.dataset.id;
let packageInfo = e.currentTarget.dataset.package;
if(packageInfo.totalCanRefundCount <= 0 || !packageInfo.totalCanRefundCount){
return ;
if (packageInfo.totalCanRefundCount <= 0 || !packageInfo.totalCanRefundCount) {
return;
}
let detail = {
id : orderId,
skuVOList :packageInfo.sendOutList,
id: orderId,
skuVOList: packageInfo.sendOutList,
}
let copyOrderInfo = JSON.parse(JSON.stringify(detail));
......@@ -445,7 +457,7 @@ wxService.page({
let params = JSON.stringify(copyOrderInfo);
// 退款申请
wxService.router(`/pages/refund/refund`).search({params})
wxService.router(`/pages/refund/refund`).search({ params })
},
// 确认收货
handelConfirmReceipt(e) {
......@@ -459,15 +471,15 @@ wxService.page({
});
//兼容老数据
if(parcelId){
this.packageConfirmReceive(id,parcelId);
if (parcelId) {
this.packageConfirmReceive(id, parcelId);
}
else{
else {
this.oldVersionConfirmReceive(id);
}
},
//包裹的确认收货
packageConfirmReceive(findId, parcelId){
packageConfirmReceive(findId, parcelId) {
wxService.post(`/sale/trade/buyer/parcelConfirm?findId=${findId}&parcelId=${parcelId}`).then(res => {
if (res) {
const { result, data } = res.data
......@@ -490,7 +502,7 @@ wxService.page({
})
},
//兼容以前老数据进行确认收货
oldVersionConfirmReceive(id){
oldVersionConfirmReceive(id) {
wxService.post(`/sale/trade/buyer/confirm/${id}`).then(res => {
if (res) {
const { result, data } = res.data
......
......@@ -152,8 +152,16 @@
<text>¥{{utils.numberFormat(detail.coouponDiscount)}}</text>
</view>
<view class="order-pro-list">
<text>包邮券优惠</text>
<text>¥{{utils.numberFormat(detail.order.postCouponDisCount)}}</text>
</view>
<view class="order-pro-list">
<text>支付券优惠</text>
<text>¥{{utils.numberFormat(detail.order.wechatCouponPrice)}}</text>
</view>
<view class="order-pro-list">
<text class="pay-amount">实付金额</text>
<text class="order-price">¥{{detail.payAmount}}</text>
<text class="order-price">¥{{detail.payAmount }}</text>
</view>
</view>
<view class="order-number-info">
......
......@@ -43,7 +43,8 @@
<view class="product-price">
<view class="price-wrap">
<view class="price-icon" wx:if="{{memberLevel}}">会员专享价</view>
<text class="price">¥{{utils.numberFormat(productInfo.minSalePrice / 100)}}</text>
<text class="price">¥{{ productInfo.minActivityPrice? utils.numberFormat(productInfo.minActivityPrice / 100):utils.numberFormat(productInfo.minSalePrice / 100) }}</text>
<text wx:if="{{productInfo.minActivityPrice}}" class="sale-price">¥{{utils.numberFormat(productInfo.minSalePrice / 100)}}</text>
<!-- <text class="cost-price">¥888</text> -->
</view>
<button
......@@ -149,16 +150,12 @@
<view class="add-car-text">购物车</view>
</navigator>
</form>
</view>
<block>
<view class="footer-buttons clearfix">
<block>
<form
class='get-formId get-formId--form'
bindsubmit="addCart"
report-submit
name='nav'
>
<form class='get-formId get-formId--form' bindsubmit="addCart" report-submit name='nav'>
<button disabled="{{fromZc || productInfo.productStatus != 2}}"
class="cart-button get-formId--btn {{(fromZc || productInfo.productStatus != 2) ? 'btn-default' : 'btn-cart'}}" formType="submit">加入购物车</button>
</form>
......@@ -180,14 +177,12 @@
</view>
<sku-popup
bind:getMobile="userGetMobile"
currentHasMobile="{{currentHasMobile}}"
product-name="{{productInfo.productName}}"
spec-item="{{productInfo.specItemList}}"
good-type="{{productInfo.productType}}"
index-img="{{productInfo.indexUrl}}"
sku-infos="{{productInfo.productSku}}"
product-price="{{productInfo.plusPrice ? productInfo.plusPrice : productInfo.minSalePrice}}"
product-price="{{ productInfo.plusPrice ? productInfo.plusPrice : productInfo.minSalePrice}}"
show="{{showSkuPopup}}"
bind:skuselect="confirmClick"
btn-text="{{btnText}}"
......
......@@ -12,7 +12,12 @@ page{
.swiper-image{
width: 100%;
}
.sale-price{
color: rgba(170, 170, 170, 1);
font-size: 24rpx;
margin-left: 12rpx;
text-decoration: line-through;
}
.video-cover{
width: 100%;
height: 100%;
......@@ -54,9 +59,9 @@ page{
width: 88rpx;
height: 30rpx;
border-radius: 3rpx;
background-color: var(--themeColorRgba01);
background-color: rgba(203, 60, 60, 0.08);
font-size: 13rpx;
color: var(--themecolor);
color: #cb3c3c;
line-height: 30rpx;
text-align: center;
vertical-align: middle;
......@@ -163,7 +168,7 @@ page{
}
.surplus-number{
font-weight: bold;
color: var(--themecolor);
color: #cb3c3c;
}
.gray-line{
background-color: #f9f9f9;
......
......@@ -87,7 +87,7 @@
<text class="refund-desc">{{refundDetail.reason}}</text>
</view>
<view class="refund-item">
<text class="refund-label">退款时间</text>
<text class="refund-label">申请时间</text>
<text class="refund-desc">{{refundDetail.createTime}}</text>
</view>
<view class="refund-item">
......
......@@ -13,7 +13,7 @@
},
"compileType": "miniprogram",
"libVersion": "2.8.2",
"appid": "wxc3b64b09b1d3dfc2",
"appid": "wxac09792264c49b5c",
"projectname": "%E5%BE%AE%E5%95%86%E5%9F%8E",
"debugOptions": {
"hidedInDevtools": []
......@@ -150,7 +150,7 @@
"id": 16,
"name": "商品详情页",
"pathName": "pages/productDetail/productDetail",
"query": "id=697828280501407744",
"query": "id=684465422204145664",
"scene": null
},
{
......@@ -566,7 +566,7 @@
"id": 77,
"name": "领取中心优惠券详情",
"pathName": "subPackage/page/pages/couponCenterInfo/couponCenterInfo",
"query": "",
"query": "id=706914649421123584",
"scene": null
},
{
......@@ -647,23 +647,45 @@
"scene": null
},
{
"id": -1,
"name": "现金购",
"id": 89,
"name": "现金购买活动列表",
"pathName": "subPackageA/page/pages/moneyBuyCoupon/moneyBuyCoupon",
"query": "",
"scene": null
},
{
"id": -1,
"name": "支付券详情",
"pathName": "subPackageA/page/pages/payCardInfo/payCardInfo",
"query": "id= 704753070554353664",
"name": "领券中心",
"pathName": "subPackage/page/pages/couponCenter/couponCenter",
"query": "",
"scene": null
},
{
"id": -1,
"name": "领券中心",
"pathName": "subPackage/page/pages/couponCenter/couponCenter",
"name": "限时抢购",
"pathName": "subPackageA/page/pages/TimelimitedSales/TimelimitedSales",
"query": "",
"scene": null
},
{
"id": -1,
"name": "所属门店信息",
"pathName": "subPackageA/page/pages/belongWithGuide/belongWithGuide",
"query": "",
"scene": null
},
{
"id": -1,
"name": "现金购买券记录",
"pathName": "subPackageA/page/pages/moneyBuyCouponRecords/moneyBuyCouponRecords",
"query": "",
"scene": null
},
{
"id": -1,
"name": "subPackage/page/pages/couponCenterInfo/couponCenterInfo",
"pathName": "subPackage/page/pages/couponCenterInfo/couponCenterInfo",
"query": "id=708696469342916608",
"scene": null
}
]
......
......@@ -143,7 +143,8 @@ wxService.page({
});
let pageNo = this.data.pageNo,
pageSize = this.data.pageSize;
wxService.post(`/sale/product/buyer/listPageByCategoryId?pageNo=${pageNo}&pageSize=${pageSize}`, this.data.form).then(res => {
// wxService.post(`/sale/product/buyer/listPageByCategoryId?pageNo=${pageNo}&pageSize=${pageSize}`, this.data.form).then(res => {
wxService.post(`/sale/product/buyer/findCategoryTreeIdByProductList?pageNo=${pageNo}&pageSize=${pageSize}&id=${this.data.form.mallCategoryId}`).then(res => {
const { result, data } = res.data
if (result == 0 && data.content) {
wx.hideLoading()
......
// subPackage/page/pages/couponCenterInfo/couponCenterInfo.js
const wxService = require('../../../../utils/wxService')
const util = require('../../../../utils/util')
wxService.page({
/**
......@@ -7,7 +8,8 @@ wxService.page({
*/
data: {
activityId : null,
activityInfo : {}
activityInfo : {},
showDialog : false,
},
/**
......@@ -36,6 +38,14 @@ wxService.page({
obj.desc = arr.filter(item => item.type == 2);
obj.hasExpDate = arr.filter(item => item.type == 1).length > 0 ;
this.data.activityInfo = obj;
//判断老活动
if(this.data.activityInfo.couponList){
this.data.activityInfo.isStart = util.compareCurrentDate(obj.startTime);
}
else{
this.data.activityInfo.isStart = true;
}
this.setData({
activityInfo: this.data.activityInfo
});
......@@ -50,14 +60,43 @@ wxService.page({
title: '领取中..',
});
let id = this.data.activityId;
let isStart = this.data.activityInfo.isStart;
console.log(isStart)
//判断是不是老活动
if(!this.data.activityInfo.couponList){
this.getCoupon(id);
return ;
}
if(isStart){
this.getCoupon(id);
}
else{
//立即预约
this.orderCouponNow(id);
}
},
//立即;领取
getCoupon(id){
wxService.post(`/coupon/couponCenterActivity/buyer/coupon/draw?id=${id}`).then(res => {
wx.hideLoading();
if (res) {
if (res.data.result == 0) {
//判断是不是老数据
if(!this.data.activityInfo.couponList){
wx.showToast({
title: '领取成功',
});
}
else{
this.data.showDialog = true;
this.setData({
showDialog : true
});
}
}
else {
wx.showToast({
title: '领取失败,请稍后再试',
......@@ -67,6 +106,44 @@ wxService.page({
}
});
},
//立即预约
orderCouponNow(id){
let baseUserInfo = wx.getStorageSync('_baseUserInfo');
wxService.post(`${'/merchant/message/wxSubMsgMapping/getListByParams'}`, {
scenarioIds: ['usernoticeappointment'],
sourceFrom: 2,
switchType: 3
}).then(res => {
let tempArr = res.data.data ? res.data.data : [];
let tempids = [];
tempArr.map(item => {
tempids.push(item.templateId);
});
wx.requestSubscribeMessage({
tmplIds: tempids,
success: (res) => {
for (let i = 0; i < tempArr.length; i++) {
wxService.post(`${'/merchant/message/wxSubMsgSubscride/member/subscribe'}`, {
businessId: id,
memberId: baseUserInfo.memberId,
scenarioId: tempArr[i].scenarioId,
templateId: tempArr[i].templateId
}).then(resp => { });
}
if (tempids.length > 0) {
let status = res[tempids[0]];
if (status == 'accept') {
this.getACtivityInfo();
wx.showToast({
title: '预约成功',
})
}
}
},
complete: (res) => { }
})
}).catch(err => { })
},
/**
* 用户点击右上角分享
......
<!--subPackage/page/pages/couponCenterInfo/couponCenterInfo.wxml-->
<view class="coupon-info-con">
<view class="coupon-info-bg" style="background-image:url('https://img3.bigaka.com/prd/3001/202003/20200331/3001df30305c-f4fe-4c35-bd73-5d87d4882f7a.png')">
<!-- 老数据活动 -->
<view class="coupon-info-bg" wx:if="{{!activityInfo.couponList}}" style="background-image:url('https://img3.bigaka.com/prd/3001/202003/20200331/3001df30305c-f4fe-4c35-bd73-5d87d4882f7a.png')">
<view class="lf-coupon-Bg">
<image wx:if="{{activityInfo.listPicture}}" mode="aspectFit" src="{{activityInfo.listPicture}}"></image>
<image wx:else src='https://img3.bigaka.com/prd/3001/202003/20200331/3001649f2f08-3b4e-4b5b-97c1-30cdf646651c.png' />
......@@ -13,6 +14,12 @@
</view>
</view>
</view>
<!-- 修改为新的布局 -->
<view class="coupon-package" wx:if="{{activityInfo.couponList}}">
<image src="{{activityInfo.detailPicture}}" mode="widthFix"></image>
</view>
<!-- 活动说明 -->
<view class='integral-detail' wx:if="{{activityInfo.hasExpDate}}">
<view class='integral-list'>
......@@ -32,8 +39,12 @@
<button wx:if="{{!currentHasUserInfo}}"
bindgetuserinfo="_getUserInfo"
open-type='getUserInfo'
class="clear-btn positionAbs">立即领取</button>
<view wx:else class="view-btn" bindtap="onTapGetCoupon">立即领取</view>
class="clear-btn positionAbs">{{activityInfo.isStart ? '立即领取' : '立即预约'}}</button>
<!-- <view wx:else class="view-btn" bindtap="onTapGetCoupon">{{activityInfo.isStart ? '立即领取' : '立即预约'}}</view> -->
<view wx:if="{{currentHasUserInfo && !activityInfo.isAppointMent}}" class="view-btn" bindtap="onTapGetCoupon">{{activityInfo.isStart ? '立即领取' : '立即预约'}}</view>
<view wx:if="{{currentHasUserInfo && activityInfo.isAppointMent}}" class="view-btn" >已预约</view>
</view>
</view>
<!-- image-dialog -->
<image-dialog showDialog="{{showDialog}}" imageUrl="{{activityInfo.dialogPicture}}"></image-dialog>
\ No newline at end of file
// share/share.js
const wxService = require('../../../../utils/wxService')
const utils = require('../../../../utils/util')
const envInfo = require('../../../../config/index').envInfo
const app = getApp()
wxService.page({
data: {
bannerImg: '',
listData: [[], [], []],
current: 0,
typeArr: [1, 2, 3]
},
onLoad: function (options) {
this.getProductList();
this.getImg();
},
getImg() {
wxService.post(`/sale/specialPriceActivate/getPropagandaSet`).then(res => {
if (res.data.data && res.data.data.imgList.length > 0) {
this.setData({
bannerImg: res.data.data.imgList[0]
})
}
})
},
getProductList(current) {
current = current ? current : 0;
wxService.post(`/sale/specialPriceActivate/getActivityProductList?type=${this.data.typeArr[current]}`).then(res => {
let data = res.data.data?res.data.data:[];
data.map(item => {
item.activityPriceText = item.activityPrice ? String((item.activityPrice / 10 / 10).toFixed(2)).split('.') : ['00', '00'];
item.salePriceText = item.productPrice ? String((item.productPrice / 10 / 10).toFixed(2)).split('.') : ['00', '00'];
item.per = (item.salesCount / item.repertory).toFixed(2) * 10 * 10;
item.width = item.per / 10 / 10 * 254;
return item;
});
let list = this.data.listData;
list[current] = data;
this.setData({
listData: list
})
})
},
linkToProInfo(e) {
let productId = e.currentTarget.dataset.productid;
wxService.router(`/pages/productDetail/productDetail?id=${productId}`);
},
//消息订阅
subscribeClick(e) {
let activeId = e.currentTarget.dataset.id;
let itemIndex = e.currentTarget.dataset.index;
let baseUserInfo = wx.getStorageSync('_baseUserInfo');
wxService.post(`${'/merchant/message/wxSubMsgMapping/getListByParams'}`, {
scenarioIds: ['usernoticeappointment'],
sourceFrom: 2,
switchType: 3
}).then(res => {
let tempArr = res.data.data ? res.data.data : [];
let tempids = [];
tempArr.map(item => {
tempids.push(item.templateId);
});
console.log(tempids)
wx.requestSubscribeMessage({
tmplIds: tempids,
success: (res) => {
for (let i = 0; i < tempArr.length; i++) {
wxService.post(`${'/merchant/message/wxSubMsgSubscride/member/subscribe'}`, {
businessId: activeId,
memberId: baseUserInfo.memberId,
scenarioId: tempArr[i].scenarioId,
templateId: tempArr[i].templateId
}).then(resp => { });
}
if(tempids.length>0){
let status = res[tempids[0]];
if(status == 'accept'){
let list = this.data.listData;
list[this.data.current][itemIndex].isAppointMent = true;
this.setData({
listData: list
})
wx.showToast({
title: '预约成功',
})
}
}
},
complete: (res) => {
console.log(res)
}
})
}).catch(err => {})
},
changeTab(e) {
this.setData({
current: e.target.dataset.current * 1
})
},
swiperChange(e) {
let current = e.detail.current;
this.setData({
current: current
})
if (this.data.listData[current].length === 0) {
this.getProductList(current);
}
// this.getProductList(current);
},
onShow: function () {
},
});
\ No newline at end of file
{
"navigationBarTitleText": "限时抢购",
"usingComponents": {}
}
\ No newline at end of file
<view class="banner-wrap">
<image class="banner-img" src="{{bannerImg}}" />
</view>
<view class="tab-wrap">
<view class="tab-item {{current==0?'tab-item-active':''}}" bind:tap="changeTab" data-current="0">抢购中</view>
<view class="tab-item {{current==1?'tab-item-active':''}}" bind:tap="changeTab" data-current="1">未开始</view>
<view class="tab-item {{current==2?'tab-item-active':''}}" bind:tap="changeTab" data-current="2">抢先商品</view>
</view>
<view class="list-wrap" style="flex:1;">
<swiper bindchange="swiperChange" current="{{current}}">
<block wx:for="{{3}}" wx:key="*this">
<swiper-item>
<view class="list-item" wx:for="{{listData[index]}}" wx:if="{{listData[current].length}}" wx:key="*this" data-productid="{{item.productId}}" bind:tap="linkToProInfo">
<view class="item-lf">
<image class="item-img" src="{{item.indexUrl}}" />
<image wx:if="{{(item.repertory - item.salesCount)==0}}" class="sale-out" src="https://img3.bigaka.com/prd/3001/202005/20200511/3001de63752e-41ab-4736-ac2e-4ef3603c0309.png" />
</view>
<view class="item-rt">
<view class="tips">{{ item.subtitle }}</view>
<view class="title">{{item.productName}}</view>
<view class="start-time" wx:if="{{current==1}}">开始时间 {{item.startTime}}</view>
<view class="left" wx:if="{{current!=1}}">
<view class="all-line">
<view class="left-line" style="width: {{item.width}}rpx;" wx:if="{{item.repertory!=0}}">已抢{{item.salesCount}}件</view>
<text class="per-text" wx:if="{{item.repertory!=0}}">{{item.per}}%</text>
<view class="left-line-saled" wx:if="{{(item.repertory - item.salesCount)==0}}">已抢完</view>
</view>
</view>
<view class="price-wrap">
<view class="active-price"><text class="fs-24">¥</text><text class="fs-38">{{ item.activityPriceText[0] }}.</text><text class="fs-32">{{item.activityPriceText[1]}}</text></view>
<view class="sale-price"><text class="fs-15">¥</text><text class="fs-23">{{item.salePriceText[0]}}.</text><text class="fs-17">{{item.salePriceText[1]}}</text></view>
<view class="rush-btn" wx:if="{{current!=1&&(item.repertory - item.salesCount)>0}}">马上抢</view>
<view class="subscribe-btn" wx:if="{{current==1 && !item.isAppointMent}}" catchtap="subscribeClick" data-id="{{item.productId}}" data-index="{{index}}">预约提醒</view>
<view class="subscribe-btn" wx:if="{{current==1 && item.isAppointMent}}" data-id="{{item.activityId}}">已预约</view>
<view class="saled-btn" wx:if="{{current!=1&&(item.repertory - item.salesCount)==0}}">去看看</view>
</view>
<view class="time">结束时间 {{item.endTime}}</view>
</view>
</view>
<view class="empty" wx:if="{{listData[index].length === 0}}">
暂无商品哦~
</view>
</swiper-item>
</block>
</swiper>
</view>
\ No newline at end of file
page{
background-color: #F4F5F6;
width: 100%;
height: 100%;
display: flex;
position: fixed;
flex-direction: column;
}
swiper{
overflow: visible;
width: 100%;
height: 100%;
}
swiper-item{
overflow: visible;
overflow-y: auto;
width: 100%;
height: 100%;
}
.banner-wrap{
height: 276rpx;
padding: 0 30rpx;
background-color: #ffffff;
}
.banner-img{
height: 276rpx;
width: 690rpx;
border-radius: 10rpx;
}
.tab-wrap{
height: 80rpx;
display: flex;
background-color: #ffffff;
padding: 0 30rpx;
justify-content: space-around;
color: #000000;
}
.tab-item{
display: flex;
align-items: center;
justify-content: center;
padding: 0 10rpx;
font-size: 28rpx;
opacity: 0.6;
}
.tab-item-active{
font-size: 34rpx;
opacity: 1;
font-weight: bold;
}
.list-wrap{
padding: 20rpx 30rpx;
}
.list-item{
background-color: #ffffff;
height: 300rpx;
border-radius: 10rpx;
display: flex;
margin-bottom: 20rpx;
}
.item-lf{
min-width: 269rpx;
max-width: 269rpx;
display: flex;
justify-content: center;
position: relative;
}
.sale-out{
width: 210rpx;
height: 210rpx;
position: absolute;
top: 44.5rpx;
left: 14.5rpx;
}
.item-img{
width: 210rpx;
height: 210rpx;
margin: auto;
margin-top: 30rpx;
}
.item-rt{
flex-grow: 1;
display: flex;
flex-direction: column;
padding-right: 23rpx;
}
.tips{
height: 22rpx;
color: rgba(102, 102, 102, 1);
font-size: 22rpx;
text-align: left;
margin-top: 33rpx;
}
.title{
height: 70rpx;
line-height: 35rpx;
color: rgba(0, 0, 0, 1);
font-size: 28rpx;
text-align: left;
margin-top: 10rpx;
text-overflow: -o-ellipsis-lastline;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-box-orient: vertical;
}
.left{
margin-top: 8rpx;
}
.all-line{
width: 254rpx;
height: 26rpx;
border-radius: 13rpx;
background-color: rgba(255, 206, 206, 1);
position: relative;
text-align: right;
display: flex;
align-items: center;
justify-content: flex-end;
}
.left-line{
position: absolute;
top: 0;
left: 0;
width: 79rpx;
height: 26rpx;
border-radius: 13rpx;
background-image: linear-gradient(to right, #FF2569, #FF1038);
color: #ffffff;
white-space: nowrap;
font-size: 16rpx;
display: flex;
align-items: center;
padding-left: 8rpx;
}
.left-line-saled{
position: absolute;
top: 0;
left: 0;
width: 254rpx;
height: 26rpx;
border-radius: 13rpx;
background-image: linear-gradient(to right, #FF2569, #FF1038);
color: #ffffff;
font-size: 16rpx;
display: flex;
align-items: center;
justify-content: center;
}
.start-time{
height: 20rpx;
color: rgba(250, 100, 0, 1);
font-size: 20rpx;
margin-top: 8rpx;
}
.per-text{
font-size: 16rpx;
color: #FF1038;
margin-right: 8rpx;
}
.price-wrap{
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 10rpx;
}
.active-price{
height: 53rpx;
color: rgba(255, 51, 51, 1);
vertical-align: bottom;
}
.sale-price{
vertical-align: bottom;
color: #9B9B9B;
text-decoration:line-through;
}
.rush-btn{
width: 123rpx;
height: 48rpx;
border-radius: 24rpx;
background-color: rgba(255, 16, 56, 1);
display: flex;
align-items: center;
justify-content: center;
color: rgba(255, 255, 255, 1);
font-size: 22rpx;
}
.subscribe-btn{
width: 138rpx;
height: 48rpx;
display: flex;
align-items: center;
justify-content: center;
border-radius: 24rpx;
border: 2rpx solid rgba(255, 16, 56, 1);
color: rgba(255, 16, 56, 1);
font-size: 22rpx;
}
.saled-btn{
width: 123rpx;
height: 48rpx;
border-radius: 24rpx;
border: 1rpx solid rgba(155, 155, 155, 1);
display: flex;
align-items: center;
justify-content: center;
color: rgba(155, 155, 155, 1);
font-size: 22rpx;
}
.time{
height: 20rpx;
color: rgba(192, 191, 191, 1);
font-size: 20rpx;
}
.empty{
width: 300rpx;
color: #808080;
margin: 40% auto;
text-align: center;
}
.fs-24{
font-size: 24rpx;
}
.fs-38{
font-size: 38rpx;
}
.fs-32{
font-size: 32rpx;
}
.fs-15{
font-size: 15rpx;
}
.fs-13{
font-size: 13rpx;
}
.fs-17{
font-size: 17rpx;
}
\ No newline at end of file
// share/share.js
const wxService = require('../../../../utils/wxService')
const utils = require('../../../../utils/util')
const envInfo = require('../../../../config/index').envInfo
const app = getApp()
wxService.page({
data: {
storeId: undefined,
storeName: undefined,
shoppingGuidName: undefined,
latitude: undefined,
longitude: undefined,
contactPhone: undefined
},
onLoad: function (options) {
const userInfo = wx.getStorageSync('_baseUserInfo');
this.getUserInfo(userInfo.member.id);
},
locationClick() {
wx.openLocation({
latitude: this.data.latitude,
longitude: this.data.longitude,
name : this.data.storeName,
address : this.data.address,
scale: 18
})
},
getUserInfo(id) {
wxService.post(`/member/find`, {
memberId: id
}).then(res => {
let member = res.data.data.member;
this.setData({
storeId: member.storeId,
storeName: member.storeName,
shoppingGuidName: member.shoppingGuidName
})
this.getStoreInfo(member.storeId)
})
},
getStoreInfo(id) {
wxService.get(`/platform/securityB/organization/findById/` + id).then(res => {
let data = res.data.data ? res.data.data : {}
this.setData({
latitude: data.latitude,
longitude: data.longitude,
contactPhone: data.contactPhone,
address: data.addressArea+data.addressDetail
})
})
}
});
\ No newline at end of file
{
"navigationBarTitleText": "所属门店",
"usingComponents": {}
}
\ No newline at end of file
<view class="guide-wrap">
<view class="guide-head">
<view class="head-lf">
<view class="row-wrap">
<view class="title">所属门店:</view>
<view class="content">{{storeName?storeName:'无'}}</view>
</view>
<view class="row-wrap">
<view class="title">门店电话:</view>
<view class="content">{{contactPhone?contactPhone:'无'}}</view>
</view>
</view>
<view class="head-rt" bind:tap="locationClick">
<image src="https://img3.bigaka.com/prd/3001/202005/20200509/300123dc8d19-2c59-461a-89a3-bab020687557.png" />
</view>
</view>
<view class="guide-body">
<view class="row-wrap">
<view class="title">所属导购:</view>
<view class="content">{{shoppingGuidName?shoppingGuidName:'无'}}</view>
</view>
<view class="row-wrap">
<view class="title">联系方式:</view>
<view class="content">企业微信</view>
</view>
<!-- <view class="qrcode-wrap">
</view>
<view class="save-btn">保存图片</view> -->
</view>
</view>
\ No newline at end of file
page{
background-color: #F4F5F6;
width: 100%;
height: 100%;
display: flex;
position: fixed;
flex-direction: column;
}
.guide-wrap{
padding: 30rpx;
}
.guide-head{
height: 198rpx;
background-color: #ffffff;
display: flex;
align-items: center;
padding: 0 48rpx;
justify-content: space-between;
border-radius: 10rpx;
}
.head-lf{
}
.head-rt{
height: 100rpx;
width: 100rpx;
}
.head-rt image{
height: 100rpx;
width: 100rpx;
}
.row-wrap{
display: flex;
font-size: 25rpx;
margin-bottom: 12rpx;
}
.title{
color: rgba(0, 0, 0, 0.5);
}
.content{
color: rgba(0, 0, 0, 1);
}
.guide-body{
height: 198rpx;
background-color: #ffffff;
display: flex;
flex-direction: column;
padding: 0 48rpx;
margin-top: 30rpx;
justify-content: center;
border-radius: 10rpx;
}
.qrcode-wrap{
height: 500rpx;
}
.save-btn{
display: flex;
align-items: center;
justify-content: center;
width: 320rpx;
height: 86rpx;
border-radius: 10rpx;
border: 1rpx solid rgba(0, 0, 0, 0.25);
color: rgba(0, 0, 0, 0.7);
font-size: 30rpx;
}
\ No newline at end of file
......@@ -399,7 +399,15 @@ function getSum(preValue,curValue,index, array) {
}
function _getUserInfo(ev,authType) {
const userInfo = ev.detail || ev
const userInfo = ev.detail || ev;
if (ev && ev.detail.errMsg.indexOf('fail') > -1){
wx.hideLoading();
return Promise.reject({
state : -1,
msg : '授权失败'
});
}
return getUserInfoByBtn(userInfo, authType).then((data = {}) => {
const { token } = data
wx.setStorageSync('_accreditUserInfo', userInfo)
......
......@@ -816,6 +816,7 @@ class WXService extends Http {
title: '用户登录中..',
});
_self.getAuthUserInfo(res.detail,'phoneNumber').then(res => {
console.log(res)
this.setData({
currentHasMobile: true,
currentHasUserInfo : true,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment