...
|
...
|
@@ -36,6 +36,9 @@ Page({ |
36
|
36
|
lable: 0,
|
37
|
37
|
title: '',
|
38
|
38
|
isIdCard: true,
|
|
39
|
+ workAddress_haschanged: false,
|
|
40
|
+ loanAddress_haschanged: false,
|
|
41
|
+ rentAddress_haschanged: false,
|
39
|
42
|
extrainfo_arr: ["请上传子女出生证明、学籍信息凭证、学费凭证、本人结婚证和分摊协议", "请上传学历学籍凭证", "请上传出生证明或关系证明、独生子女证、分摊协议、其他法定赡养人赡养证明", "请上传诊断书和医疗费用收据", "请上传首套房证明、还款证明、不动产登记证、结婚证和夫妻约定抵扣协议"],
|
40
|
43
|
cur_index: 'support_duty',
|
41
|
44
|
lovercardtypeData: {
|
...
|
...
|
@@ -318,6 +321,7 @@ Page({ |
318
|
321
|
address_value: ['', ''],
|
319
|
322
|
selected: '',
|
320
|
323
|
placeholder: '请选择城市',
|
|
324
|
+ requestdata: {},
|
321
|
325
|
onChange: 'onPickerSelect'
|
322
|
326
|
},
|
323
|
327
|
houseLocateInfo: {
|
...
|
...
|
@@ -330,6 +334,7 @@ Page({ |
330
|
334
|
address_code: ['', '', ''],
|
331
|
335
|
address_value: ['', '', ''],
|
332
|
336
|
selected: '',
|
|
337
|
+ requestdata: {},
|
333
|
338
|
placeholder: '请选择地址',
|
334
|
339
|
onChange: 'onPickerSelect'
|
335
|
340
|
},
|
...
|
...
|
@@ -343,6 +348,7 @@ Page({ |
343
|
348
|
address_code: ['', '', ''],
|
344
|
349
|
address_value: ['', '', ''],
|
345
|
350
|
selected: '',
|
|
351
|
+ requestdata: {},
|
346
|
352
|
placeholder: '请选择地址',
|
347
|
353
|
onChange: 'onPickerSelect'
|
348
|
354
|
},
|
...
|
...
|
@@ -577,13 +583,13 @@ Page({ |
577
|
583
|
case 'continuing_education':
|
578
|
584
|
var setData = {}
|
579
|
585
|
if (data.education_type && data.education_type.length) {
|
580
|
|
- if ('title' == data.education_type){
|
|
586
|
+ if ('title' == data.education_type) {
|
581
|
587
|
var edutypeData = this.data.edutypeData
|
582
|
588
|
edutypeData.selected = "学历继续教育"
|
583
|
589
|
setData.edutypeData = edutypeData
|
584
|
|
- }else{
|
|
590
|
+ } else {
|
585
|
591
|
var edutypeData = this.data.edutypeData
|
586
|
|
- edutypeData.selected = data.education_type =='major'?"专业技术人员职业资格":"技能人员职业资格"
|
|
592
|
+ edutypeData.selected = data.education_type == 'major' ? "专业技术人员职业资格" : "技能人员职业资格"
|
587
|
593
|
setData.edutypeData = edutypeData
|
588
|
594
|
}
|
589
|
595
|
}
|
...
|
...
|
@@ -618,7 +624,7 @@ Page({ |
618
|
624
|
}
|
619
|
625
|
if (data.certification_autority && data.certification_autority.length) {
|
620
|
626
|
setData.certification_autority = data.certification_autority
|
621
|
|
- }
|
|
627
|
+ }
|
622
|
628
|
this.setData(setData)
|
623
|
629
|
break;
|
624
|
630
|
case 'support_duty':
|
...
|
...
|
@@ -687,17 +693,12 @@ Page({ |
687
|
693
|
loverbirthDate.selected = format.formatTime_date(data.spouse_birthday)
|
688
|
694
|
loverbirthDate.datelong = data.spouse_birthday
|
689
|
695
|
setData.loverbirthDate = loverbirthDate
|
690
|
|
- }
|
|
696
|
+ }
|
691
|
697
|
if (data.loan_type && data.loan_type.length) {
|
692
|
698
|
var loantypeData = this.data.loantypeData
|
693
|
699
|
loantypeData.selected = data.loan_type
|
694
|
700
|
setData.loantypeData = loantypeData
|
695
|
701
|
}
|
696
|
|
- if (data.house_address && data.house_address.length) {
|
697
|
|
- var houseLocateInfo = this.data.houseLocateInfo
|
698
|
|
- houseLocateInfo.selected = data.house_address
|
699
|
|
- setData.houseLocateInfo = houseLocateInfo
|
700
|
|
- }
|
701
|
702
|
if (data.house_detail_address && data.house_detail_address.length) {
|
702
|
703
|
setData.house_detail_address = data.house_detail_address
|
703
|
704
|
}
|
...
|
...
|
@@ -737,11 +738,25 @@ Page({ |
737
|
738
|
leaseendDate.datelong = data.rent_end
|
738
|
739
|
setData.leaseendDate = leaseendDate
|
739
|
740
|
}
|
740
|
|
- if (data.work_city && data.work_city.length) {
|
|
741
|
+ if (data.work_city && data.work_city.province) {
|
741
|
742
|
var workingcityInfo = this.data.workingcityInfo
|
742
|
|
- workingcityInfo.selected = data.work_city
|
|
743
|
+ workingcityInfo.requestdata = data.work_city
|
|
744
|
+ workingcityInfo.selected = data.work_city.province + data.work_city.city
|
743
|
745
|
setData.workingcityInfo = workingcityInfo
|
744
|
746
|
}
|
|
747
|
+ if (house_type == 'house_fund_loan' && data.house_address && data.house_address.province) {
|
|
748
|
+ var houseLocateInfo = this.data.houseLocateInfo
|
|
749
|
+ houseLocateInfo.requestdata = data.house_address
|
|
750
|
+ houseLocateInfo.selected = data.work_city.province + data.work_city.city + data.work_city.district
|
|
751
|
+ setData.houseLocateInfo = houseLocateInfo
|
|
752
|
+ }
|
|
753
|
+ if (house_type == 'house_fund_rent' && data.house_address && data.house_address.province) {
|
|
754
|
+ var rentLocateInfo = this.data.rentLocateInfo
|
|
755
|
+ rentLocateInfo.requestdata = data.house_address
|
|
756
|
+ rentLocateInfo.selected = data.work_city.province + data.work_city.city + data.work_city.district
|
|
757
|
+ setData.rentLocateInfo = rentLocateInfo
|
|
758
|
+ }
|
|
759
|
+
|
745
|
760
|
this.setData(setData)
|
746
|
761
|
break;
|
747
|
762
|
}
|
...
|
...
|
@@ -1043,10 +1058,10 @@ Page({ |
1043
|
1058
|
} else {
|
1044
|
1059
|
newdata.percentage = parseFloat(formdata.percentage)
|
1045
|
1060
|
}
|
1046
|
|
- newdata.older_birthday = this.data.olderbirthDate.datelong
|
1047
|
|
- newdata.older_relative = this.data.older_relativeData.selected
|
|
1061
|
+ newdata.birthday = this.data.olderbirthDate.datelong
|
|
1062
|
+ newdata.relationship = this.data.older_relativeData.selected
|
1048
|
1063
|
newdata.support_type = this.data.supporttypeData.selected
|
1049
|
|
- newdata.older_cardtype = this.data.oldercardtypeData.selected
|
|
1064
|
+ newdata.id_card_type = this.data.oldercardtypeData.selected
|
1050
|
1065
|
break;
|
1051
|
1066
|
case 'medical_fund':
|
1052
|
1067
|
subUrl = 'persontax/v1/medical-funds'
|
...
|
...
|
@@ -1091,7 +1106,7 @@ Page({ |
1091
|
1106
|
} else if (this.data.identifytypeData.selected.length < 1) {
|
1092
|
1107
|
this.showToast('请选择证书类型')
|
1093
|
1108
|
return
|
1094
|
|
- } else if (!formdata.certification_no || formdata.certification_no.length < 1) {
|
|
1109
|
+ } else if (!formdata.certification_no || formdata.certification_no.length < 1) {
|
1095
|
1110
|
this.showToast('请填写证书号码')
|
1096
|
1111
|
return
|
1097
|
1112
|
} else if (this.data.beforemarryData.selected.length < 1) {
|
...
|
...
|
@@ -1116,7 +1131,6 @@ Page({ |
1116
|
1131
|
this.showToast('请选择贷款期限')
|
1117
|
1132
|
return
|
1118
|
1133
|
}
|
1119
|
|
- newdata.house_location = this.data.houseLocateInfo.address_value[0] + this.data.houseLocateInfo.address_value[1] + this.data.houseLocateInfo.address_value[2]
|
1120
|
1134
|
newdata.loan_before_marry = this.data.beforemarryData.selected == "是" ? 'y' : 'n'
|
1121
|
1135
|
newdata.loan_by_self = this.data.isselfData.selected == "是" ? 'y' : 'n'
|
1122
|
1136
|
newdata.identify_type = this.data.identifytypeData.selected
|
...
|
...
|
@@ -1125,6 +1139,9 @@ Page({ |
1125
|
1139
|
newdata.loan_bank = this.data.bankInfo.selected
|
1126
|
1140
|
newdata.payback_date = this.data.firstpaybackDate.selected
|
1127
|
1141
|
newdata.loan_datelong = this.data.loandatelongData.selected
|
|
1142
|
+ var request_loan_address = that.getLoanAddressRequest()
|
|
1143
|
+ newdata.house_location = request_loan_address
|
|
1144
|
+
|
1128
|
1145
|
} else if (this.data.house_type == "house_fund_rent") {
|
1129
|
1146
|
if (this.data.workingcityInfo.address_value.length < 1) {
|
1130
|
1147
|
this.showToast('请选择工作城市')
|
...
|
...
|
@@ -1138,35 +1155,42 @@ Page({ |
1138
|
1155
|
} else if (!formdata.lease_idno || formdata.lease_idno.length < 1) {
|
1139
|
1156
|
this.showToast('请填写纳税人识别号')
|
1140
|
1157
|
return
|
1141
|
|
- } else if (!formdata.identify_no || formdata.identify_no.length < 1) {
|
1142
|
|
- this.showToast('请填写出租方号码')
|
1143
|
|
- return
|
1144
|
|
- } else if (this.data.identifytypeData.selected.length < 1) {
|
|
1158
|
+ }
|
|
1159
|
+ // else if (!formdata.identify_no || formdata.identify_no.length < 1) {
|
|
1160
|
+ // this.showToast('请填写出租方号码')
|
|
1161
|
+ // return
|
|
1162
|
+ // }
|
|
1163
|
+ else if (this.data.identifytypeData.selected.length < 1) {
|
1145
|
1164
|
this.showToast('请选择证件类型')
|
1146
|
1165
|
return
|
1147
|
|
- } else if (this.data.rentLocateInfo.address_value.length < 1) {
|
1148
|
|
- this.showToast('请选择房屋地址')
|
1149
|
|
- return
|
1150
|
1166
|
} else if (!formdata.owner_id_cartd_no || formdata.owner_id_cartd_no.length < 1) {
|
1151
|
1167
|
this.showToast('请填写证件号码')
|
1152
|
1168
|
return
|
1153
|
|
- } else if (!formdata.rent_contract_no || formdata.rent_contract_no.length < 1) {
|
|
1169
|
+ } else if (this.data.rentLocateInfo.address_value.length < 1) {
|
|
1170
|
+ this.showToast('请选择房屋地址')
|
|
1171
|
+ return
|
|
1172
|
+ }
|
|
1173
|
+ else if (!formdata.rent_contract_no || formdata.rent_contract_no.length < 1) {
|
1154
|
1174
|
this.showToast('请填写租赁合同编号')
|
1155
|
1175
|
return
|
1156
|
|
- }else if (this.data.leasestartDate.selected.length < 1) {
|
|
1176
|
+ } else if (this.data.leasestartDate.selected.length < 1) {
|
1157
|
1177
|
this.showToast('请选择日期')
|
1158
|
1178
|
return
|
1159
|
1179
|
} else if (this.data.leaseendDate.selected.length < 1) {
|
1160
|
1180
|
this.showToast('请选择日期')
|
1161
|
1181
|
return
|
1162
|
1182
|
}
|
1163
|
|
- newdata.house_address = this.data.rentLocateInfo.address_value[0] + this.data.rentLocateInfo.address_value[1] + this.data.rentLocateInfo.address_value[2]
|
1164
|
|
- newdata.work_city = this.data.workingcityInfo.address_value[0] + this.data.workingcityInfo.address_value[1] + this.data.workingcityInfo.address_value[2]
|
1165
|
1183
|
newdata.lease_type = this.data.leasetypeData.selected
|
1166
|
1184
|
newdata.certification_type = this.data.identifytypeData.selected
|
1167
|
1185
|
newdata.rent_start = this.data.leasestartDate.selected
|
1168
|
1186
|
newdata.rent_end = this.data.leaseendDate.selected
|
1169
|
|
- console.log('houseLocateInfo', this.data.houseLocateInfo)
|
|
1187
|
+
|
|
1188
|
+ var request_working_address = that.getWorkingAddressRequest()
|
|
1189
|
+ newdata.work_city = request_working_address
|
|
1190
|
+ var request_rent_address = that.getRentAddressRequest()
|
|
1191
|
+ newdata.house_address = request_rent_address
|
|
1192
|
+ console.log('request_working_address', this.data.request_working_address)
|
|
1193
|
+
|
1170
|
1194
|
}
|
1171
|
1195
|
if (formdata.spouse_name || formdata.spouse_id_card_no || this.data.loverbirthDate.selected) {
|
1172
|
1196
|
if (!formdata.spouse_name || formdata.spouse_name.length < 1) {
|
...
|
...
|
@@ -1488,7 +1512,10 @@ Page({ |
1488
|
1512
|
house_address.selected = e.detail.value[0] + e.detail.value[1] + e.detail.value[2]
|
1489
|
1513
|
|
1490
|
1514
|
}
|
|
1515
|
+ house_address.address_value = e.detail.value
|
|
1516
|
+ house_address.address_code = e.detail.code
|
1491
|
1517
|
this.setData({
|
|
1518
|
+ loanAddress_haschanged: true,
|
1492
|
1519
|
houseLocateInfo: house_address
|
1493
|
1520
|
})
|
1494
|
1521
|
break;
|
...
|
...
|
@@ -1499,10 +1526,12 @@ Page({ |
1499
|
1526
|
if (e.detail.value[0] == e.detail.value[1]) {
|
1500
|
1527
|
work_address.selected = e.detail.value[1] + e.detail.value[2]
|
1501
|
1528
|
} else {
|
1502
|
|
- work_address.selected = e.detail.value[0] + e.detail.value[1] + e.detail.value[2]
|
1503
|
|
-
|
|
1529
|
+ work_address.selected = e.detail.value[0] + e.detail.value[1]
|
1504
|
1530
|
}
|
|
1531
|
+ work_address.address_value = e.detail.value
|
|
1532
|
+ work_address.address_code = e.detail.code
|
1505
|
1533
|
this.setData({
|
|
1534
|
+ workAddress_haschanged: true,
|
1506
|
1535
|
workingcityInfo: work_address
|
1507
|
1536
|
})
|
1508
|
1537
|
break;
|
...
|
...
|
@@ -1514,9 +1543,11 @@ Page({ |
1514
|
1543
|
rent_address.selected = e.detail.value[1] + e.detail.value[2]
|
1515
|
1544
|
} else {
|
1516
|
1545
|
rent_address.selected = e.detail.value[0] + e.detail.value[1] + e.detail.value[2]
|
1517
|
|
-
|
1518
|
1546
|
}
|
|
1547
|
+ rent_address.address_value = e.detail.value
|
|
1548
|
+ rent_address.address_code = e.detail.code
|
1519
|
1549
|
this.setData({
|
|
1550
|
+ rentAddress_haschanged: true,
|
1520
|
1551
|
rentLocateInfo: rent_address
|
1521
|
1552
|
})
|
1522
|
1553
|
break;
|
...
|
...
|
@@ -1601,6 +1632,52 @@ Page({ |
1601
|
1632
|
// })
|
1602
|
1633
|
// },
|
1603
|
1634
|
|
|
1635
|
+ getWorkingAddressRequest: function() {
|
|
1636
|
+ var that = this
|
|
1637
|
+ if (that.data.workAddress_haschanged) {
|
|
1638
|
+ return {
|
|
1639
|
+ "province_code": that.data.workingcityInfo.address_code[0],
|
|
1640
|
+ "province": that.data.workingcityInfo.address_value[0],
|
|
1641
|
+ "city_code": that.data.workingcityInfo.address_code[1],
|
|
1642
|
+ "city": that.data.workingcityInfo.address_value[1]
|
|
1643
|
+ }
|
|
1644
|
+ } else {
|
|
1645
|
+ return that.data.workingcityInfo.requestdata
|
|
1646
|
+ }
|
|
1647
|
+ },
|
|
1648
|
+
|
|
1649
|
+ getRentAddressRequest: function() {
|
|
1650
|
+ var that = this
|
|
1651
|
+ if (that.data.rentAddress_haschanged) {
|
|
1652
|
+ return {
|
|
1653
|
+ "province_code": that.data.rentLocateInfo.address_code[0],
|
|
1654
|
+ "province": that.data.rentLocateInfo.address_value[0],
|
|
1655
|
+ "city_code": that.data.rentLocateInfo.address_code[1],
|
|
1656
|
+ "city": that.data.rentLocateInfo.address_value[1],
|
|
1657
|
+ "district_code": that.data.rentLocateInfo.address_code[2],
|
|
1658
|
+ "district": that.data.rentLocateInfo.address_value[2]
|
|
1659
|
+ }
|
|
1660
|
+ } else {
|
|
1661
|
+ return that.data.rentLocateInfo.requestdata
|
|
1662
|
+ }
|
|
1663
|
+ },
|
|
1664
|
+
|
|
1665
|
+ getLoanAddressRequest: function() {
|
|
1666
|
+ var that = this
|
|
1667
|
+ if (that.data.loanAddress_haschanged) {
|
|
1668
|
+ return {
|
|
1669
|
+ "province_code": that.data.houseLocateInfo.address_code[0],
|
|
1670
|
+ "province": that.data.houseLocateInfo.address_value[0],
|
|
1671
|
+ "city_code": that.data.houseLocateInfo.address_code[1],
|
|
1672
|
+ "city": that.data.houseLocateInfo.address_value[1],
|
|
1673
|
+ "district_code": that.data.houseLocateInfo.address_code[2],
|
|
1674
|
+ "district": that.data.houseLocateInfo.address_value[2]
|
|
1675
|
+ }
|
|
1676
|
+ } else {
|
|
1677
|
+ return that.data.houseLocateInfo.requestdata
|
|
1678
|
+ }
|
|
1679
|
+ },
|
|
1680
|
+
|
1604
|
1681
|
showToast: function(data) {
|
1605
|
1682
|
if (data && data.length > 0) {
|
1606
|
1683
|
wx.showToast({
|
...
|
...
|
|