Browse Source

上朵修改结算新增优惠券,商品页面删除 “免运费”

wangxiaoming 6 years ago
parent
commit
436be6bbc9
3 changed files with 13 additions and 6 deletions
  1. 8 4
      tooth/clearing.html
  2. 1 1
      tooth/pro-details.html
  3. 4 1
      watero/20190512.html

+ 8 - 4
tooth/clearing.html

@@ -260,14 +260,18 @@
 											wechatAddr.status = false;
 										}
 										$(".count_price").text(accDiv(dt.data.payTotal,100));
-										//var oldTotal = fullSub(dt.data.payTotal);
 										
-										$(".pay_price,.all_price").text(accDiv(fullSub(dt.data.payTotal),100));
+										var oldTotal = accDiv(fullSub(dt.data.payTotal),100);
+										
 										if(accDiv(fullSub(dt.data.payTotal),100) < 30){
 											$(".sales_postage").text(10);
+											oldTotal = accAdd(oldTotal,10);
 										}else{
 											$(".sales_postage").text(0);
 										}
+										
+										$(".pay_price,.all_price").text(oldTotal);
+										
 										//$("#pro-count").text(proCount);
 										$(".loading").hide().css("opacity", "0"); //隐藏(正在加载...)
 									} else {
@@ -337,7 +341,7 @@
 							var otherPrice = 0;//其他商品总金额
 							var couponPrice = $(".my-picker input[name=radio]:checked").attr("val");	//优惠券金额
 							mui.each(orderItem,function(index){
-								if(this.productType == 101 && this.cartProductId != 310 ){	//刷头类
+								if(this.productType == 101 && this.cartProductId != 310 && this.cartProductId != 79 && this.cartProductId != 81){	//刷头类
 									var brPrice = this.productPrice;	//优惠券金额
 									if(brushCouponPrice == 0 || brushCouponPrice < brPrice){
 										brushCouponPrice = brPrice;
@@ -352,7 +356,7 @@
 							var otherPrice = 0;//其他商品总金额
 							var couponPrice = $(".my-picker input[name=radio]:checked").attr("val");	//优惠券金额
 							mui.each(orderItem,function(index){
-								if(this.productType == 101 && this.cartProductId != 310 ){
+								if(this.productType == 101 && this.cartProductId != 310 && this.cartProductId != 79 && this.cartProductId != 81){
 									brushPrice = accAdd(brushPrice,this.productPrice*this.cartNum);
 								}else{
 									otherPrice = accAdd(otherPrice,this.productPrice*this.cartNum);

+ 1 - 1
tooth/pro-details.html

@@ -44,7 +44,7 @@
 							<div class="pro-details-name" style="padding:15px 0 0 0;"></div>
 						</li>
 						<li style="padding: 11px 0;" class="mui-table-view-cell mui-text-center">
-							<span class="mui-pull-left cl-red price">¥0.0</span><span class="mui-h6">运费:免运费</span><span class="iconfont icon-fenxiang mui-pull-right" style="font-size: 16px;color: #999;padding: 10px;position: absolute;right: 0;top: 0;"></span>
+							<span class="mui-pull-left cl-red price">¥0.0</span><span class="mui-h6"></span><span class="iconfont icon-fenxiang mui-pull-right" style="font-size: 16px;color: #999;padding: 10px;position: absolute;right: 0;top: 0;"></span>
 						</li>
 						<li style="padding: 11px 0 11px 7px;" class="mui-table-view-cell">
 							<a class="mui-navigate-right select-color">

+ 4 - 1
watero/20190512.html

@@ -150,7 +150,10 @@ $(window).ajaxStop(function(){
 									console.log(dt)
 									if(dt.resultCode == "200") {
 										$(".loading").hide().css("opacity", "0");
-										location.reload();
+										mui.alert('哎呀,您来晚了,别伤心,你写给妈妈的爱,已参与“妈妈的三行情书”评选征集,还有机会获得美丽大奖哦,祝你好运。', '确定', function() {
+											location.reload();
+										});
+										return false;
 									} else {
 										$(".loading").hide().css("opacity", "0");
 										mui.alert(dt.message);