...
|
...
|
@@ -222,26 +222,30 @@ var Cart = { |
|
|
var msg = '确定要将该商品从购物车中移入收藏吗?<br/>移入收藏后该商品将不在购物车中显示';
|
|
|
var dialog;
|
|
|
|
|
|
if (products.length > 1) {
|
|
|
msg = '确定要将已选中的商品从购物车中移入收藏吗?<br/>移入收藏后已选中的商品将不在购物车中显示';
|
|
|
}
|
|
|
|
|
|
dialog = new _confirm({
|
|
|
content: msg,
|
|
|
cb: function() {
|
|
|
dialog.close();
|
|
|
Util.ajax({
|
|
|
url: '/shopping/cart/product/send_to_favorite',
|
|
|
type: 'POST',
|
|
|
data: {skuList: JSON.stringify(products)},
|
|
|
success: function(res) {
|
|
|
Util.refreshCart(res, function() {
|
|
|
Stepper.init();
|
|
|
});
|
|
|
}
|
|
|
});
|
|
|
if(!products.length) {
|
|
|
new _alert('请至少选中一件商品!').show();
|
|
|
} else{
|
|
|
if (products.length > 1) {
|
|
|
msg = '确定要将已选中的商品从购物车中移入收藏吗?<br/>移入收藏后已选中的商品将不在购物车中显示';
|
|
|
}
|
|
|
}).show();
|
|
|
|
|
|
dialog = new _confirm({
|
|
|
content: msg,
|
|
|
cb: function() {
|
|
|
dialog.close();
|
|
|
Util.ajax({
|
|
|
url: '/shopping/cart/product/send_to_favorite',
|
|
|
type: 'POST',
|
|
|
data: {skuList: JSON.stringify(products)},
|
|
|
success: function(res) {
|
|
|
Util.refreshCart(res, function() {
|
|
|
Stepper.init();
|
|
|
});
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
}).show();
|
|
|
}
|
|
|
},
|
|
|
|
|
|
// 编辑商品的颜色和尺寸
|
...
|
...
|
|