withdraw.js
5.48 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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
import moment from 'moment';
let curDay = moment().format('YYYY-MM-DD');
const withdrawStatus = {
0: '提现中',
1: '提现成功',
2: '提现失败'
};
export default function() {
return {
day: curDay,
date: curDay,
dateRange: [curDay, curDay],
beginTime: curDay,
endTime: curDay,
today: moment().format('YYYY-MM-DD'),
yesterday: moment().add(-1, 'days').format('YYYY-MM-DD'),
day7: moment().add(-6, 'days').format('YYYY-MM-DD'),
day30: moment().add(-29, 'days').format('YYYY-MM-DD'),
timeLimit: true,
tableCols: [
{
title: 'ID',
key: 'id',
width: 60,
align: 'center'
},
{
title: '申请时间',
key: 'createTime',
width: 90,
align: 'center'
}, {
title: '结算类型',
key: 'clearingType',
width: 90,
align: 'center'
}, {
title: '商家收款账户',
key: 'targetAccount',
width: 90,
align: 'center'
}, {
title: '申请金额(元)',
key: 'applyAmount',
width: 90,
align: 'center'
}, {
title: '服务费(元)',
key: 'serviceAmount',
width: 90,
align: 'center'
}, {
title: '成功金额(元)',
}, {
title: '提现状态',
key: 'status',
align: 'center',
render: (h, params) => {
const row = params.row;
const as = row.status;
const asText = as === 2 ? `${withdrawStatus[row.status]}(${row.rejectReason})` : withdrawStatus[as];
ow.lineIndex = params.index;
return (
<p class={{'high-light': as === 2}}>{asText}</p>
);
},
className: 'status-column'
}, {
title: '业务单据号',
key: 'statementSn',
width: 90,
align: 'center'
}, {
title: '说明',
}, {
title: '操作人',
key: 'applyPid',
width: 90,
align: 'center'
}, {
title: '操作',
key: 'action',
width: 180,
align: 'center',
render: (h, params) => {
const row = params.row;
return (
<div>
<div class="cell-action-row">
<i-button type="primary" size="small"
onClick={() => this.getDetailById(row.id)}>提现明细</i-button>
</div>
<div class="cell-action-row">
<i-button type="primary" size="small"
onClick={() => this.getInfoById(row.id)}>结算明细</i-button>
</div>
</div>
);
},
className: 'action-column'
}
],
tableData: [],
pageData: {
total: 0,
current: 1,
pageSize: 20
},
filters: {
dateRange: {
label: '起止日期',
model: '',
labelSpan: 8
},
beginTime: '',
endTime: '',
timeFlag: {
label: '时间标志',
model: '',
options: [
{
value: 1,
label: '今天',
},{
value: 2,
label: '昨天',
},{
value: 3,
label: '近7天',
},{
value: 4,
label: '近30天',
}
]
},
withdrawStatus: {
label: '提现状态',
model: '',
labelSpan: 6,
fieldSpan: 18,
options: [
{
value: 0,
label: '提现中',
},
{
value: 1,
label: '提现成功',
},
{
value: 2,
label: '提现失败',
}
]
},
statementSn: {
label: '业务单据号',
model: '',
labelSpan: 6,
fieldSpan: 18
},
targetAccount: {
label: '提现账户',
model: '',
options: [
{
value: 0,
label: 'abcxxx@ert.com',
},
{
value: 1,
label: 'hjkxxx@ihi.com',
}
]
}
}
}
};