...
|
...
|
@@ -27,8 +27,11 @@ function formatPaymentData(data, yasInfo) { |
|
|
deliveryWayList: data.delivery_way || [],
|
|
|
deliveryTimeList: data.delivery_time || [],
|
|
|
promotionList: data.shopping_cart_data.promotion_formula_list,
|
|
|
paymentAmount: data.shopping_cart_data.last_order_amount
|
|
|
paymentAmount: data.shopping_cart_data.last_order_amount,
|
|
|
isJit: false,
|
|
|
package_title_detail: ''
|
|
|
};
|
|
|
let supplierId = 0;
|
|
|
|
|
|
yasInfo = yasInfo || {};
|
|
|
|
...
|
...
|
@@ -41,9 +44,19 @@ function formatPaymentData(data, yasInfo) { |
|
|
yasInfo.skus && yasInfo.skus.push(value.product_sku);
|
|
|
yasInfo.pids && yasInfo.pids.push(value.product_id);
|
|
|
|
|
|
if (!info.isJit && value.is_jit === 'Y') {
|
|
|
supplierId = value.supplier_id;
|
|
|
info.isJit = true;
|
|
|
}
|
|
|
|
|
|
return value;
|
|
|
});
|
|
|
|
|
|
(data.shopping_cart_data && data.shopping_cart_data.package_list || []).some(item => {
|
|
|
info.package_title_detail = item.title || '';
|
|
|
return item === supplierId;
|
|
|
});
|
|
|
|
|
|
let selectWay,
|
|
|
selectTime;
|
|
|
|
...
|
...
|
@@ -94,8 +107,11 @@ function formatShoppingPaymentData(data, yasInfo) { |
|
|
deliveryWayList: data.delivery_way || [],
|
|
|
deliveryTimeList: data.delivery_time || [],
|
|
|
promotionList: data.shopping_cart_data.promotion_formula_list,
|
|
|
paymentAmount: data.shopping_cart_data.last_order_amount
|
|
|
paymentAmount: data.shopping_cart_data.last_order_amount,
|
|
|
isJit: false,
|
|
|
package_title_detail: ''
|
|
|
};
|
|
|
let supplierId = 0;
|
|
|
|
|
|
yasInfo = yasInfo || {};
|
|
|
|
...
|
...
|
@@ -108,9 +124,19 @@ function formatShoppingPaymentData(data, yasInfo) { |
|
|
yasInfo.skus && yasInfo.skus.push(value.product_sku);
|
|
|
yasInfo.pids && yasInfo.pids.push(value.product_id);
|
|
|
|
|
|
if (!info.isJit && value.is_jit === 'Y') {
|
|
|
supplierId = value.supplier_id;
|
|
|
info.isJit = true;
|
|
|
}
|
|
|
|
|
|
return value;
|
|
|
});
|
|
|
|
|
|
(data.shopping_cart_data && data.shopping_cart_data.package_list || []).some(item => {
|
|
|
info.package_title_detail = item.title || '';
|
|
|
return item === supplierId;
|
|
|
});
|
|
|
|
|
|
let selectWay,
|
|
|
selectTime;
|
|
|
|
...
|
...
|
@@ -166,7 +192,10 @@ Page({ |
|
|
invoiceNeedStatus: false,
|
|
|
|
|
|
promotionList: [],
|
|
|
paymentAmount: ''
|
|
|
paymentAmount: '',
|
|
|
|
|
|
isJit: false,
|
|
|
package_title_detail: ''
|
|
|
},
|
|
|
onLoad(options) {
|
|
|
this.orderData = options;
|
...
|
...
|
@@ -180,9 +209,7 @@ Page({ |
|
|
if (this.orderData.productSku) {
|
|
|
this.loadEnsurePayment({buyNumber: this.orderData.buyNumber, productSku: this.orderData.productSku});
|
|
|
} else {
|
|
|
setTimeout(() => {
|
|
|
this.loadShoppingPayment(options);
|
|
|
}, 1500);
|
|
|
}
|
|
|
|
|
|
yas = new Yas(app);
|
...
|
...
|
|