fix
13404089107
2025-04-11 eb296bfbd3f18dff5a2ee60b42f8415d51c897b9
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
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
<template>
  <div class="app-container">
    <!-- 搜索区域 -->
    <div class="filter-container">
      <el-form :inline="true" :model="queryParams" class="demo-form-inline">
        <el-form-item label="镇街">
          <el-input v-model="queryParams.street" size="small" placeholder="请输入" clearable></el-input>
        </el-form-item>
        <el-form-item label="所在村(社区)">
          <el-input v-model="queryParams.community" size="small" placeholder="请输入" clearable></el-input>
        </el-form-item>
        <el-form-item label="项目名称">
          <el-input v-model="queryParams.projectName" size="small" placeholder="请输入" clearable></el-input>
        </el-form-item>
        <el-form-item label="户主姓名">
          <el-input v-model="queryParams.householdHead" size="small" placeholder="请输入" clearable></el-input>
        </el-form-item>
        <el-form-item>
          <el-button type="primary" size="small" @click="handleQuery">查询</el-button>
          <el-button type="primary" plain size="small" @click="handleReset">重置</el-button>
        </el-form-item>
      </el-form>
    </div>
 
    <!-- Tab切换区域 -->
    <div class="tab-container">
      <el-tabs v-model="activeTab" type="card" @tab-click="handleTabClick">
        <el-tab-pane label="资金表" name="fullReport"></el-tab-pane>
        <el-tab-pane label="购房信息表" name="houseInfo"></el-tab-pane>
      </el-tabs>
    </div>
 
    <!-- 统计卡片区域 -->
    <div class="statistics-container">
      <el-row :gutter="20">
        <el-col :span="6">
          <el-card class="statistics-card" shadow="hover">
            <div class="card-amount">{{ detailData.totalAmount || 0 }}万元</div>
            <div class="card-title">补偿资金总金额</div>
          </el-card>
        </el-col>
        <el-col :span="6">
          <el-card class="statistics-card" shadow="hover">
            <div class="card-amount">{{ detailData.downPaymentAmount || 0 }}万元</div>
            <div class="card-title">首付款总金额</div>
          </el-card>
        </el-col>
        <el-col :span="6">
          <el-card class="statistics-card" shadow="hover">
            <div class="card-amount">{{ detailData.subsidyAmount || 0 }}万元</div>
            <div class="card-title">过渡补贴总金额</div>
          </el-card>
        </el-col>
        <el-col :span="6">
          <el-card class="statistics-card" shadow="hover">
            <div class="card-amount">{{ detailData.quarterPayAmount || 0 }}万元</div>
            <div class="card-title">季度款总金额</div>
          </el-card>
        </el-col>
      </el-row>
    </div>
 
    <!-- 功能按钮区域 -->
    <div class="button-container">
      <el-button type="primary" size="small" @click="handleAdd">新增安置户记录</el-button>
      <el-button type="success" size="small" @click="handleDownloadTemplate">下载导入模板</el-button>
      <el-button type="primary" size="small" @click="handleImport">批量导入</el-button>
      <el-button type="danger" size="small" @click="handleExportSelected">问题数据导出</el-button>
      <el-button type="primary" size="small" @click="autoApprove">自动纠错</el-button>
    </div>
 
    <div v-if="activeTab === 'fullReport'">
      <!-- 表格区域 -->
      <el-table v-loading="loading" :data="tableData" border style="width: 100%" :row-class-name="tableRowClassName">
        <el-table-column type="index" key="table_A" label="序号" width="50" align="center" />
        <el-table-column prop="street" key="table_A" label="镇(街道)" min-width="120" align="center" />
        <el-table-column prop="projectName" key="table_A" label="拆迁项目名称" min-width="180" align="center" />
        <el-table-column prop="community" key="table_A" label="所在村(社区)" min-width="120" align="center" />
        <el-table-column prop="householdHead" key="table_A" label="户主姓名" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.householdHead }} <el-tooltip v-if="scope.row.householdHeadWarn == 1" class="item"
                effect="dark" content="用户信息未通过安置申请" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column prop="idCard" label="身份证号" key="table_A" min-width="180" align="center">
          <template slot-scope="scope">
            {{ scope.row.idCard || '-' }} <el-tooltip v-if="scope.row.idCardWarn == 1" class="item" effect="dark"
              content="身份信息不存在于待安置人员库" placement="top">
              <el-image style="width: 12px; height: 12px;margin-left:5px"
                :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column prop="resettledNum" label="应安置人数(人)" key="table_A" min-width="140" align="center" />
        <el-table-column label="所有家庭人员应安置面积(㎡)" prop="resettledArea" key="table_A" min-width="160" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.resettledArea }} <el-tooltip v-if="scope.row.waitFamilyAreaWarn == 1" class="item"
                effect="dark" content="应补偿面积数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column label="补偿单位标准(万元)" min-width="160" key="table_A" align="center">
          <el-table-column prop="priceNewAmount" label="新建商品住房、商业用房、停车位" min-width="160" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.priceNewAmount }} <el-tooltip v-if="scope.row.priceAmountWarn == 1" class="item"
                  effect="dark" content="补充标准数据异常" placement="top">
                  <el-image style="width: 12px; height: 12px;margin-left:5px"
                    :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
                </el-tooltip></span>
            </template>
          </el-table-column>
          <el-table-column prop="priceOldAmount" label="二手住房" min-width="150" key="table_A" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.priceOldAmount }} <el-tooltip v-if="scope.row.twoPriceWarn == 1" class="item"
                  effect="dark" content="检测到多个购房情况请人工核对" placement="top">
                  <el-image style="width: 12px; height: 12px;margin-left:5px"
                    :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
                </el-tooltip></span>
            </template>
          </el-table-column>
        </el-table-column>
        <el-table-column prop="compensationAmount" label="补偿资金总额(万元)" key="table_A" min-width="160" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.compensationAmount }} <el-tooltip v-if="scope.row.compensationSumWarn == 1" class="item"
                effect="dark" content="补偿总金额数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column prop="downPaymentAmount" label="25%首付款(㎡)" key="table_A" min-width="150" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.downPaymentAmount }}</span>
            <el-tooltip v-if="scope.row.downPaymentAmountWarn == 1" placement="top">
              <div slot="content">
                {{ "首付款金额异常" }}
              </div>
              <el-image style="width: 12px; height: 12px;margin-left:5px"
                :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column prop="quarterPayAmount" label="每季度需支付款项(万元)" key="table_A" min-width="180" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.quarterPayAmount }} <el-tooltip v-if="scope.row.quarterPayAmountWarn == 1" class="item"
                effect="dark" content="季度款金额数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column prop="subsidyAmount" label="过渡补贴(万元)" min-width="180" key="table_A" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.subsidyAmount }} <el-tooltip v-if="scope.row.subsidyAmountWarn == 1" class="item"
                effect="dark" content="过渡补贴金额数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column label="操作" prop="operation" fixed="right" width="180" key="table_A" align="center">
          <template slot-scope="scope" v-if="activeTab == 'fullReport'">
            <el-button type="text" size="small" @click="handleView(scope.row)">详情</el-button>
            <el-button type="text" size="small" @click="handleEdit(scope.row)">编辑</el-button>
            <el-button type="text" size="small" @click="handleDelete(scope.row)">删除</el-button>
            <el-button type="text" size="small" @click="handleCheckMoney(scope.row)">已核对</el-button>
          </template>
        </el-table-column>
      </el-table>
 
      <!-- 分页区域 -->
      <div class="pagination-container">
        <el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
          :current-page="queryParams.pageNum" :page-sizes="[10, 20, 30, 40]" :page-size="queryParams.pageSize"
          layout="total, sizes, prev, pager, next, jumper" :total="total">
        </el-pagination>
      </div>
    </div>
    <div v-else>
      <!-- 购房信息表格 -->
      <el-table v-loading="loading" :data="tableData1" border style="width: 100%" :row-class-name="tableRowClassName1">
        <el-table-column type="index" key="table_B" label="序号" width="50" align="center" />
        <el-table-column prop="street" key="table_B" label="镇(街道)" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.street }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="projectName" key="table_B" label="拆迁项目名称" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.projectName }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="community" key="table_B" label="所在村(社区)" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.community }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="demolitionTime" key="table_B" label="拆迁时间" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.demolitionTime }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="householdHead" key="table_B" label="户主姓名" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.householdHead }} <el-tooltip v-if="scope.row.householdHeadWarn == 1" class="item"
                effect="dark" content="户主信息不存在于待安置人员库" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column prop="idCard" label="身份证号" key="table_B" min-width="180" align="center">
          <template slot-scope="scope">
            {{ scope.row.idCard || '-' }} <el-tooltip v-if="scope.row.idCardWarn == 1" class="item" effect="dark"
              content="身份信息不存在于待安置人员库" placement="top">
              <el-image style="width: 12px; height: 12px;margin-left:5px"
                :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column prop="mobile" key="table_B" label="联系电话" min-width="100" align="center">
          <template slot-scope="scope">
            {{ scope.row.mobile || '-' }}
          </template>
        </el-table-column>
 
        <el-table-column label="本次安置人数(人)" key="table_B" min-width="100" align="center">
          <el-table-column prop="currentCollectiveNum" key="table_B" label="集体经济组织成员" min-width="100" align="center">
            <template slot-scope="scope">
              {{ scope.row.currentCollectiveNum || '-' }}
            </template>
          </el-table-column>
          <el-table-column prop="currentNoCollectiveNum" key="table_B" label="非集体经济组织成员" min-width="100" align="center">
            <template slot-scope="scope">
              {{ scope.row.currentNoCollectiveNum || '-' }}
            </template>
          </el-table-column>
          <el-table-column prop="currentCount" label="合计" key="table_B" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.currentCount }}</span>
            </template>
          </el-table-column>
        </el-table-column>
        <el-table-column prop="waitFamilyNames" key="table_B" label="待安置家庭成员姓名" min-width="100" align="center">
          <template slot-scope="scope">
            {{ scope.row.waitFamilyNames || '-' }} <el-tooltip v-if="scope.row.waitFamilyNamesWarn == 1" class="item"
              effect="dark" content="身份信息存在重复数据" placement="top">
              <el-image style="width: 12px; height: 12px;margin-left:5px"
                :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
            </el-tooltip>
            <el-tooltip v-if="scope.row.waitFamilyNamesNoWarn == 1" class="item" effect="dark" content="家庭成员不在安置库"
              placement="top">
              <el-image style="width: 12px; height: 12px;margin-left:5px"
                :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column prop="orgArea" key="table_B" label="集体成员面积" align="center" width="150">
          <template slot-scope="scope">
            {{ scope.row.orgArea }}
          </template>
        </el-table-column>
        <el-table-column prop="noOrgArea" key="table_B" label="非集体成员面积" align="center" width="150">
          <template slot-scope="scope">
            {{ scope.row.noOrgArea }}
          </template>
        </el-table-column>
        <el-table-column prop="waitFamilyArea" key="table_B" label="待安置人员应安置面积合计(㎡)" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.waitFamilyArea }} <el-tooltip v-if="scope.row.waitFamilyAreaWarn == 1" class="item"
                effect="dark" content="应补偿面积数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column label="补偿金额(万元)" key="table_B" min-width="100" align="center">
          <el-table-column prop="compensationNewAmount" key="table_B" label="新建商品住房、商业用房、停车位" min-width="100"
            align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.compensationNewAmount }} <el-tooltip v-if="scope.row.compensationAmountWarn == 1"
                  class="item" effect="dark" content="检测到多个购房情况请人工核对" placement="top">
                  <el-image style="width: 12px; height: 12px;margin-left:5px"
                    :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
                </el-tooltip></span>
            </template>
          </el-table-column>
          <el-table-column prop="compensationOldAmount" key="table_B" label="二手住房" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.compensationOldAmount }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="compensationSum" key="table_B" label="合计" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.compensationSum }} <el-tooltip v-if="scope.row.compensationSumWarn == 1" class="item"
                  effect="dark" content="补偿总金额数据异常" placement="top">
                  <el-image style="width: 12px; height: 12px;margin-left:5px"
                    :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
                </el-tooltip></span>
            </template>
          </el-table-column>
        </el-table-column>
        <el-table-column prop="downPaymentAmount" key="table_B" label="25%首付款(万元)" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.downPaymentAmount }}</span>
            <el-tooltip v-if="scope.row.downPaymentAmountWarn == 1" placement="top">
              <div slot="content">
                {{ "首付款金额异常" }}
              </div>
              <el-image style="width: 12px; height: 12px;margin-left:5px"
                :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column prop="quarterPayAmount" key="table_B" label="每季度需支付款项(万元)" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.quarterPayAmount }} <el-tooltip v-if="scope.row.quarterPayAmountWarn == 1" class="item"
                effect="dark" content="季度款金额数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column prop="subsidyAmount" key="table_B" label="过渡补贴(万元)" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.subsidyAmount }} <el-tooltip v-if="scope.row.subsidyAmount == 1" class="item"
                effect="dark" content="过渡补贴金额数据异常" placement="top">
                <el-image style="width: 12px; height: 12px;margin-left:5px"
                  :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
              </el-tooltip></span>
          </template>
        </el-table-column>
        <el-table-column prop="remark" key="table_B" label="备注" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.remark }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="certificateTime" key="table_B" label="凭证发放时间" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.certificateTime }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="buyTime" label="购房时间" key="table_B" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.buyTime }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="dealAmount" label="成交金额(万元)" key="table_B" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.dealAmount }}</span>
          </template>
        </el-table-column>
 
 
        <el-table-column label="新建商品住房" min-width="100" key="table_B" align="center">
          <el-table-column prop="newHousingName" label="楼盘名称" key="table_B" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.newHousingName }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="newHousingArea" key="table_B" label="面积(㎡)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.newHousingArea }} <el-tooltip v-if="scope.row.areaWarn == 1" class="item" effect="dark"
                  content="面积数据异常" placement="top">
                  <el-image style="width: 12px; height: 12px;margin-left:5px"
                    :src="require('../../assets/logo/warning.png')" fit="fit"></el-image>
                </el-tooltip></span>
            </template>
          </el-table-column>
          <el-table-column prop="newHousingNum" key="table_B" label="套数(套)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.newHousingNum }}</span>
            </template>
          </el-table-column>
        </el-table-column>
 
 
        <el-table-column label="二手住房" key="table_B" min-width="100" align="center">
          <el-table-column prop="oldHousingName" label="小区名称" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.oldHousingName }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="oldHousingArea" key="table_B" label="面积(㎡)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.oldHousingArea }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="oldHousingNum" key="table_B" label="套数(套)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.oldHousingNum }}</span>
            </template>
          </el-table-column>
        </el-table-column>
 
 
 
        <el-table-column prop="householdHead" key="table_B" label="新建商业用房" min-width="100" align="center">
          <el-table-column prop="buildHousingName" key="table_B" label="楼盘名称" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.buildHousingName }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="buildHousingArea" key="table_B" label="面积(㎡)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.buildHousingArea }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="buildHousingNum" key="table_B" label="套数(套)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.buildHousingNum }}</span>
            </template>
          </el-table-column>
        </el-table-column>
 
 
 
        <el-table-column label="新建停车位" key="table_B" min-width="100" align="center">
          <el-table-column prop="newStopName" key="table_B" label="楼盘名称" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.newStopName }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="newStopArea" key="table_B" label="金额(万元)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.newStopArea }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="newStopNum" key="table_B" label="个数(个)" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.newStopNum }}</span>
            </template>
          </el-table-column>
        </el-table-column>
 
 
        <el-table-column prop="signTime" key="table_B" label="自主购房协议签订时间" min-width="100" align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.signTime }}</span>
          </template>
        </el-table-column>
        <el-table-column prop="compensationPayTime" key="table_B" label="25%补偿款及过渡补贴支付时间" min-width="100"
          align="center">
          <template slot-scope="scope">
            <span>{{ scope.row.compensationPayTime }}</span>
          </template>
        </el-table-column>
        <el-table-column label="剩余款项支付时间" key="table_B" min-width="100" align="center">
          <el-table-column prop="remainingTime1" key="table_B" label="第一年" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.remainingTime1 }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="remainingTime2" key="table_B" label="第二年" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.remainingTime2 }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="remainingTime3" key="table_B" label="第三年" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.remainingTime3 }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="remainingTime4" key="table_B" label="第四年" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.remainingTime4 }}</span>
            </template>
          </el-table-column>
          <el-table-column prop="remainingTime5" key="table_B" label="第五年" min-width="100" align="center">
            <template slot-scope="scope">
              <span>{{ scope.row.remainingTime5 }}</span>
            </template>
          </el-table-column>
        </el-table-column>
        <el-table-column label="操作" prop="operation" key="table_B" fixed="right" width="180" align="center">
          <template slot-scope="scope">
            <el-button type="text" size="small" @click="handleView(scope.row)">详情</el-button>
            <el-button type="text" size="small" @click="handleEdit(scope.row)">编辑</el-button>
            <el-button type="text" size="small" @click="handleDelete(scope.row)">删除</el-button>
            <el-button type="text" size="small" @click="handleCheckHousehold(scope.row)">已核对</el-button>
          </template>
        </el-table-column>
      </el-table>
 
      <div class="pagination-container">
        <el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
          :current-page="queryParams.pageNum" :page-sizes="[10, 20, 30, 40]" :page-size="queryParams.pageSize"
          layout="total, sizes, prev, pager, next, jumper" :total="total">
        </el-pagination>
      </div>
    </div>
    <!-- :title="activeTab == 'fullReport' ? '导入资金表' : '导入购房信息表'" -->
    <export-money-applay @close="dialogVisible = false" :visible.sync="dialogVisible"
      :batchNumber="detailData.batchNumber" @importPrice="importPrice" :type="activeTab == 'fullReport' ? 1 : 2" />
  </div>
