|
@@ -111,7 +111,7 @@
|
|
<text v-if="ExchangeCouponData.couponType == 3">仅限购买店铺【{{ ExchangeCouponData.shopName }}】的商品</text>
|
|
<text v-if="ExchangeCouponData.couponType == 3">仅限购买店铺【{{ ExchangeCouponData.shopName }}】的商品</text>
|
|
<text v-if="ExchangeCouponData.couponType == 4 || ExchangeCouponData.couponType == 2">全商城商品通用</text>
|
|
<text v-if="ExchangeCouponData.couponType == 4 || ExchangeCouponData.couponType == 2">全商城商品通用</text>
|
|
</view>
|
|
</view>
|
|
- <view class="list-cell-time">有效期:{{ ExchangeCouponData.startDate }} - {{ ExchangeCouponData.endDate }}</view>
|
|
|
|
|
|
+ <view class="list-cell-time">{{ ExchangeCouponData.startDate }} - {{ ExchangeCouponData.endDate }}</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="coupon-btn" @click.stop="handleClickCancel">立即收下</view>
|
|
<view class="coupon-btn" @click.stop="handleClickCancel">立即收下</view>
|
|
@@ -262,8 +262,8 @@
|
|
this.couponList = data.couponList
|
|
this.couponList = data.couponList
|
|
this.reducedPrice = data.reducedPrice
|
|
this.reducedPrice = data.reducedPrice
|
|
this.allPrice = data.totalAmount
|
|
this.allPrice = data.totalAmount
|
|
|
|
+ this.isCouponShow = true
|
|
if(this.couponList.length>0){
|
|
if(this.couponList.length>0){
|
|
- this.isCouponShow = true
|
|
|
|
this.couponAmount = data.couponList[0].couponAmount
|
|
this.couponAmount = data.couponList[0].couponAmount
|
|
this.clubCouponId = data.couponList[0].clubCouponId
|
|
this.clubCouponId = data.couponList[0].clubCouponId
|
|
this.payAllPrice = this.allPrice - this.couponAmount
|
|
this.payAllPrice = this.allPrice - this.couponAmount
|
|
@@ -296,9 +296,11 @@
|
|
this.isFreight = true
|
|
this.isFreight = true
|
|
this.freightData = response.data
|
|
this.freightData = response.data
|
|
if(response.data.freePostFlag== 1){
|
|
if(response.data.freePostFlag== 1){
|
|
- this.payAllPrice = this.allPrice+response.data.freight
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice + response.data.freight
|
|
|
|
+ this.attributePallPrice()
|
|
}else{
|
|
}else{
|
|
this.payAllPrice = this.allPrice
|
|
this.payAllPrice = this.allPrice
|
|
|
|
+ this.attributePallPrice()
|
|
}
|
|
}
|
|
})
|
|
})
|
|
})
|
|
})
|
|
@@ -328,7 +330,7 @@
|
|
handleChoiceaFreightData(data){//获取运费信息
|
|
handleChoiceaFreightData(data){//获取运费信息
|
|
if(data.freePostFlag == '1'){
|
|
if(data.freePostFlag == '1'){
|
|
this.freightData = data
|
|
this.freightData = data
|
|
- this.payAllPrice = this.allPrice+parseInt(data.freight)
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice + parseInt(data.freight)
|
|
this.attributePallPrice()
|
|
this.attributePallPrice()
|
|
}else{
|
|
}else{
|
|
this.freightData = data
|
|
this.freightData = data
|
|
@@ -355,11 +357,13 @@
|
|
}else{
|
|
}else{
|
|
this.balanceDeductionFlag = 2
|
|
this.balanceDeductionFlag = 2
|
|
if(this.freightData.freePostFlag == 1 || this.freightData.freePostFlag == '1'){
|
|
if(this.freightData.freePostFlag == 1 || this.freightData.freePostFlag == '1'){
|
|
- this.payAllPrice = this.allPrice+parseInt(this.freightData.freight)
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice + parseInt(this.freightData.freight) - this.couponAmount
|
|
}else{
|
|
}else{
|
|
- this.payAllPrice = this.allPrice
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice - this.couponAmount
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ console.log('最终订单支付金额',this.payAllPrice)
|
|
|
|
+ console.log('优惠券金额',this.couponAmount)
|
|
}else{
|
|
}else{
|
|
return
|
|
return
|
|
}
|
|
}
|
|
@@ -373,38 +377,43 @@
|
|
},
|
|
},
|
|
attributeNofreight(){//计算没有邮费的支付价格
|
|
attributeNofreight(){//计算没有邮费的支付价格
|
|
if(this.ischecked){
|
|
if(this.ischecked){
|
|
- if(this.userMoney>this.payAllPrice){
|
|
|
|
|
|
+ let totalAmount = this.allPrice - this.couponAmount//计算不包邮的价格 总价等于商品价格+邮费
|
|
|
|
+ if(this.userMoney > totalAmount){
|
|
this.payAllPrice = 0.00
|
|
this.payAllPrice = 0.00
|
|
- this.deductMoney = this.allPrice //勾选后使用抵余额
|
|
|
|
- this.surplusMoney = this.userMoney - this.deductMoney //勾选后的剩余抵扣
|
|
|
|
|
|
+ this.deductMoney = this.allPrice - this.couponAmount // 勾选后使用抵余额
|
|
|
|
+ this.surplusMoney = this.userMoney - this.deductMoney // 勾选后的剩余抵扣
|
|
}else{
|
|
}else{
|
|
- this.payAllPrice = this.allPrice - this.userMoney - this.couponAmount //勾选后的总价
|
|
|
|
- this.deductMoney = this.userMoney //勾选后使用抵余额
|
|
|
|
- this.surplusMoney = this.userMoney - this.deductMoney //勾选后的剩余抵扣
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice - this.userMoney - this.couponAmount //勾选后的总价
|
|
|
|
+ this.deductMoney = this.userMoney // 勾选后使用抵余额
|
|
|
|
+ this.surplusMoney = this.userMoney - this.deductMoney // 勾选后的剩余抵扣
|
|
}
|
|
}
|
|
}else{
|
|
}else{
|
|
this.payAllPrice = this.allPrice - this.couponAmount;
|
|
this.payAllPrice = this.allPrice - this.couponAmount;
|
|
- this.deductMoney = 0.00;
|
|
|
|
- this.surplusMoney = this.userMoney;
|
|
|
|
|
|
+ this.deductMoney = 0.00
|
|
|
|
+ this.surplusMoney = this.userMoney
|
|
}
|
|
}
|
|
|
|
+ console.log('最终订单支付金额',this.payAllPrice)
|
|
|
|
+ console.log('优惠券金额',this.couponAmount)
|
|
},
|
|
},
|
|
attributeHashfreight(freight){//计算需要邮费的支付价格
|
|
attributeHashfreight(freight){//计算需要邮费的支付价格
|
|
- this.payAllPrice = this.allPrice+parseInt(freight)//计算不包邮的价格 总价等于商品价格+邮费
|
|
|
|
|
|
+ let totalAmount = this.allPrice + parseInt(freight) - this.couponAmount//计算不包邮的价格 总价等于商品价格+邮费
|
|
if(this.ischecked){
|
|
if(this.ischecked){
|
|
- if(this.userMoney>this.payAllPrice){ //余额大于支付金额
|
|
|
|
- this.payAllPrice =0.00
|
|
|
|
- this.deductMoney = this.allPrice+parseInt(freight) //勾选后使用抵余额
|
|
|
|
|
|
+ if(this.userMoney > totalAmount ){ //余额大于支付金额
|
|
|
|
+ this.payAllPrice = 0.00
|
|
|
|
+ this.deductMoney = this.allPrice + parseInt(freight) - this.couponAmount //勾选后使用抵余额
|
|
this.surplusMoney = this.userMoney - this.deductMoney //勾选后的剩余抵扣
|
|
this.surplusMoney = this.userMoney - this.deductMoney //勾选后的剩余抵扣
|
|
}else{
|
|
}else{
|
|
- this.payAllPrice = this.allPrice+parseInt(freight) - this.userMoney - this.couponAmount //勾选后的总价
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice + parseInt(freight) - this.userMoney - this.couponAmount //勾选后的总价
|
|
this.deductMoney = this.userMoney //勾选后使用抵余额
|
|
this.deductMoney = this.userMoney //勾选后使用抵余额
|
|
this.surplusMoney = this.userMoney - this.deductMoney //勾选后的剩余抵扣
|
|
this.surplusMoney = this.userMoney - this.deductMoney //勾选后的剩余抵扣
|
|
}
|
|
}
|
|
}else{
|
|
}else{
|
|
- this.payAllPrice = this.allPrice+parseInt(freight) - this.couponAmount
|
|
|
|
|
|
+ this.payAllPrice = this.allPrice + parseInt(freight) - this.couponAmount
|
|
this.deductMoney = 0.00
|
|
this.deductMoney = 0.00
|
|
this.surplusMoney = this.userMoney
|
|
this.surplusMoney = this.userMoney
|
|
}
|
|
}
|
|
|
|
+ console.log('最终订单支付金额',this.payAllPrice)
|
|
|
|
+ console.log('优惠券金额',this.couponAmount)
|
|
},
|
|
},
|
|
orderSubmitMit(){//提交订单
|
|
orderSubmitMit(){//提交订单
|
|
if(this.addressID == ''){
|
|
if(this.addressID == ''){
|
|
@@ -814,6 +823,12 @@
|
|
font-size: $font-size-26;
|
|
font-size: $font-size-26;
|
|
color: #333333;
|
|
color: #333333;
|
|
float: left;
|
|
float: left;
|
|
|
|
+ text-overflow:ellipsis;
|
|
|
|
+ display: -webkit-box;
|
|
|
|
+ word-break: break-all;
|
|
|
|
+ -webkit-box-orient: vertical;
|
|
|
|
+ -webkit-line-clamp: 1;
|
|
|
|
+ overflow: hidden;
|
|
}
|
|
}
|
|
.list-cell-time{
|
|
.list-cell-time{
|
|
width: 100%;
|
|
width: 100%;
|