Authored by 毕凯

cookie 增加购物车类型

... ... @@ -33,6 +33,8 @@ if ($couponUse.data('name') !== orderInfo('couponName')) {
orderInfo('couponName', null);
}
orderInfo('cartType', queryString.cartType || queryString.carttype || 'ordinary');
function dispacthTapEvt(e) {
var $cur = $(e.target).closest('li');
... ... @@ -78,7 +80,7 @@ function orderCompute() {
method: 'POST',
url: '/cart/index/orderCompute',
data: {
cartType: queryString.cartType || queryString.carttype || 'ordinary',
cartType: orderInfo('cartType') || 'ordinary',
deliveryId: orderInfo('deliveryId'),
paymentTypeId: orderInfo('paymentTypeId'),
couponCode: orderInfo('couponCode'),
... ... @@ -139,11 +141,12 @@ function submitOrder() {
url: '/cart/index/orderSub',
data: {
addressId: orderInfo('addressId'),
cartType: queryString.cartType || queryString.carttype || 'ordinary',
cartType: orderInfo('cartType') || 'ordinary',
deliveryId: orderInfo('deliveryId'),
deliveryTimeId: orderInfo('deliveryTimeId'),
invoiceText: orderInfo('invoice') ? invoiceText : null,
invoiceType: orderInfo('invoice') ? ($invoice.find('.invoice-type').val() || orderInfo('invoiceType')) : null,
invoiceType: orderInfo('invoice') ? ($invoice.find('.invoice-type').val() ||
orderInfo('invoiceType')) : null,
msg: msg,
paymentTypeId: orderInfo('paymentTypeId'),
paymentType: orderInfo('paymentType'), //支付方式
... ...
... ... @@ -19,7 +19,8 @@ function init() {
invoice: null,
invoiceText: null,
invoiceType: null,
msg: null
msg: null,
cartType: 'ordinary'
};
window.setCookie('order-info', JSON.stringify(info));
}
... ...