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
<template>
<el-dialog
title="提现详情"
center
append-to-body
:visible.sync="dialogObj.show"
width="90%">
<el-table
:data="detail"
style="width: 100%">
<el-table-column
prop="withdraw_no"
label="提现单号"
>
</el-table-column>
<el-table-column
prop="out_trade_no"
label="订单号"
>
</el-table-column>
<el-table-column
label="用户"
width="200"
className="f-c"
>
<template slot-scope="scope">
<img class="avatar" :src="scope.row.user_avatar"/> {{scope.row.user_nickname}}(ID:{{scope.row.user_id}})
</template>
</el-table-column>
<el-table-column
prop="user_mobile"
label="手机号"
>
</el-table-column>
<el-table-column
label="提现金额"
>
<template slot-scope="scope">
{{ scope.row.money | moneyYuan}}
</template>
</el-table-column>
<el-table-column
label="提现状态"
>
<template slot-scope="scope">
<span :class="{status:true,red:scope.row.status === 2,green:scope.row.status === 1}">
{{ scope.row.status | filterStatus}}
</span>
</template>
</el-table-column>
<el-table-column
label="提现成功时间"
>
<template slot-scope="scope">
{{ scope.row.success_at }}
</template>
</el-table-column>
<el-table-column
label="提现时间"
>
<template slot-scope="scope">
{{ scope.row.created_at }}
</template>
</el-table-column>
<el-table-column
prop="reason"
label="失败原因"
>
</el-table-column>
<el-table-column
prop="desc"
label="备注"
>
</el-table-column>
</el-table>
</el-dialog>
</template>
<script>
import {getWithdrawListApi} from "../../service/api";
export default {
name: "sourceDialog",
props:[
'dialogObj'
],
data(){
return{
detail:[]
}
},
filters:{
moneyYuan:function (value) {
if(!value){
return '';
}
return value = (value/100).toFixed(2) + '元';
},
filterStatus:function (value) {
let msg = '';
if(value === 0){
msg = '审核中'
}else if(value === 1){
msg = '提现成功'
}else if(value === 2){
msg = '提现失败'
}
return msg;
}
},
methods:{
initPage(){
let json = {
out_trade_no:this.dialogObj.out_trade_no,
limit:200
};
getWithdrawListApi(json).then(res=>{
this.detail = res.list
})
}
},
watch:{
'dialogObj.show'(value){
if(value === true){
this.initPage()
}
}
}
}
</script>
<style scoped>
.avatar {
width:50px;
height: 50px;
border-radius: 50%;
}
</style>