...
|
...
|
@@ -72,6 +72,7 @@ const invoiceText = { |
|
|
2: '电子'
|
|
|
};
|
|
|
|
|
|
|
|
|
// 订单状态
|
|
|
const statusMap = {
|
|
|
0: {
|
...
|
...
|
@@ -282,11 +283,13 @@ const deleteOrder = (uid, code) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
const cancelOrder = (uid, code) => {
|
|
|
const cancelOrder = (uid, data) => {
|
|
|
return api.get('', {
|
|
|
method: 'app.SpaceOrders.close',
|
|
|
uid: uid,
|
|
|
order_code: code
|
|
|
order_code: data.orderCode,
|
|
|
reason_id: data.reasonId,
|
|
|
reason: data.reason
|
|
|
}, {
|
|
|
cache: true
|
|
|
});
|
...
|
...
|
@@ -328,6 +331,19 @@ const getOrderData = (uid, type, page) => { |
|
|
]
|
|
|
};
|
|
|
|
|
|
const emptyMsg = {
|
|
|
1: {
|
|
|
text: '您暂时还没有订单',
|
|
|
showEmptyEn: true
|
|
|
},
|
|
|
2: {
|
|
|
text: '您暂时还没有待付款的订单'
|
|
|
},
|
|
|
3: {
|
|
|
text: '您暂时还没有待收货的订单'
|
|
|
}
|
|
|
}
|
|
|
|
|
|
type = parseInt(type, 10);
|
|
|
|
|
|
type = type < 4 ? type : 1;
|
...
|
...
|
@@ -342,6 +358,13 @@ const getOrderData = (uid, type, page) => { |
|
|
type: type
|
|
|
};
|
|
|
|
|
|
const empty = {
|
|
|
showEmptyEn: emptyMsg[type].showEmptyEn,
|
|
|
emptyMsg: emptyMsg[type].text
|
|
|
}
|
|
|
|
|
|
console.log(empty);
|
|
|
|
|
|
navBar.tabs[typeActiveIndexMap[type]].isActive = true;
|
|
|
|
|
|
const order = Object.assign(basicData, {
|
...
|
...
|
@@ -357,7 +380,7 @@ const getOrderData = (uid, type, page) => { |
|
|
} : false;
|
|
|
|
|
|
return {
|
|
|
order: Object.assign(order, paginationOpts)
|
|
|
order: Object.assign(order, paginationOpts, empty)
|
|
|
};
|
|
|
});
|
|
|
};
|
...
|
...
|
|