ChangeDetailDialog.vue
1.88 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
<!-- 对账单管理 - 变更说明弹窗 -->
<template>
<d2-dialog title="变更说明" :is-visible="detailVisible" class="privacyDailog" width="1080px" btnOkLabel="关闭" :noCancel="true" @closeDialog="handleClose" @confirmDialog="handleClose">
<d2-table ref="tmplTable" :get-list-api="getListApi" :search-form="searchForm" :table-params="tableParams" :before-search-fn="beforeSearchFn">
</d2-table>
</d2-dialog>
</template>
<script>
import { getBillDetailList } from '@api/accountManage'
import { Util, deepClone } from '@/common/util'
export default {
name: 'ChangeDetailDialog',
data() {
return {
searchForm: {},
getListApi: getBillDetailList,
tableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000),
listName: 'list',
tableOption: false,
tableColumns: [{
label: '变更类型',
prop: 'changeType',
formatter: (cellValue) => {
return {1: '删除', 2: '新增'}[cellValue.changeType]
}
}, {
label: '订单编码',
prop: 'orderCode',
}, {
label: '变更人',
prop: 'operator',
}, {
label: '变更时间',
width: '150px',
prop: 'createdDate',
formatter: (cellValue) => {
return Util.dateFormate(cellValue.createdDate, 'YYYY-MM-DD HH:mm:ss')
}
}]
}
}
},
props: {
detailVisible: {
type: Boolean,
default: false
},
info: {
type: Object,
default: () => []
}
},
mounted() {
},
methods: {
beforeSearchFn() {
return new Promise(resolve => {
this.searchForm.reconciliationBillId = this.info.id
resolve()
})
},
handleClose() {
this.$emit('dialogClose')
}
}
}
</script>
<style>
.privacyDailog .el-dialog {
min-width: 700px;
}
</style>