orderMixin.js
2.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
export default {
data() {
return {
statusEnum: {
0: '未支付',
1: '已支付',
2: '待收货',
3: '已完成',
4: '售后中',
5: '退款失败',
6: '已退款',
},
qb_statusEnum: {
3: '充值成功',
6: '充值失败',
2: '充值中'
},
channlList: [{
label: '海威',
value: 'HW'
}],
statusList: [{
label: '待收货',
value: [1, 2]
}, {
label: '已完成',
value: [3]
}, {
label: '已退款',
value: [6]
},
{
label: '售后中',
value: [4]
}
],
appereanceList: [{
label: '卡券',
value: 1
}, {
label: '直充',
value: 2
}],
}
},
watch: {
'date' (n) {
let [orderDateStart, orderDateEnd] = n
this.searchObj.orderDateStart = orderDateStart ? `${orderDateStart} 00:00:00` : ''
this.searchObj.orderDateEnd = orderDateEnd ? `${orderDateEnd} 23:59:59` : ''
}
},
methods: {
handleClick({ name, $parent: { $el } }) {
let { target } = $el.dataset
let orderStatus = name ? name.split(',').map(e => Number(e)) : ''
this.searchObj[target] = orderStatus
this.$nextTick(() => {
this.search()
})
},
jump(query, name) {
let parent = name == 'order' ? '/order/detail' : '/sale/detail'
// window.location.href = `./detail.html?orderCode=${orderCode}`
// let target = ['嘀加权益卡管理平台', '运营平台', '权益', parent, '*详情']
// if (window.$config.axios.environment) {
// let arr = name == 'order' ? ['订单管理', '*权益订单详情'] : ['售后管理', '售后详情']
// target = ['权益卡管理平台', '运营平台', 'SCRM权益平台', ...arr]
// }
// console.log(target, { orderCode: query.orderCode })
// this.$root.to(target, { orderCode: query.orderCode })
this.$router.push({ path: parent, query })
},
},
}