</template>
<script>
import {
  getPlacementBatchDetail,
  deletePlacementBatchMoney,
  deletePlacementBatchHouse,
  importPlacementBatch,
  checkPlacementBatchMoney,
  autoCorrectPlacementBatch,
  checkPlacementBatchHouse
} from '@/api/placement-details'
import ExportMoneyApplay from './components/exportMoneyApplay.vue'
 
import { downLoad, exportExcell } from '@/utils'
import { autoApprove } from '../../api/application-batch'
export default {
  name: 'PlacementPerson',
  components: {
    ExportMoneyApplay
  },
  data() {
    return {
      // 遮罩层
      loading: false,
      // 选中数组
      selectedRows: [],
      // 弹窗
      dialogVisible: false,
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 总条数
      total: 0,
      // 表格数据
      tableData: [],
      // 表格数据
      tableData1: [],
      // 当前激活的tab
      activeTab: 'fullReport',
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 10,
 
        street: undefined,
        community: undefined,
        projectName: undefined,
        householdHead: undefined
      },
      detailData: {},
      columns: []
    }
  },
 
  created() {
    this.getList()
  },
  methods: {
    /** 自动纠错 */
    autoApprove() {
      this.$confirm('是否确认自动纠错', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        autoCorrectPlacementBatch({ id: this.detailData.id }).then((res) => {
          this.getList();
        })
      })
    },
 
    /** 资金核对数据 */
    handleCheckMoney(row) {
      this.$confirm('是否确认已核对数据', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        checkPlacementBatchMoney({ id: row.id }).then((res) => {
          this.getList();
        })
      })
    },
 
    /** 购房信息核对数据 */
    handleCheckHousehold(row) {
      this.$confirm('是否确认核对数据', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        checkPlacementBatchHouse({ id: row.id }).then((res) => {
          this.getList();
        })
      })
    },
 
 
    /** 查询列表 */
    getList() {
      this.loading = true
      // TODO: 调用接口获取数据
      getPlacementBatchDetail({ ...this.queryParams, placementBatchId: this.$route.query.id, type: this.activeTab == 'fullReport' ? 1 : 2 }).then(res => {
        if (res.code == 200) {
          // this.tableData = this.activeTab == 'fullReport' ? res.data.assetList : res.data.householdList
          if (this.activeTab == 'fullReport') {
            this.tableData = res.data.assetList
          } else {
            this.tableData1 = res.data.householdList
          }
          this.detailData = res.data.placementBatch
          this.total = res.data.total
          this.loading = false
        }
      })
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1
      this.getList()
    },
    tableRowClassName({ row, rowIndex }) {
      if (row.compensationSumWarn == 1 || row.householdHeadWarn == 1 || row.idCardWarn == 1 || row.waitFamilyNamesNoWarn == 1 || row.priceAmountWarn == 1 || row.quarterPayAmountWarn == 1 || row.subsidyAmountWarn == 1 || row.twoPriceWarn == 1 || row.waitFamilyAreaWarn == 1 || row.downPaymentAmountWarn == 1) {
        return 'warning-row'
      }
      return ''
    },
    tableRowClassName1({ row, rowIndex }) {
      if (row.areaWarn == 1 || row.compensationAmountWarn == 1 || row.compensationSumWarn == 1 || row.householdHeadWarn == 1 || row.waitFamilyNamesNoWarn == 1 || row.idCardWarn == 1 || row.waitFamilyAreaWarn == 1 || row.waitFamilyNamesWarn == 1 || row.subsidyAmountWarn == 1 || row.quarterPayAmountWarn == 1 || row.downPaymentAmountWarn == 1) {
        return 'warning-row'
      }
      return ''
    },
    importPrice(form) {
      let formData = new FormData()
      if (this.activeTab == 'fullReport') {
        formData.append('assetFile', form.assetFile)
      } else {
        formData.append('householdFile', form.householdFile)
      }
      formData.append('batchNumber', form.batchNumber)
      formData.append('id', this.$route.query.id)
      importPlacementBatch(formData).then(res => {
        if (res.code == 200) {
          this.$message.success('导入成功')
          this.dialogVisible = false
          this.getList()
        }
      })
    },
 
    /** 分页 */
    handleSizeChange(size) {
      this.queryParams.pageSize = size
      this.getList()
    },
    /** 分页 */
    handleCurrentChange(page) {
      this.queryParams.pageNum = page
      this.getList()
    },
    /** 重置按钮操作 */
    handleReset() {
      this.queryParams = {
        pageNum: 1,
        pageSize: 10,
        street: undefined,
        community: undefined,
        projectName: undefined,
        householdHead: undefined
      }
      this.getList()
    },
    /** Tab切换操作 */
    handleTabClick(tab) {
      this.activeTab = tab.name
      this.queryParams = {
        pageNum: 1,
        pageSize: 10,
        street: undefined,
        community: undefined,
        projectName: undefined,
        householdHead: undefined
      }
      this.$forceUpdate()
      this.getList()
    },
    /** 选择框变更 */
    handleSelectionChange(selection) {
      this.selectedRows = selection
      this.single = selection.length !== 1
      this.multiple = !selection.length
    },
    /** 新增按钮操作 */
    handleAdd() {
      // TODO: 实现新增逻辑
      if (this.activeTab == 'fullReport') {
        this.$router.push('/placement/batch/addResettle?id=' + this.$route.query.id)
      } else {
        this.$router.push('/placement/batch/applayPerson?id=' + this.$route.query.id)
      }
    },
    /** 导出操作 */
    handleExport() {
      // TODO: 实现导出逻辑
    },
    /** 下载模板 */
    handleDownloadTemplate() {
      // TODO: 实现下载模板逻辑
      downLoad(`/placement-batch/download-template/${this.activeTab == 'fullReport' ? 3 : 4}`, `${this.activeTab == 'fullReport' ? '资金导入模版' : '购房信息表导入模版'}.xlsx`)
    },
    /** 导入操作 */
    handleImport() {
      // TODO: 实现导入逻辑
      this.dialogVisible = true
    },
    /** 导出选中记录 */
    handleExportSelected() {
      // TODO: 实现导出选中记录逻辑
      exportExcell(`${this.activeTab == 'fullReport' ? '资金问题数据' : '购房信息问题数据'}.xlsx`, {
        ...this.queryParams,
        placementBatchId: this.$route.query.id,
        type: this.activeTab == 'fullReport' ? 1 : 2
      }, `/placement-batch/problem-export`)
    },
    /** 查看详情按钮操作 */
    handleView(row) {
      // TODO: 实现查看详情逻辑
      if (this.activeTab == 'fullReport') {
        this.$router.push('/placement/batch/resettleDetail?id=' + this.$route.query.id + '&type=detail' + '&moneyId=' + row.id)
      } else {
        this.$router.push('/placement/batch/applayPersonDetail?id=' + this.$route.query.id + '&type=detail' + '&houseId=' + row.id)
      }
    },
    /** 编辑按钮操作 */
    handleEdit(row) {
      // TODO: 实现编辑逻辑
      if (this.activeTab == 'fullReport') {
        this.$router.push('/placement/batch/editResettle?id=' + this.$route.query.id + '&type=edit' + '&moneyId=' + row.id)
      } else {
        this.$router.push('/placement/batch/editApplayPerson?id=' + this.$route.query.id + '&type=edit' + '&houseId=' + row.id)
      }
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      // TODO: 实现删除逻辑
      this.$confirm('确定删除该条资金记录吗?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        if (this.activeTab == 'fullReport') {
          deletePlacementBatchMoney({ id: row.id }).then(res => {
            if (res.code == 200) {
              this.$message.success('删除成功')
              this.getList()
            }
          })
        } else {
          deletePlacementBatchHouse({ id: row.id }).then(res => {
            if (res.code == 200) {
              this.$message.success('删除成功')
              this.getList()
            }
          })
        }
      })
 
 
    },
    /** 获取购房信息列表 */
    getHouseList() {
      this.loading = true
      // TODO: 调用接口获取购房信息数据
      setTimeout(() => {
        this.loading = false
      }, 1000)
    },
  }
}
</script>
 
<style scoped lang="scss">
::v-deep .warning-row {
  background: #DE868F !important;
}
 
.app-container {
  padding: 20px;
}
 
.filter-container {
  margin-bottom: 20px;
}
 
.tab-container {
  margin-bottom: 20px;
}
 
.statistics-container {
  margin-bottom: 20px;
}
 
.statistics-card {
  text-align: center;
  color: #666;
}
 
.card-amount {
  font-size: 24px;
  color: #409EFF;
  margin-bottom: 10px;
}
 
.card-title {
  font-size: 14px;
}
 
.button-container {
  margin-bottom: 20px;
}
 
.area-value {
  cursor: pointer;
  color: #409EFF;
  text-decoration: underline;
}
 
.el-table {
  margin-bottom: 20px;
}
</style>