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
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
<template>
  <div>
    <FormInfo
      v-if="totalInfoHeader.length > 0 && totalInfo && (typeof totalInfo === 'object' && Object.keys(totalInfo).length > 0)"
      :info="totalInfo"
      title="物业汇总信息"
      :keys="totalInfoHeader"
    ></FormInfo>
 
    <FormInfo
      v-if="objectType === 'BuildingBusinessApply' && occurType === '01'"
      :info="ext"
      title="成交信息"
      :keys="dealInfo"
    ></FormInfo>
 
    <div class="tab-section">
      <el-tabs v-model="activeName" type="card" v-loading="loading">
        <el-tab-pane
          v-for="(item, index) in list"
          :key="index"
          :label="item.buildingprojectname.value  || chineseNum[index.toString()]"
          :name="`${index}`"
        >
          <FormInfo 
            :info="item" 
            title="物业明细信息" 
            :keys="propertyInfo"
            @projectManageDetail='projectManageDetail(item)' 
            @showAgent='acceptShowAgent'
          >
          </FormInfo>
          <KeysTable
            v-if="Array.isArray(item.propertyList) && item.propertyList.length > 0"
            :list="item.propertyList"
            title="产权人信息"
            :header="propertyListHeader"
            :isShowPages="false"
          ></KeysTable>
 
          <KeysTable
            v-if="propertyCertListHeader.length > 0 && Array.isArray(item.propertyList) && item.propertyList.length > 0"
            :list="item.propertyCertList"
            title="权证信息"
            :header="propertyCertListHeader"
            :isShowPages="false"
          ></KeysTable>
          <Agent
            v-if="showAgent"
            :visible="showAgent"
            :houseorparkingid="item.houseorparkingid.value"
            @closeAgent="showAgent = false"
          ></Agent>
        </el-tab-pane>
      </el-tabs>
    </div>
  </div>
</template>
<script>
// 物业信息
import { qryHouseList, queryHouseTotalInfo,projectManageDetail } from '@comprehensive/serve/public'
import {
  propertyInfo,
  creditFlowCommonTotalInfoHeader,
  creditFlowCommonPropertyInfo,
  mortgageFlowPropertyInfo,
  mortgageFlowTotalInfoHeader,
  buildingBusinessFlowInfo,
  buildingBusinessFlowDealInfo
} from '@comprehensive/utils/formHeaders'
import {
  propertyListHeader,
  propertyCertListHeader
} from '@comprehensive/utils/tableHeaders'
import Agent from '@views/product/components/Agent'
import FormInfo from '../FormInfo'
import KeysTable from '../KeysTable'
import { flownos } from '@comprehensive/utils/comm'
 
