...
|
...
|
@@ -140,20 +140,27 @@ |
|
|
if(goods_id.length == 0){
|
|
|
alert('不能为空');
|
|
|
}else{
|
|
|
goods_id = goods_id.join(',');
|
|
|
myprice = $('#myprice').text();
|
|
|
$.post("{:url('Shopcart/shop_cart_pay')}",{id:goods_id,myprice:myprice},function(data){
|
|
|
obj = JSON.parse(data);
|
|
|
if(obj.type == 3){
|
|
|
alert('业务员商品和平台商品不能同时购买!');
|
|
|
}else if(obj.type == 1){
|
|
|
window.location.href = "{:url('Orderpage/order_page')}?indet_id="+obj.indet_id;
|
|
|
}else if(obj.type == 2){
|
|
|
window.location.href = "{:url('Orderpage/order_salesman_ty')}?indet_id="+obj.indet_id;
|
|
|
}
|
|
|
$.post("{:url('Shopcart/is_to_pay')}",{},function(data){
|
|
|
if(data){
|
|
|
goods_id = goods_id.join(',');
|
|
|
myprice = $('#myprice').text();
|
|
|
$.post("{:url('Shopcart/shop_cart_pay')}",{id:goods_id,myprice:myprice},function(data){
|
|
|
obj = JSON.parse(data);
|
|
|
if(obj.type == 3){
|
|
|
alert('业务员商品和平台商品不能同时购买!');
|
|
|
}else if(obj.type == 1){
|
|
|
window.location.href = "{:url('Orderpage/order_page')}?indet_id="+obj.indet_id;
|
|
|
}else if(obj.type == 2){
|
|
|
window.location.href = "{:url('Orderpage/order_salesman_ty')}?indet_id="+obj.indet_id;
|
|
|
}
|
|
|
|
|
|
});
|
|
|
}else{
|
|
|
alert('业务员不能购买书籍');
|
|
|
}
|
|
|
});
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
...
|
...
|
|