edit
This commit is contained in:
parent
6b402a0d47
commit
a293629c81
|
@ -135,6 +135,12 @@ export function getSignList(data) {
|
||||||
export function setSignIntegral() {
|
export function setSignIntegral() {
|
||||||
return request.post('user/sign/create')
|
return request.post('user/sign/create')
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* 开盲盒
|
||||||
|
*/
|
||||||
|
export function setBlind() {
|
||||||
|
return request.post('user/sign/open')
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 签到列表(年月)
|
* 签到列表(年月)
|
||||||
|
|
|
@ -13,6 +13,12 @@
|
||||||
<view>
|
<view>
|
||||||
预售价
|
预售价
|
||||||
¥<text class="num">{{ attr.productSelect.price }}</text>
|
¥<text class="num">{{ attr.productSelect.price }}</text>
|
||||||
|
<view class="discount" v-if="attr.productSelect.coupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{attr.productSelect.coupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<text v-if="presell_type === 2">定金¥<text class="num">{{ attr.productSelect.down_price }}</text></text>
|
<text v-if="presell_type === 2">定金¥<text class="num">{{ attr.productSelect.down_price }}</text></text>
|
||||||
</view>
|
</view>
|
||||||
<text class="stock" v-if='isShow'>库存: {{ attr.productSelect.stock }}</text>
|
<text class="stock" v-if='isShow'>库存: {{ attr.productSelect.stock }}</text>
|
||||||
|
@ -22,6 +28,12 @@
|
||||||
<view class="acea-row row-middle">
|
<view class="acea-row row-middle">
|
||||||
<view class="acea-row row-middle">
|
<view class="acea-row row-middle">
|
||||||
<text>¥</text><text class="num">{{ attr.productSelect.price }}</text>
|
<text>¥</text><text class="num">{{ attr.productSelect.price }}</text>
|
||||||
|
<view class="discount" v-if="attr.productSelect.coupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{attr.productSelect.coupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<view v-if="attr.productSelect && attr.productSelect.svip_price" class="acea-row row-middle">
|
<view v-if="attr.productSelect && attr.productSelect.svip_price" class="acea-row row-middle">
|
||||||
<text class='vip-money'>¥{{attr.productSelect.svip_price}}</text>
|
<text class='vip-money'>¥{{attr.productSelect.svip_price}}</text>
|
||||||
<view class="vipImg">
|
<view class="vipImg">
|
||||||
|
@ -151,6 +163,28 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
|
.discount{
|
||||||
|
display: inline-block;
|
||||||
|
margin-left: 20rpx;
|
||||||
|
line-height: 48rpx;
|
||||||
|
min-height: 48rpx;
|
||||||
|
vertical-align: top;
|
||||||
|
border: 1px solid #F8D2CB;
|
||||||
|
padding-left: 20rpx;
|
||||||
|
border-radius: 10rpx;
|
||||||
|
&_main{
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
&_left{
|
||||||
|
padding-right: 10rpx;
|
||||||
|
border-right: 2px dotted #F6D3D7;
|
||||||
|
}
|
||||||
|
&_right{
|
||||||
|
padding: 0 10rpx;
|
||||||
|
background: #FDEFEE;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
.product-window {
|
.product-window {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
|
|
|
@ -21,6 +21,12 @@
|
||||||
-¥{{couponData.order_total_integral_price}}
|
-¥{{couponData.order_total_integral_price}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view v-if="couponData.order_total_amount_price>0" class="check-item">
|
||||||
|
<view>抵扣券抵扣:</view>
|
||||||
|
<view class="radio">
|
||||||
|
-¥{{couponData.order_total_amount_price}}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<view v-if="couponData.total_platform_coupon_price>0" class="check-item">
|
<view v-if="couponData.total_platform_coupon_price>0" class="check-item">
|
||||||
<view>平台优惠金额:</view>
|
<view>平台优惠金额:</view>
|
||||||
<view class="radio">
|
<view class="radio">
|
||||||
|
|
|
@ -13,6 +13,12 @@
|
||||||
<view>
|
<view>
|
||||||
预售价
|
预售价
|
||||||
¥<text class="num">{{ attr.productSelect.price }}</text>
|
¥<text class="num">{{ attr.productSelect.price }}</text>
|
||||||
|
<view class="discount" v-if="attr.productSelect.coupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{attr.productSelect.coupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<text v-if="presell_type === 2">定金¥<text class="num">{{ attr.productSelect.down_price }}</text></text>
|
<text v-if="presell_type === 2">定金¥<text class="num">{{ attr.productSelect.down_price }}</text></text>
|
||||||
</view>
|
</view>
|
||||||
<text class="stock" v-if='isShow'>库存: {{ attr.productSelect.stock }}</text>
|
<text class="stock" v-if='isShow'>库存: {{ attr.productSelect.stock }}</text>
|
||||||
|
@ -28,6 +34,12 @@
|
||||||
</view>
|
</view>
|
||||||
<view v-else>
|
<view v-else>
|
||||||
<text>¥</text><text class="num">{{ attr.productSelect.price }}</text>
|
<text>¥</text><text class="num">{{ attr.productSelect.price }}</text>
|
||||||
|
<view class="discount" v-if="attr.productSelect.coupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{attr.productSelect.coupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="svipPrice" class="acea-row row-middle">
|
<view v-if="svipPrice" class="acea-row row-middle">
|
||||||
<text class='vip-money'>¥{{attr.productSelect.svip_price}}</text>
|
<text class='vip-money'>¥{{attr.productSelect.svip_price}}</text>
|
||||||
|
@ -230,6 +242,28 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
|
.discount{
|
||||||
|
display: inline-block;
|
||||||
|
margin-left: 20rpx;
|
||||||
|
line-height: 48rpx;
|
||||||
|
min-height: 48rpx;
|
||||||
|
vertical-align: top;
|
||||||
|
border: 1px solid #F8D2CB;
|
||||||
|
padding-left: 20rpx;
|
||||||
|
border-radius: 10rpx;
|
||||||
|
&_main{
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
&_left{
|
||||||
|
padding-right: 10rpx;
|
||||||
|
border-right: 2px dotted #F6D3D7;
|
||||||
|
}
|
||||||
|
&_right{
|
||||||
|
padding: 0 10rpx;
|
||||||
|
background: #FDEFEE;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
.product-window {
|
.product-window {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
|
|
|
@ -15,7 +15,6 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="coupon_popups" v-if="popShow">
|
<view class="coupon_popups" v-if="popShow">
|
||||||
<view class="bg2"></view>
|
|
||||||
<view class="con" v-if="blind">
|
<view class="con" v-if="blind">
|
||||||
<view class="contents">
|
<view class="contents">
|
||||||
<image src="@/static/images/jf.png" style="width: 48px;height:48px;" mode=""></image>
|
<image src="@/static/images/jf.png" style="width: 48px;height:48px;" mode=""></image>
|
||||||
|
@ -27,7 +26,7 @@
|
||||||
<view class='iconfont icon-guanbi3' @click="popShow = false"></view>
|
<view class='iconfont icon-guanbi3' @click="popShow = false"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="con" v-else>
|
<view class="con" v-else>
|
||||||
<view class="content">
|
<view class="contents">
|
||||||
<image src="https://store.tropjoin.com/images/notBlind.png" style="width: 80px;height: 80px;" mode=""></image>
|
<image src="https://store.tropjoin.com/images/notBlind.png" style="width: 80px;height: 80px;" mode=""></image>
|
||||||
<view class="text-black">很遗憾,差一点就中奖了</view>
|
<view class="text-black">很遗憾,差一点就中奖了</view>
|
||||||
<view class="text-red">期待您下次再来</view>
|
<view class="text-red">期待您下次再来</view>
|
||||||
|
@ -42,7 +41,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import {getWhellNumber,getWhellConfig,getWhellAction,getWhellList,setSignIntegral} from '@/api/user.js';
|
import {getWhellNumber,getWhellConfig,getWhellAction,getWhellList,setSignIntegral,setBlind} from '@/api/user.js';
|
||||||
import blindBox from '@/components/blindBox/blindBox.vue';
|
import blindBox from '@/components/blindBox/blindBox.vue';
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
@ -73,17 +72,18 @@
|
||||||
this.close();
|
this.close();
|
||||||
},
|
},
|
||||||
async openBox(){
|
async openBox(){
|
||||||
await setSignIntegral().then(res=>{
|
await setBlind().then(res=>{
|
||||||
this.drawInfo.text = res.data.integral;
|
this.drawInfo.text = res.data.integral;
|
||||||
this.drawInfo.wheel=res.data.wheel;
|
this.drawInfo.wheel=res.data.wheel;
|
||||||
this.gifShow=true;
|
this.gifShow=true;
|
||||||
|
this.blind=!!res.data.integral;
|
||||||
setTimeout(()=>{
|
setTimeout(()=>{
|
||||||
this.gifShow=false;
|
this.gifShow=false;
|
||||||
this.popShow=true;
|
this.popShow=true;
|
||||||
},1500)
|
},1500)
|
||||||
}).catch(err=>{
|
}).catch(err=>{
|
||||||
this.close();
|
// this.close();
|
||||||
return this.$util.Tips({title:err})
|
// return this.$util.Tips({title:err})
|
||||||
});
|
});
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
4
main.js
4
main.js
|
@ -28,8 +28,8 @@ let cookieName = "VCONSOLE",
|
||||||
query = parseQuery(),
|
query = parseQuery(),
|
||||||
urlSpread = query["spread"],
|
urlSpread = query["spread"],
|
||||||
vconsole = query[cookieName.toLowerCase()],
|
vconsole = query[cookieName.toLowerCase()],
|
||||||
md5 = "b14d1e9baeced9bb7525ab19ee35f2d2", // MD5 加密开启vconsole模式
|
md5 = "4F02CE914A28098A5CDEA243CE51C333", // MD5 加密开启vconsole模式
|
||||||
md5Un = "3dca2162c4e101b7656793a1af20295c"; //UN_CREMB MD5 加密关闭vconsole模式
|
md5Un = "AEC89F78998B46D17748574D027729B2"; //UN_CREMB MD5 加密关闭vconsole模式
|
||||||
|
|
||||||
if (urlSpread !== undefined) {
|
if (urlSpread !== undefined) {
|
||||||
var spread = Cache.get(SPREAD);
|
var spread = Cache.get(SPREAD);
|
||||||
|
|
|
@ -26,6 +26,12 @@
|
||||||
<!--有氛围图-->
|
<!--有氛围图-->
|
||||||
<view v-if="storeInfo.atmosphere_pic" :style="{ backgroundImage: `url(${storeInfo.atmosphere_pic})` }" class='nav acea-row row-between-wrapper'>
|
<view v-if="storeInfo.atmosphere_pic" :style="{ backgroundImage: `url(${storeInfo.atmosphere_pic})` }" class='nav acea-row row-between-wrapper'>
|
||||||
<view class='money skeleton-rect'>¥<text class='num'>{{storeInfo.price}}</text>
|
<view class='money skeleton-rect'>¥<text class='num'>{{storeInfo.price}}</text>
|
||||||
|
<view class="discount" v-if="skuCoupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{skuCoupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<text v-if="!svipData" class='y-money'>¥{{storeInfo.ot_price}}</text>
|
<text v-if="!svipData" class='y-money'>¥{{storeInfo.ot_price}}</text>
|
||||||
<view class="atmosphere" v-if="svipData && svipData.show_svip_price && svipData.show_svip" style="display: inline-block;">
|
<view class="atmosphere" v-if="svipData && svipData.show_svip_price && svipData.show_svip" style="display: inline-block;">
|
||||||
<text class="vip-money">¥{{storeInfo.svip_price}}</text>
|
<text class="vip-money">¥{{storeInfo.svip_price}}</text>
|
||||||
|
@ -54,6 +60,12 @@
|
||||||
<view class='money p-color skeleton-rect' style="min-width: 70rpx;">
|
<view class='money p-color skeleton-rect' style="min-width: 70rpx;">
|
||||||
¥
|
¥
|
||||||
<text class='num'>{{storeInfo.price}}</text>
|
<text class='num'>{{storeInfo.price}}</text>
|
||||||
|
<view class="discount" v-if="skuCoupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{skuCoupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<view v-if="svipData && svipData.show_svip_price && svipData.show_svip" style="display: inline-block;">
|
<view v-if="svipData && svipData.show_svip_price && svipData.show_svip" style="display: inline-block;">
|
||||||
<text class="vip-money">¥{{storeInfo.svip_price}}</text>
|
<text class="vip-money">¥{{storeInfo.svip_price}}</text>
|
||||||
<image class="vip-image" :src="`${domain}/static/images/svip.png`"></image>
|
<image class="vip-image" :src="`${domain}/static/images/svip.png`"></image>
|
||||||
|
@ -95,7 +107,7 @@
|
||||||
<view class="skeleton-rect">库存:{{storeInfo.stock ? storeInfo.stock : 0}}{{storeInfo.unit_name ? storeInfo.unit_name : ''}}</view>
|
<view class="skeleton-rect">库存:{{storeInfo.stock ? storeInfo.stock : 0}}{{storeInfo.unit_name ? storeInfo.unit_name : ''}}</view>
|
||||||
<view class="skeleton-rect">销量:{{storeInfo.sales ? storeInfo.sales : 0}}{{storeInfo.unit_name ? storeInfo.unit_name : ''}}</view>
|
<view class="skeleton-rect">销量:{{storeInfo.sales ? storeInfo.sales : 0}}{{storeInfo.unit_name ? storeInfo.unit_name : ''}}</view>
|
||||||
</view>
|
</view>
|
||||||
<navigator v-if="storeInfo.top_pid" hover-class='none' :url="`/pages/activity/rank/index?cate_id=${storeInfo.top_pid}`" class='label'>
|
<!-- <navigator v-if="storeInfo.top_pid" hover-class='none' :url="`/pages/activity/rank/index?cate_id=${storeInfo.top_pid}`" class='label'>
|
||||||
<view class="rank_list acea-row row-between-wrapper">
|
<view class="rank_list acea-row row-between-wrapper">
|
||||||
<view class="acea-row row-between-wrapper">
|
<view class="acea-row row-between-wrapper">
|
||||||
<text class="rank_title"></text>
|
<text class="rank_title"></text>
|
||||||
|
@ -103,14 +115,14 @@
|
||||||
</view>
|
</view>
|
||||||
<text class="iconfont icon-xiala1"></text>
|
<text class="iconfont icon-xiala1"></text>
|
||||||
</view>
|
</view>
|
||||||
</navigator>
|
</navigator> -->
|
||||||
<view class='coupon acea-row row-between-wrapper skeleton-rect' @click='couponTap' style="margin-top: 20rpx;" v-if="coupon.list.length > 0">
|
<!-- <view class='coupon acea-row row-between-wrapper skeleton-rect' @click='couponTap' style="margin-top: 20rpx;" v-if="coupon.list.length > 0">
|
||||||
<view class='hide line1 acea-row'>
|
<view class='hide line1 acea-row'>
|
||||||
优惠券:
|
优惠券:
|
||||||
<view class='activity' v-for="(item,index) in coupon.list" :key="index">满{{item.use_min_price}}减{{item.coupon_price}}</view>
|
<view class='activity' v-for="(item,index) in coupon.list" :key="index">满{{item.use_min_price}}减{{item.coupon_price}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='iconfont icon-jiantou'></view>
|
<view class='iconfont icon-jiantou'></view>
|
||||||
</view>
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
<view class='attribute acea-row row-between-wrapper skeleton-rect' @click="selecAttr">
|
<view class='attribute acea-row row-between-wrapper skeleton-rect' @click="selecAttr">
|
||||||
<view class="acea-row row-between-wrapper">{{attrTxt}}:
|
<view class="acea-row row-between-wrapper">{{attrTxt}}:
|
||||||
|
@ -495,6 +507,7 @@
|
||||||
'coupon': false,
|
'coupon': false,
|
||||||
list: [],
|
list: [],
|
||||||
},
|
},
|
||||||
|
skuCoupon:'',
|
||||||
attrTxt: '选择', //属性页面提示
|
attrTxt: '选择', //属性页面提示
|
||||||
attrValue: '', //已选属性
|
attrValue: '', //已选属性
|
||||||
animated: false, //购物车动画
|
animated: false, //购物车动画
|
||||||
|
@ -1187,6 +1200,8 @@
|
||||||
}
|
}
|
||||||
//sort();排序函数:数字-英文-汉字;
|
//sort();排序函数:数字-英文-汉字;
|
||||||
let productSelect = this.productValue[value.join(",")];
|
let productSelect = this.productValue[value.join(",")];
|
||||||
|
// console.log(productSelect);
|
||||||
|
this.skuCoupon = productSelect.coupon
|
||||||
if (productSelect && productAttr.length) {
|
if (productSelect && productAttr.length) {
|
||||||
this.$set(
|
this.$set(
|
||||||
this.attr.productSelect,
|
this.attr.productSelect,
|
||||||
|
@ -1198,6 +1213,7 @@
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
|
this.$set(this.attr.productSelect, "coupon", productSelect.coupon);
|
||||||
this.$set(this, "uniqueValue", productSelect.unique);
|
this.$set(this, "uniqueValue", productSelect.unique);
|
||||||
this.$set(this, "attrValue", value.join(","));
|
this.$set(this, "attrValue", value.join(","));
|
||||||
this.$set(this, "attrTxt", "选择");
|
this.$set(this, "attrTxt", "选择");
|
||||||
|
@ -1243,6 +1259,7 @@
|
||||||
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
|
||||||
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
this.$set(this.attr.productSelect, "stock", productSelect.stock);
|
||||||
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
this.$set(this.attr.productSelect, "unique", productSelect.unique);
|
||||||
|
this.$set(this.attr.productSelect, "coupon", productSelect.coupon);
|
||||||
this.$set(this, "uniqueValue", productSelect.unique);
|
this.$set(this, "uniqueValue", productSelect.unique);
|
||||||
this.$set(this, "attrValue", value.join(","));
|
this.$set(this, "attrValue", value.join(","));
|
||||||
this.$set(this, "attrTxt", "选择");
|
this.$set(this, "attrTxt", "选择");
|
||||||
|
@ -1414,6 +1431,20 @@
|
||||||
};
|
};
|
||||||
postCartAdd(q)
|
postCartAdd(q)
|
||||||
.then(function(res) {
|
.then(function(res) {
|
||||||
|
if('no_real' == res.data.status){
|
||||||
|
return uni.showModal({
|
||||||
|
title: res.message,
|
||||||
|
content: res.msg,
|
||||||
|
confirmText: '实名认证绑定',
|
||||||
|
success(res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
uni.navigateTo({
|
||||||
|
url:`/pages/users/real_name_authentication/index?type=edit`
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
that.isOpen = that.attr.cartAttr = false;
|
that.isOpen = that.attr.cartAttr = false;
|
||||||
let cartId = res.data.cart_id
|
let cartId = res.data.cart_id
|
||||||
let arr = (Cache.get(CART_ID)&&JSON.parse(Cache.get(CART_ID))) || []
|
let arr = (Cache.get(CART_ID)&&JSON.parse(Cache.get(CART_ID))) || []
|
||||||
|
@ -1755,6 +1786,28 @@
|
||||||
.ml8{
|
.ml8{
|
||||||
top:2rpx
|
top:2rpx
|
||||||
}
|
}
|
||||||
|
.discount{
|
||||||
|
display: inline-block;
|
||||||
|
margin-left: 20rpx;
|
||||||
|
line-height: 60rpx;
|
||||||
|
min-height: 60rpx;
|
||||||
|
vertical-align: top;
|
||||||
|
border: 1px solid #F8D2CB;
|
||||||
|
padding-left: 20rpx;
|
||||||
|
border-radius: 10rpx;
|
||||||
|
&_main{
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
&_left{
|
||||||
|
padding-right: 10rpx;
|
||||||
|
border-right: 2px dotted #F6D3D7;
|
||||||
|
}
|
||||||
|
&_right{
|
||||||
|
padding: 0 10rpx;
|
||||||
|
background: #FDEFEE;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
.activity_pin {
|
.activity_pin {
|
||||||
width: auto;
|
width: auto;
|
||||||
height: 44rpx;
|
height: 44rpx;
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
<view class="name">{{item.mer_name}}</view>
|
<view class="name">{{item.mer_name}}</view>
|
||||||
<text class="iconfont icon-xiangyou"></text>
|
<text class="iconfont icon-xiangyou"></text>
|
||||||
</navigator>
|
</navigator>
|
||||||
<view class="coupon-btn" v-if="item.hasCoupon>0" @click="giveCoupon(item)">优惠券</view>
|
<!-- <view class="coupon-btn" v-if="item.hasCoupon>0" @click="giveCoupon(item)">优惠券</view> -->
|
||||||
</view>
|
</view>
|
||||||
<navigator v-for="goods in item.list" :key="goods.cart_id" :url='"/pages/goods_details/index?id="+goods.product.product_id'
|
<navigator v-for="goods in item.list" :key="goods.cart_id" :url='"/pages/goods_details/index?id="+goods.product.product_id'
|
||||||
hover-class='none' class='picTxt acea-row'>
|
hover-class='none' class='picTxt acea-row'>
|
||||||
|
@ -52,6 +52,12 @@
|
||||||
<image :src="`${domain}/static/images/svip.png`"></image>
|
<image :src="`${domain}/static/images/svip.png`"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="discount" v-if="goods.productAttr.coupon">
|
||||||
|
<view class="discount_main">
|
||||||
|
<view class="discount_left">可用抵扣</view>
|
||||||
|
<view class="discount_right">{{goods.productAttr.coupon}}券</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='carnum acea-row row-center-wrapper'>
|
<view class='carnum acea-row row-center-wrapper'>
|
||||||
<view class="reduce" :class="goods.numSub || (goods.product.once_max_count>0 && goods.product.once_min_count>0 && goods.cart_num <= goods.product.once_min_count) ? 'on' : ''" @click.stop='subCart(goods)'>-</view>
|
<view class="reduce" :class="goods.numSub || (goods.product.once_max_count>0 && goods.product.once_min_count>0 && goods.cart_num <= goods.product.once_min_count) ? 'on' : ''" @click.stop='subCart(goods)'>-</view>
|
||||||
|
@ -601,6 +607,7 @@
|
||||||
getCartList: function(isChange) {
|
getCartList: function(isChange) {
|
||||||
let that = this;
|
let that = this;
|
||||||
getCartList().then(res => {
|
getCartList().then(res => {
|
||||||
|
console.log(res);
|
||||||
if(checkCart()){
|
if(checkCart()){
|
||||||
that.selectedArr = (Cache.get(CART_ID)&&JSON.parse(Cache.get(CART_ID))) || []
|
that.selectedArr = (Cache.get(CART_ID)&&JSON.parse(Cache.get(CART_ID))) || []
|
||||||
}else{
|
}else{
|
||||||
|
@ -836,6 +843,30 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
|
.discount{
|
||||||
|
color: var(--view-priceColor);
|
||||||
|
font-weight: 700;
|
||||||
|
display: inline-block;
|
||||||
|
margin-top: 10rpx;
|
||||||
|
line-height: 48rpx;
|
||||||
|
min-height: 48rpx;
|
||||||
|
border: 1px solid #F8D2CB;
|
||||||
|
padding-left: 8rpx;
|
||||||
|
font-size: 24rpx;
|
||||||
|
border-radius: 10rpx;
|
||||||
|
&_main{
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
&_left{
|
||||||
|
padding-right: 10rpx;
|
||||||
|
border-right: 2px dotted #F6D3D7;
|
||||||
|
}
|
||||||
|
&_right{
|
||||||
|
padding: 0 10rpx;
|
||||||
|
background: #FDEFEE;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
.shoppingCart .labelNav {
|
.shoppingCart .labelNav {
|
||||||
height: 76rpx;
|
height: 76rpx;
|
||||||
padding: 0 30rpx;
|
padding: 0 30rpx;
|
||||||
|
|
|
@ -282,7 +282,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view> -->
|
||||||
|
|
||||||
<view class="item">
|
<!-- <view class="item">
|
||||||
<view class="uni-list">
|
<view class="uni-list">
|
||||||
<view class="uni-list-cell">
|
<view class="uni-list-cell">
|
||||||
<view class="uni-list-cell-db acea-row row-middle">
|
<view class="uni-list-cell-db acea-row row-middle">
|
||||||
|
@ -318,7 +318,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view> -->
|
||||||
<button class='submitBtn' :disabled="!validate" :class="validate === true ? 'on':''"
|
<button class='submitBtn' :disabled="!validate" :class="validate === true ? 'on':''"
|
||||||
@click="nextStep">下一步</button>
|
@click="nextStep">下一步</button>
|
||||||
</view>
|
</view>
|
||||||
|
@ -494,9 +494,9 @@
|
||||||
// if(isVeteran&&isVeteranPhoto.length==0){
|
// if(isVeteran&&isVeteranPhoto.length==0){
|
||||||
// this.validate=false;
|
// this.validate=false;
|
||||||
// }else
|
// }else
|
||||||
if (isFlagshipStore&&isFlagshipStorePhoto.length==0){
|
// if (isFlagshipStore&&isFlagshipStorePhoto.length==0){
|
||||||
this.validate=false;
|
// this.validate=false;
|
||||||
}else{
|
// }else{
|
||||||
let date2 = {
|
let date2 = {
|
||||||
phone: EnterprisePhone,
|
phone: EnterprisePhone,
|
||||||
mer_name:shopName,
|
mer_name:shopName,
|
||||||
|
@ -527,7 +527,7 @@
|
||||||
|
|
||||||
|
|
||||||
this.validate = true;
|
this.validate = true;
|
||||||
}
|
// }
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
this.validate=false;
|
this.validate=false;
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class='discount' v-else>免运费</view>
|
<view class='discount' v-else>免运费</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='item acea-row row-between-wrapper'
|
<!-- <view class='item acea-row row-between-wrapper'
|
||||||
v-if="order_type != 3 && order_type != 4 && item.order.enabledCoupon">
|
v-if="order_type != 3 && order_type != 4 && item.order.enabledCoupon">
|
||||||
<view>店铺优惠券</view>
|
<view>店铺优惠券</view>
|
||||||
<block v-if="item.coupon.length>0">
|
<block v-if="item.coupon.length>0">
|
||||||
|
@ -154,7 +154,7 @@
|
||||||
<block v-else>
|
<block v-else>
|
||||||
<view class='discount'>暂无优惠券</view>
|
<view class='discount'>暂无优惠券</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view> -->
|
||||||
<view v-if="item.openReceipt == 1" class='item acea-row row-between-wrapper'>
|
<view v-if="item.openReceipt == 1" class='item acea-row row-between-wrapper'>
|
||||||
<view>开具发票 <text @tap="showInvoice" class="iconfont icon-wenhao1"></text></view>
|
<view>开具发票 <text @tap="showInvoice" class="iconfont icon-wenhao1"></text></view>
|
||||||
<view class='discount discount_voice' @tap="goInvoice(item.mer_id)">
|
<view class='discount discount_voice' @tap="goInvoice(item.mer_id)">
|
||||||
|
@ -414,10 +414,10 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='item acea-row row-between-wrapper' v-if="userInfo.now_money>0">
|
<view class='item acea-row row-between-wrapper' v-if="userInfo.now_money>0">
|
||||||
<view>抵扣卷抵扣:</view>
|
<view>抵扣券抵扣:</view>
|
||||||
<view class='money'>
|
<view class='money'>
|
||||||
<text v-if="!now_integral">当前抵扣卷<text class="pColor">{{userInfo.now_money}}</text></text>
|
<text v-if="!now_integral">当前抵扣券<text class="pColor">{{userInfo.now_money}}</text></text>
|
||||||
<text v-else>使用了{{use_count}}个抵扣卷,抵扣<text
|
<text v-else>使用了{{use_count}}个抵扣券,抵扣<text
|
||||||
class="pColor">{{use_amount}}元</text></text>
|
class="pColor">{{use_amount}}元</text></text>
|
||||||
<view class="checkbox integral_checked" @click="changeIntegral('now')">
|
<view class="checkbox integral_checked" @click="changeIntegral('now')">
|
||||||
<view class="iconfont icon-weixuanzhong" v-if="!now_integral"></view>
|
<view class="iconfont icon-weixuanzhong" v-if="!now_integral"></view>
|
||||||
|
@ -425,7 +425,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='item acea-row row-between-wrapper'
|
<!-- <view class='item acea-row row-between-wrapper'
|
||||||
v-if="order_type != 3 && order_type != 4 && enabledPlatformCoupon">
|
v-if="order_type != 3 && order_type != 4 && enabledPlatformCoupon">
|
||||||
<view>平台优惠券<text @tap="showCoupon" class="iconfont icon-wenhao1"></text></view>
|
<view>平台优惠券<text @tap="showCoupon" class="iconfont icon-wenhao1"></text></view>
|
||||||
<block v-if="platformCoupon.length > 0">
|
<block v-if="platformCoupon.length > 0">
|
||||||
|
@ -438,7 +438,7 @@
|
||||||
<block v-else>
|
<block v-else>
|
||||||
<view class='discount'>暂无优惠券</view>
|
<view class='discount'>暂无优惠券</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view> -->
|
||||||
<view class='item acea-row row-between-wrapper' v-if="priceGroup.storePostage > 0">
|
<view class='item acea-row row-between-wrapper' v-if="priceGroup.storePostage > 0">
|
||||||
<view>运费:</view>
|
<view>运费:</view>
|
||||||
<view class='money'>+¥{{priceGroup.storePostage}}</view>
|
<view class='money'>+¥{{priceGroup.storePostage}}</view>
|
||||||
|
@ -811,8 +811,10 @@
|
||||||
console.log(e);
|
console.log(e);
|
||||||
if(e=='use'){
|
if(e=='use'){
|
||||||
this.use_integral = !this.use_integral;
|
this.use_integral = !this.use_integral;
|
||||||
|
this.now_integral = false
|
||||||
}else{
|
}else{
|
||||||
this.now_integral = !this.now_integral;
|
this.now_integral = !this.now_integral;
|
||||||
|
this.use_integral = false
|
||||||
}
|
}
|
||||||
this.getConfirm(this.addressId);
|
this.getConfirm(this.addressId);
|
||||||
},
|
},
|
||||||
|
|
|
@ -75,8 +75,12 @@
|
||||||
number:'',
|
number:'',
|
||||||
image1:[],
|
image1:[],
|
||||||
image2:[],
|
image2:[],
|
||||||
|
type:''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
onLoad(e) {
|
||||||
|
this.type = e.type
|
||||||
|
},
|
||||||
methods:{
|
methods:{
|
||||||
async submitReal(){
|
async submitReal(){
|
||||||
let data1={
|
let data1={
|
||||||
|
@ -87,17 +91,26 @@
|
||||||
}
|
}
|
||||||
await userReal(data1).then((res)=>{
|
await userReal(data1).then((res)=>{
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon:'success',
|
icon:'none',
|
||||||
title: res
|
title: res.message
|
||||||
});
|
});
|
||||||
uni.redirectTo({
|
console.log(this.type);
|
||||||
url: '/pages/user/index',
|
if(this.type == 'edit'){
|
||||||
success: res => {},
|
setTimeout(()=>{
|
||||||
fail: () => {},
|
uni.navigateBack({
|
||||||
complete: () => {}
|
delta: 1
|
||||||
});
|
});
|
||||||
|
},1000)
|
||||||
|
}else{
|
||||||
|
setTimeout(()=>{
|
||||||
|
uni.switchTab({
|
||||||
|
url: '/pages/user/index'
|
||||||
|
});
|
||||||
|
},1000)
|
||||||
|
|
||||||
|
}
|
||||||
}).catch((err)=>{
|
}).catch((err)=>{
|
||||||
|
console.log(this.type);
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon:'none',
|
icon:'none',
|
||||||
title: err
|
title: err
|
||||||
|
@ -275,7 +288,7 @@
|
||||||
border-radius: 60rpx;
|
border-radius: 60rpx;
|
||||||
// background-color: red;
|
// background-color: red;
|
||||||
color: white;
|
color: white;
|
||||||
font-size: 48rpx;
|
font-size: 32rpx;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
line-height: 100rpx;
|
line-height: 100rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
<view class='list acea-row row-between-wrapper'>
|
<view class='list acea-row row-between-wrapper'>
|
||||||
<view class='item' v-for="(item,index) in signConfig" :key="index">
|
<view class='item' v-for="(item,index) in signConfig" :key="index">
|
||||||
<view :class='(index+1) == signConfig.length ? "rewardTxt" : ""'>{{item.value.sign_day}}</view>
|
<view :class='(index+1) == signConfig.length ? "rewardTxt" : ""'>{{item.value.sign_day}}</view>
|
||||||
<view class='venus' :class="(index + 1 === signConfig.length ? 'reward' : '') + '' +(sign_index >= index + 1 ? 'venusSelect' : '')"></view>
|
<view class='venus' :class="(index + 1 === signConfig.length ? 'reward' : '') + '' +(sign_index >= index + 1 ? ' venusSelect' : '')"></view>
|
||||||
<!-- <view class='num' :class='item.is_sgin ? "on" : ""'>+{{item.value.sign_integral}}</view> -->
|
<!-- <view class='num' :class='item.is_sgin ? "on" : ""'>+{{item.value.sign_integral}}</view> -->
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -53,7 +53,7 @@
|
||||||
</view>
|
</view>
|
||||||
<treasureBox v-if="treasureShow" @closeTreasureBox="closeBox"></treasureBox>
|
<treasureBox v-if="treasureShow" @closeTreasureBox="closeBox"></treasureBox>
|
||||||
|
|
||||||
<view class='signTip acea-row row-center-wrapper' :class='active==true?"on":""'>
|
<view class='signTip acea-row row-center-wrapper' v-if="active" :class='active==true?"on":""'>
|
||||||
<view class='signTipLight loadingpic'></view>
|
<view class='signTipLight loadingpic'></view>
|
||||||
<view class='signTipCon' :style="'background-image: url('+domain+'/static/diy/signSuccess'+keyColor+'.png)'">
|
<view class='signTipCon' :style="'background-image: url('+domain+'/static/diy/signSuccess'+keyColor+'.png)'">
|
||||||
<view class='state'>签到成功</view>
|
<view class='state'>签到成功</view>
|
||||||
|
@ -91,7 +91,7 @@
|
||||||
is_sign: false, //是否签到
|
is_sign: false, //是否签到
|
||||||
disabled: false,
|
disabled: false,
|
||||||
treasureShow:false,
|
treasureShow:false,
|
||||||
|
blindShow:false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: mapGetters(['isLogin','viewColor','keyColor']),
|
computed: mapGetters(['isLogin','viewColor','keyColor']),
|
||||||
|
@ -181,31 +181,33 @@
|
||||||
let that = this, sum_sgin_day = that.signConfig.sign_num;
|
let that = this, sum_sgin_day = that.signConfig.sign_num;
|
||||||
if (that.userInfo.is_day_sgin) return this.$util.Tips({title:'您今日已签到!'});
|
if (that.userInfo.is_day_sgin) return this.$util.Tips({title:'您今日已签到!'});
|
||||||
that.disabled = true;
|
that.disabled = true;
|
||||||
if(!that.userInfo.is_day_sgin&&that.sign_index==6){
|
// if(!that.userInfo.is_day_sgin&&that.sign_index==6){
|
||||||
that.blindShow=true;
|
// that.treasureShow=true;
|
||||||
}else{
|
// }else{
|
||||||
that.treasureShow=true;
|
setSignIntegral().then(res=>{
|
||||||
}
|
that.active = true;
|
||||||
// setSignIntegral().then(res=>{
|
that.integral = res.data.integral;
|
||||||
// // that.active = true;
|
that.sign_index = (that.sign_index + 1) > that.signConfig.title.length ? 1 : that.sign_index + 1;
|
||||||
// that.integral = res.data.integral;
|
that.signCount = that.PrefixInteger(sum_sgin_day + 1, 4);
|
||||||
// that.sign_index = (that.sign_index + 1) > that.signConfig.title.length ? 1 : that.sign_index + 1;
|
that.$set(that.userInfo,'is_sgin',true);
|
||||||
// that.signCount = that.PrefixInteger(sum_sgin_day + 1, 4);
|
that.$set(that.userInfo,'integral',that.$util.$h.Add(that.userInfo.integral, res.data.integral));
|
||||||
// that.$set(that.userInfo,'is_sgin',true);
|
}).catch(err=>{
|
||||||
// that.$set(that.userInfo,'integral',that.$util.$h.Add(that.userInfo.integral, res.data.integral));
|
that.disabled = false;
|
||||||
|
return this.$util.Tips({title:err})
|
||||||
// }).catch(err=>{
|
});
|
||||||
// that.disabled = false;
|
// }
|
||||||
// return this.$util.Tips({title:err})
|
|
||||||
// });
|
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* 关闭签到提示
|
* 关闭签到提示
|
||||||
*/
|
*/
|
||||||
close:function(){
|
close:function(){
|
||||||
this.active = false;
|
this.active = false;
|
||||||
this.getSignList();
|
let that = this
|
||||||
this.getUserInfo();
|
if(!that.userInfo.is_day_sgin&&that.sign_index==6){
|
||||||
|
that.treasureShow=true;
|
||||||
|
}
|
||||||
|
// this.getSignList();
|
||||||
|
// this.getUserInfo();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
Loading…
Reference in New Issue