export default {
  props: {
    // 申请编号
    serialNo: {
      type: String,
      required: true
    },
    objectType: {
      type: String,
      default: ''
    },
    customerID: {
      type: String,
      default: ''
    },
    relationtype: {
      // 01: 共借人信息, 02: 担保人信息
      type: String,
      default: '01'
    },
    flowno: {
      type: String,
 
      // 默认为案场
      default: 'CreditFlowCase'
    },
    // 01 卖方信息, 02 买方信息
    sellerOrBuyer: {
      type: String,
      default: ''
    },
    // 01 交易类, 02 非交易类
    occurType: {
      type: String,
      default: ''
    }
  },
  components: {
    FormInfo,
    KeysTable,
    Agent
  },
  data() {
    return {
      list: {},
      // 成交信息
      ext: {},
      totalInfo: {},
      totalInfoHeader: [],
      activeName: '0',
      propertyInfo: [],
      chineseNum: {
        '0': '物业一',
        '1': '物业二',
        '2': '物业三',
        '3': '物业四',
        '4': '物业五',
        '5': '物业六',
        '6': '物业七',
        '7': '物业八',
        '8': '物业九',
        '9': '物业十'
      },
      loading: false,
      showAgent: false,
 
      // 产权人列表
      propertyListHeader: [...propertyListHeader],
 
      dealInfo: [...buildingBusinessFlowDealInfo],
 
      // 权证信息
      propertyCertListHeader: []
    }
  },
  created() {
    this.init()
  },
  methods: {
    init() {
      const { flowno } = this
      const {
        // 案场
        CreditFlowCase,
 
        // 非案场
        CreditFlowCommon,
 
        // 抵押/易贷
        MortgageFlow,
 
        // 赎楼/快贷
        BuildingBusinessFlow
      } = flownos
      this.activeName = '0'
      let totalInfoHeader = []
      let propertyHeader = []
      let certListHeader = []
 
      if (flowno === CreditFlowCase) {
        propertyHeader = [...propertyInfo]
      }
 
      if (flowno === CreditFlowCommon) {
        propertyHeader = [...creditFlowCommonPropertyInfo]
        totalInfoHeader = [...creditFlowCommonTotalInfoHeader]
      }
      if (flowno === MortgageFlow) {
        propertyHeader = [...mortgageFlowPropertyInfo]
        totalInfoHeader = [...mortgageFlowTotalInfoHeader]
        certListHeader = [...propertyCertListHeader]
      }
 
      if (flowno === BuildingBusinessFlow) {
        propertyHeader = [...buildingBusinessFlowInfo]
        // totalInfoHeader = [...mortgageFlowTotalInfoHeader]
        // certListHeader = [...propertyCertListHeader]
        // if (objectType === 'BuildingBusinessApply' && occurtype === '01') {
        // }
      }
 
      // 物业汇总信息
      this.totalInfoHeader = [...totalInfoHeader]
 
      // 物业明细信息
      this.propertyInfo = [...propertyHeader]
 
      this.propertyCertListHeader = [...certListHeader]
 
      this.qryHouseList()
 
      // 物业汇总信息
      this.queryHouseTotalInfo()
    },
    acceptShowAgent(val){
      this.showAgent = val
    },
    // 查看项目信息
    projectManageDetail(row) {
      projectManageDetail({
        serialno: row.buildingprojectid.value,
        objectType: this.$route.query.objectType
      }).then(res => {
        if (res.code == "00") {
          const { href } = this.$router.resolve({
            name: "detailsProjectInfo",
            query: {
              type: "details",
              dataType: res.result.dataType,
              objectNo: res.result.objectNo,
              objectType: res.result.objectType,
              projectFlag: res.result.projectFlag,
              projectType: res.result.projectType
            }
          });
          window.open(
            href,        
            'newwindow',
            'height=700px, width=1280px, top=100px,left=400px, toolbar=no, menubar=no, scrollbars=yes, resizable=no,location=no, status=no'
          )
        }
      });
    },
    // 查询顶部流程节点状态
    async qryHouseList() {
      this.loading = true
      const { serialNo, customerID } = this
      const res = await qryHouseList({
        businessNo: serialNo,
        customerId: customerID
      })
      this.loading = false
      const { result, ext = {} } = res
      this.list = result.map(item => {
        const {
          buildingprojectid,
          buildingorunit,
          buildingorunitname,
          buildingprojectname,
          houseorparkingid,
          houseorparkingname
        } = item
        return {
          ...item,
          buildingprojectname: {
            ...buildingprojectname,
            visible: buildingprojectid.visible
          },
          buildingorunitname: {
            ...buildingorunitname,
            visible: buildingorunit.visible
          },
          houseorparkingname: {
            ...houseorparkingname,
            visible: houseorparkingid.visible
          }
        }
      })
      this.ext = ext
    },
    async queryHouseTotalInfo() {
      const { serialNo, customerID } = this
      const res = await queryHouseTotalInfo({
        applyserialno: serialNo,
        customerid: customerID
      })
 
      const { result } = res
      this.totalInfo = result
    }
  },
  watch: {
    serialNo() {
      this.init()
    }
  }
}
</script>
 
<style lang="stylus" scoped>
.tab-section 
  margin-top 30px
</style>