...
|
...
|
@@ -73,8 +73,8 @@ function cancelFactory(id) { |
|
|
return new Dialog(options);
|
|
|
}
|
|
|
|
|
|
function shwoRefundDialog(orderId) {
|
|
|
var refundHtml = '';
|
|
|
function showRefundDialog(orderId) {
|
|
|
return ordersApi.refundReason().then(function(result) {
|
|
|
var options = {
|
|
|
mask: false,
|
|
|
btns: [
|
...
|
...
|
@@ -110,12 +110,10 @@ function shwoRefundDialog(orderId) { |
|
|
}
|
|
|
}
|
|
|
],
|
|
|
content: refundHtml,
|
|
|
content: refundDialogTpl(result),
|
|
|
className: 'cancel-dialog'
|
|
|
};
|
|
|
|
|
|
return ordersApi.refundReason(function(result) {
|
|
|
refundHtml = refundDialogTpl(result.data);
|
|
|
active = new Dialog(options);
|
|
|
active.show();
|
|
|
});
|
...
|
...
|
@@ -157,7 +155,7 @@ function buyAgain(id) { |
|
|
data: {orderCode: id}
|
|
|
}).then(function(d) {
|
|
|
if (d.code === 200) {
|
|
|
location.href = '/shopping/cart';
|
|
|
location.href = '/cart/cart';
|
|
|
} else {
|
|
|
new dialog.Alert(d.message).show();
|
|
|
}
|
...
|
...
|
@@ -647,5 +645,5 @@ $('.check-logistics').click(function() { |
|
|
});
|
|
|
|
|
|
$('.refund-apply').on('click', function() {
|
|
|
shwoRefundDialog($(this).closest('.order, .order-detail').data('id'));
|
|
|
showRefundDialog($(this).closest('.order, .order-detail').data('id'));
|
|
|
}); |
...
|
...
|
|