zhaoxiaoqiang1
2026-01-04 f1d30d03186c79ca2cbcfe60d6d2ce7d73fba97b
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
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
<template>
  <div class="main">
    <h3 class="top-title">订单详情
      <el-button size="mini"
               @click="goBack"
               class="back-btn">
      <i class="el-icon-back">返回列表</i>
    </el-button></h3>
 
    <FormInfo title="个人信息"
              :info="personInfo"
              :keys="hebaoCustomerHeader"
              :loading="loading"></FormInfo>
 
    <FormInfo title="商品信息"
              :info="goodsInfo"
              :keys="hebaoGoodsHeader"
              :loading="loading1"></FormInfo>
 
    <p class="section-title">联系人信息</p>
    <TableList :isAutoIndex="false"
               :isShowPages="false"
               :loading="loading"
               :list="relationList"
               :header="heBaoRelationInfoHeader"
               @doAction="doAction"></TableList>
 
    <p class="section-title">还款计划</p>
    <ul class="dis-flex">
      <li class="flex1">应还总金额:{{form.totalAmount || '-'}}</li>
      <li class="flex1"> 已还总金额:{{form.actualTotalAmount || '-'}}</li>
      <li class="flex1">当前逾期欠款:{{form.overdueAmount || '-'}}</li>
    </ul>
 
    <TableList :isAutoIndex="false"
               :isShowPages="false"
               :loading="loading2"
               :list="records"
               :header="heBaoRepayInfoHeader"
               @doAction="doAction"></TableList>
 
  </div>
</template>
<script>
/**
 * 订单查询列表-详情
 */
import {
    heBaoselectHeBaoGoodsInfo,
    heBaoSelectHeBaoPersonInfo,
    heSelectHeBaoRepayInfo
} from '@comprehensive/serve/public'
import {
    heBaoRepayInfoHeader,
    heBaoRelationInfoHeader
} from '@comprehensive/utils/tableHeaders'
import TabContent from './components/TabContent'
import HeaderSteps from './components/HeaderSteps'
import ScrollToTab from './components/ScrollToTab'
import FormInfo from './components/FormInfo'
import TableList from './components/TableList'
import {
    hebaoCustomerHeader,
    hebaoGoodsHeader
} from '@comprehensive/utils/formHeaders'
export default {
    components: {
        TabContent,
        HeaderSteps,
        ScrollToTab,
        FormInfo,
        TableList
    },
    data() {
        return {
            form: {},
            trackInfo: {},
            list: [],
            records: [],
            hebaoCustomerHeader,
            hebaoGoodsHeader,
            heBaoRepayInfoHeader,
            heBaoRelationInfoHeader,
            serialNo: '',
            loading: false,
            loading1: false,
            loading2: false,
            dialogComplainVisible: false,
            personInfo: {},
            goodsInfo: {},
            relationList: []
        }
    },
    created() {
  },
    mounted() {
        this.init()
        this.setEleHeight()
        window.addEventListener('resize', this.setEleHeight)
    },
    methods: {
        async init() {
            this.serialNo = this.$route.params.id
          await this.getPersonInfo()
          await this.getGoodsInfo()
            this.getrepayInfo()
        },
 
        async getPersonInfo() {
            this.loading = true
            const res = await heBaoSelectHeBaoPersonInfo({
                busiNo: this.serialNo
            })
            if (res.code == '00') {
                this.personInfo = res.result
                this.relationList = res.result.relationList
            }
            this.loading = false
        },
        async getGoodsInfo() {
            this.loading1 = true
            const res = await heBaoselectHeBaoGoodsInfo({
                busiNo: this.serialNo
            })
            if (res.code == '00') {
                this.goodsInfo = res.result
        this.personInfo = {...this.personInfo, mobileNo: res.result.mobileNo || ''}
            }
            this.loading1 = false
        },
 
        async getrepayInfo() {
            this.loading2 = true
            const res = await heSelectHeBaoRepayInfo({ busiNo: this.serialNo })
            if (res.code == '00') {
                this.form = res.result
                this.records = res.result.repayDetailList
            }
            this.loading2 = false
        },
        // 表单事件回调
        doAction(name, item, { label }) {
            if (name === 'lastAction') {
            }
        },
 
        setEleHeight() {
            const clientHeight = document.documentElement.clientHeight
            this.clientHeight = clientHeight || 600
        },
 
        // 返回列表
        goBack() {
            window.history.go(-1)
        }
    },
    computed: {
        currTabItem() {
            let { tabIndex, treeList } = this
            return treeList[tabIndex] || {}
        }
    },
    watch: {
        // $route() {
        //     this.init()
        // }
    },
    beforeRouteEnter(to, from, next) {
        next(vm => {
            vm.$store.commit('SET_detailBackRoute', from.path)
        })
    },
    beforeDestroy() {
        window.removeEventListener('resize', this.setEleHeight)
    }
}
</script>
 
<style lang="postcss" scoped>
.main {
    padding: 0 30px 30px;
    background: #fff;
    & .section-title {
        margin: 30px 0 20px 0;
        padding: 0 0 0 10px;
        border-left: solid 2px #0081f0;
        line-height: 16px;
        font-size: 14px;
        color: #222222;
    }
    & .btn-block {
        margin-bottom: 20px;
    }
 
  & .top-title {
    font-size: 16px;
    border-bottom: solid 2px #eeeeee;
    color: #000;
    padding: 16px 20px;
    margin-bottom: 10px;
    font-weight: 500;
    & .back-btn {
      float: right;
    }
  }
 
    & .dis-flex {
    width: 50%;
    padding: 20px 0;
        display: flex;
        align-items: center;
 
        & .flex1 {
            flex: 1;
        }
 
        & .flex2 {
            flex: 2;
        }
    }
}
</style>