Commit b26390be by 肖康

购物车交互修改

parent 1869bf97
......@@ -63,6 +63,9 @@ define('car', ['tool', 'liexin_pop', 'artTemplate'], function (require, exports,
var parents=$(this).parents(".tr")
var max_num=Number($(this).attr("maxNum"));
var min_num=Number($(this).attr("minNum"));
var mult= Number($(this).attr("mult"));
num = Math.ceil(num / mult) * mult;
$(this).val(num)
if(num>max_num){
$(this).val(max_num)
liexin_pop.Tip({ title: "At Most "+max_num })
......@@ -89,7 +92,7 @@ define('car', ['tool', 'liexin_pop', 'artTemplate'], function (require, exports,
}
})
}, 300))
}, 600))
//删除购物车
$(".delcarsd").click(function(){
var arr_=[]
......
......@@ -120,7 +120,7 @@
</div>
<div class="td w119">{{value.hk_delivery_time}}</div>
<div class="td w93">
<input type="text" class="valuep" goods_id="{{value.goods_id}}" minNum="{{value.moq}}" maxNum="{{value.max_buy_stock}}" value="{{value.buy_number}}" onkeyup="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}" onafterpaste="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}">
<input type="text" class="valuep" goods_id="{{value.goods_id}}" mult="{{value.mult}}" minNum="{{value.moq}}" maxNum="{{value.max_buy_stock}}" value="{{value.buy_number}}" onkeyup="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}" onafterpaste="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}">
</div>
<div class="td w110">{{value.stock}}</div>
<div class="td w92">$<span class="rowdj">{{value.buy_price}}</span></div>
......
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 sign in to comment