提交 4884b294cb12c1f306c0982ef0577f2da7848147

作者 pangy
1 个父辈 a57a63b2

居民身份证。改成汉字

@@ -1374,13 +1374,13 @@ Page({ @@ -1374,13 +1374,13 @@ Page({
1374 this.showToast('请选择配偶出生日期') 1374 this.showToast('请选择配偶出生日期')
1375 return 1375 return
1376 } 1376 }
1377 - newdata.spouse_id_card_type = '1' //this.data.lovercardtypeData.selected 1377 + newdata.spouse_id_card_type = '居民身份证' //this.data.lovercardtypeData.selected
1378 newdata.spouse_birthday = this.data.loverbirthDate.datelong 1378 newdata.spouse_birthday = this.data.loverbirthDate.datelong
1379 } 1379 }
1380 newdata.has_spouse = this.data.hasLover?'y':'n' 1380 newdata.has_spouse = this.data.hasLover?'y':'n'
1381 newdata.relationship = this.data.taxperson_relativeData.selected 1381 newdata.relationship = this.data.taxperson_relativeData.selected
1382 newdata.percent = this.data.childrenpercentData.selected.replace("%","") 1382 newdata.percent = this.data.childrenpercentData.selected.replace("%","")
1383 - newdata.children_id_card_type = '1' //this.data.childrencardtypeData.selected 1383 + newdata.children_id_card_type = '居民身份证' //this.data.childrencardtypeData.selected
1384 newdata.children_birthday = this.data.commonbirthDate.datelong 1384 newdata.children_birthday = this.data.commonbirthDate.datelong
1385 newdata.education_period_end = this.data.studyPeriodDate.datelong 1385 newdata.education_period_end = this.data.studyPeriodDate.datelong
1386 newdata.education_end = this.data.studyEndDate.datelong 1386 newdata.education_end = this.data.studyEndDate.datelong
@@ -1514,7 +1514,7 @@ Page({ @@ -1514,7 +1514,7 @@ Page({
1514 } 1514 }
1515 newdata.birthday = this.data.olderbirthDate.datelong 1515 newdata.birthday = this.data.olderbirthDate.datelong
1516 newdata.relationship = this.data.older_relativeData.selected 1516 newdata.relationship = this.data.older_relativeData.selected
1517 - newdata.id_card_type = '1' //this.data.oldercardtypeData.selected 1517 + newdata.id_card_type = '居民身份证' //this.data.oldercardtypeData.selected
1518 newdata.nation = "中国" 1518 newdata.nation = "中国"
1519 break; 1519 break;
1520 case 'medical_fund': 1520 case 'medical_fund':
@@ -1553,7 +1553,7 @@ Page({ @@ -1553,7 +1553,7 @@ Page({
1553 1553
1554 newdata.total_amount = parseFloat(formdata.total_amount) 1554 newdata.total_amount = parseFloat(formdata.total_amount)
1555 newdata.amount_by_person = parseFloat(formdata.amount_by_person) 1555 newdata.amount_by_person = parseFloat(formdata.amount_by_person)
1556 - newdata.id_card_type = '1'//this.data.cardtypeData.selected 1556 + newdata.id_card_type = '居民身份证'//this.data.cardtypeData.selected
1557 newdata.relationship = this.data.taxperson_relativeData.selected 1557 newdata.relationship = this.data.taxperson_relativeData.selected
1558 newdata.patient_birthday = this.data.commonbirthDate.datelong 1558 newdata.patient_birthday = this.data.commonbirthDate.datelong
1559 newdata.patient_nation = "中国" 1559 newdata.patient_nation = "中国"
@@ -1662,7 +1662,7 @@ Page({ @@ -1662,7 +1662,7 @@ Page({
1662 this.showToast('身份证格式有误') 1662 this.showToast('身份证格式有误')
1663 return 1663 return
1664 } 1664 }
1665 - newdata.owner_id_card_type = '1'//this.data.cardtypeData.selected 1665 + newdata.owner_id_card_type = '居民身份证'//this.data.cardtypeData.selected
1666 } 1666 }
1667 // if (this.data.rentLocateInfo.address_value[0].length < 1) { 1667 // if (this.data.rentLocateInfo.address_value[0].length < 1) {
1668 // this.showToast('请选择房屋地址') 1668 // this.showToast('请选择房屋地址')
@@ -1720,7 +1720,7 @@ Page({ @@ -1720,7 +1720,7 @@ Page({
1720 return 1720 return
1721 } 1721 }
1722 newdata.id_card_no = newdata.spouse_id_card_no ? newdata.spouse_id_card_no : '' 1722 newdata.id_card_no = newdata.spouse_id_card_no ? newdata.spouse_id_card_no : ''
1723 - newdata.id_card_type = '1' //this.data.lovercardtypeData.selected 1723 + newdata.id_card_type = '居民身份证' //this.data.lovercardtypeData.selected
1724 newdata.birthday = this.data.loverbirthDate.datelong 1724 newdata.birthday = this.data.loverbirthDate.datelong
1725 newdata.nation = "中国" 1725 newdata.nation = "中国"
1726 } 1726 }
@@ -2,10 +2,7 @@ @@ -2,10 +2,7 @@
2 var app = getApp(); 2 var app = getApp();
3 var format = require('../../../../utils/util.js'); 3 var format = require('../../../../utils/util.js');
4 var baseUrl = app.globalData.baseUrl; 4 var baseUrl = app.globalData.baseUrl;
5 -// const cardTypeArray = ['居民身份证', '中国护照', '港澳居民来往内地通行证', '港澳居民居住证', '台湾居民来往大陆通行证', '台湾居民居住证', '外国护照', '外国人永久居留身份证', '外国人工作许可证(A类)', '外国人工作许可证(B类)', '外国人工作许可证(C类)'];  
6 -const cardTypeDicts = [{ 'code': '1', 'name': '居民身份证' }, { 'code': '2', 'name': '中国护照' }, { 'code': '3', 'name': '港澳居民来往内地通行证' }, { 'code': '4', 'name': '港澳居民居住证' }, { 'code': '5', 'name': '台湾居民来往大陆通行证' }, { 'code': '6', 'name': '台湾居民居住证' }, { 'code': '7', 'name': '外国护照' }, { 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }];  
7 -const cardTypes8 = [{ 'code': '1', 'name': '居民身份证' }, { 'code': '2', 'name': '中国护照' }, { 'code': '3', 'name': '港澳居民来往内地通行证' }, { 'code': '5', 'name': '台湾居民来往大陆通行证' }, { 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }];  
8 - 5 +const cardTypeArray8 = ['居民身份证', '中国护照', '港澳居民居住证', '台湾居民居住证', '外国人永久居留身份证', '外国人工作许可证(A类)', '外国人工作许可证(B类)', '外国人工作许可证(C类)'];
9 6
10 Page({ 7 Page({
11 cur_id:null, 8 cur_id:null,
@@ -44,9 +41,9 @@ Page({ @@ -44,9 +41,9 @@ Page({
44 label: '证照类型', 41 label: '证照类型',
45 bindtype: 'cardtype', 42 bindtype: 'cardtype',
46 placeholder: '请选择证照类型', 43 placeholder: '请选择证照类型',
47 - values: cardTypeDicts, 44 + values: cardTypeArray8,
48 // values: ["居民身份证", "军官证", '士兵证', '武警警官证', '港澳居民来往内地通行证', '外交官证', '中国护照','外国护照', '香港永久性居民身份证', '澳门特别行政区永久性居民身份证', '台湾身份证', '台湾居民来往大陆通行证', '外国人永久居留证'], 45 // values: ["居民身份证", "军官证", '士兵证', '武警警官证', '港澳居民来往内地通行证', '外交官证', '中国护照','外国护照', '香港永久性居民身份证', '澳门特别行政区永久性居民身份证', '台湾身份证', '台湾居民来往大陆通行证', '外国人永久居留证'],
49 - range_key: 'name', 46 + // range_key: 'name',
50 onChange: 'onPickerSelect' 47 onChange: 'onPickerSelect'
51 }, 48 },
52 forignerInfo: { 49 forignerInfo: {
@@ -183,7 +180,7 @@ Page({ @@ -183,7 +180,7 @@ Page({
183 age: tax_info.age, 180 age: tax_info.age,
184 mobile: tax_info.mobile, 181 mobile: tax_info.mobile,
185 genderData: this.data.genderData, 182 genderData: this.data.genderData,
186 - isIdCard: '1' == tax_info.id_card_type ? true : false, 183 + isIdCard: '居民身份证' == tax_info.id_card_type ? true : false,
187 card_number: tax_info.id_card_no, 184 card_number: tax_info.id_card_no,
188 countryData: this.data.countryData 185 countryData: this.data.countryData
189 }) 186 })
@@ -221,7 +218,7 @@ Page({ @@ -221,7 +218,7 @@ Page({
221 } 218 }
222 var cardtype_Data = that.data.cardtypeData 219 var cardtype_Data = that.data.cardtypeData
223 cardtype_Data.selected = '居民身份证' 220 cardtype_Data.selected = '居民身份证'
224 - cardtypeData.selected_code = '1' 221 + // cardtypeData.selected_code = '1'
225 var gender_Data = that.data.genderData 222 var gender_Data = that.data.genderData
226 gender_Data.selected = id_info.gender 223 gender_Data.selected = id_info.gender
227 224
@@ -257,74 +254,40 @@ Page({ @@ -257,74 +254,40 @@ Page({
257 }) 254 })
258 }, 255 },
259 256
260 - dealCardType: function (new_type_code) { 257 + dealCardType: function (new_type) {
261 var is_idcard = this.data.isIdCard 258 var is_idcard = this.data.isIdCard
262 - const new_type = cardTypeDicts[parseInt(new_type_code) - 1]['name']  
263 - this.data.cardtypeData.selected_code = new_type_code  
264 this.data.cardtypeData.selected = new_type 259 this.data.cardtypeData.selected = new_type
265 260
266 if ('居民身份证' == new_type) { 261 if ('居民身份证' == new_type) {
267 is_idcard = true 262 is_idcard = true
268 this.data.genderData.disabled = true 263 this.data.genderData.disabled = true
269 - // this.data.birthDate.disabled = true  
270 } else { 264 } else {
271 is_idcard = false 265 is_idcard = false
272 this.data.genderData.disabled = false 266 this.data.genderData.disabled = false
273 - // this.data.birthDate.disabled = false  
274 } 267 }
275 - // this.data.hasOtherCard = true  
276 this.data.overseas = '否' 268 this.data.overseas = '否'
277 - // this.data.taxpayerTypeData.disabled = false  
278 - // this.data.taxpayerTypeData.selected = ''  
279 if ('居民身份证' == new_type || '中国护照' == new_type) { 269 if ('居民身份证' == new_type || '中国护照' == new_type) {
280 this.data.countryData.selected = '中国' 270 this.data.countryData.selected = '中国'
281 this.data.countryData.disabled = true 271 this.data.countryData.disabled = true
282 - // this.data.hasOtherCard = false  
283 - // this.data.taxpayerTypeData.selected = '居民'  
284 - // this.data.taxpayerTypeData.disabled = true  
285 } else if (new_type.indexOf("港澳") != -1) { 272 } else if (new_type.indexOf("港澳") != -1) {
286 this.data.countryData.values = ['中国香港', '中国澳门'] 273 this.data.countryData.values = ['中国香港', '中国澳门']
287 this.data.countryData.selected = '' 274 this.data.countryData.selected = ''
288 this.data.countryData.disabled = false 275 this.data.countryData.disabled = false
289 - // this.data.nameText = '英文名'  
290 - // if (new_type.indexOf('通行证') != -1) {  
291 - // this.data.otherCardtypeData.values = [{ 'code': '4', 'name': '港澳居民居住证' }];  
292 - // } else {  
293 - // this.data.otherCardtypeData.values = [{ 'code': '3', 'name': '港澳居民来往内地通行证' }];  
294 - // }  
295 } else if (new_type.indexOf("台湾") != -1) { 276 } else if (new_type.indexOf("台湾") != -1) {
296 this.data.countryData.selected = '中国台湾' 277 this.data.countryData.selected = '中国台湾'
297 this.data.countryData.disabled = true 278 this.data.countryData.disabled = true
298 - // this.data.nameText = '英文名'  
299 - // if (new_type.indexOf('通行证') != -1) {  
300 - // this.data.otherCardtypeData.values = [{ 'code': '6', 'name': '台湾居民居住证' }];  
301 - // } else {  
302 - // this.data.otherCardtypeData.values = [{ 'code': '5', 'name': '台湾居民来往大陆通行证' }];  
303 - // }  
304 -  
305 } else { 279 } else {
306 this.data.overseas = '是' 280 this.data.overseas = '是'
307 this.data.countryData.selected = '' 281 this.data.countryData.selected = ''
308 this.data.countryData.values = this.countrys ? this.countrys : [] 282 this.data.countryData.values = this.countrys ? this.countrys : []
309 this.data.countryData.disabled = false 283 this.data.countryData.disabled = false
310 - // this.data.nameText = '中文名'  
311 - // if (new_type.indexOf("外国护照") != -1) {  
312 - // this.data.otherCardtypeData.values = [{ 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }];  
313 - // } else {  
314 - // this.data.otherCardtypeData.values = [{ 'code': '7', 'name': '外国护照' }];  
315 - // }  
316 } 284 }
317 this.setData({ 285 this.setData({
318 isIdCard: is_idcard, 286 isIdCard: is_idcard,
319 - // hasOtherCard: this.data.hasOtherCard,  
320 genderData: this.data.genderData, 287 genderData: this.data.genderData,
321 - // birthDate: this.data.birthDate,  
322 countryData: this.data.countryData, 288 countryData: this.data.countryData,
323 cardtypeData: this.data.cardtypeData, 289 cardtypeData: this.data.cardtypeData,
324 - // otherCardtypeData: this.data.otherCardtypeData,  
325 - // nameText: this.data.nameText,  
326 overseas: this.data.overseas, 290 overseas: this.data.overseas,
327 - // taxpayerTypeData: this.data.taxpayerTypeData  
328 }) 291 })
329 292
330 293
@@ -344,14 +307,14 @@ Page({ @@ -344,14 +307,14 @@ Page({
344 break; 307 break;
345 case 'cardtype': 308 case 'cardtype':
346 var cardtypeData = this.data.cardtypeData 309 var cardtypeData = this.data.cardtypeData
347 - var new_type = cardtypeData.values[e.detail.value]['name']  
348 - var new_type_code = cardtypeData.values[e.detail.value]['code']  
349 - // if (new_type != cardtypeData.selected) {  
350 - this.dealCardType(new_type_code) 310 + var new_type = cardtypeData.values[e.detail.value] //['name']
  311 + // var new_type_code = cardtypeData.values[e.detail.value]['code']
  312 + if (new_type != cardtypeData.selected) {
  313 + this.dealCardType(new_type)
351 this.setData({ 314 this.setData({
352 card_number: "" 315 card_number: ""
353 }) 316 })
354 - // } 317 + }
355 break; 318 break;
356 case 'gender': 319 case 'gender':
357 var gender_data = this.data.genderData 320 var gender_data = this.data.genderData
@@ -489,7 +452,7 @@ Page({ @@ -489,7 +452,7 @@ Page({
489 data: { 452 data: {
490 'certification_status': that.getCertifyStatus(formdata), 453 'certification_status': that.getCertifyStatus(formdata),
491 "family_ties": that.data.relativeData.selected, 454 "family_ties": that.data.relativeData.selected,
492 - "id_card_type": that.data.cardtypeData.selected_code, 455 + "id_card_type": that.data.cardtypeData.selected,//_code,
493 "id_card_no": that.data.card_number, 456 "id_card_no": that.data.card_number,
494 "name": name, 457 "name": name,
495 "gender": that.data.genderData.selected, 458 "gender": that.data.genderData.selected,
@@ -3,8 +3,9 @@ var app = getApp(); @@ -3,8 +3,9 @@ var app = getApp();
3 var baseUrl = app.globalData.baseUrl; 3 var baseUrl = app.globalData.baseUrl;
4 // var countryInfo = require('../../../../utils/country.js'); 4 // var countryInfo = require('../../../../utils/country.js');
5 // const cardTypeArray = ['居民身份证', '中国护照', '港澳居民来往内地通行证', '港澳居民居住证', '台湾居民来往大陆通行证', '台湾居民居住证', '外国护照', '外国人永久居留身份证', '外国人工作许可证(A类)', '外国人工作许可证(B类)', '外国人工作许可证(C类)']; 5 // const cardTypeArray = ['居民身份证', '中国护照', '港澳居民来往内地通行证', '港澳居民居住证', '台湾居民来往大陆通行证', '台湾居民居住证', '外国护照', '外国人永久居留身份证', '外国人工作许可证(A类)', '外国人工作许可证(B类)', '外国人工作许可证(C类)'];
6 -const cardTypeDicts = [{ 'code': '1', 'name': '居民身份证' }, { 'code': '2', 'name': '中国护照' }, { 'code': '3', 'name': '港澳居民来往内地通行证' }, { 'code': '4', 'name': '港澳居民居住证' }, { 'code': '5', 'name': '台湾居民来往大陆通行证' }, { 'code': '6', 'name': '台湾居民居住证' }, { 'code': '7', 'name': '外国护照' }, { 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)'}];  
7 -const cardTypes8 = [{ 'code': '1', 'name': '居民身份证' }, { 'code': '2', 'name': '中国护照' }, { 'code': '4', 'name': '港澳居民居住证' }, { 'code': '6', 'name': '台湾居民居住证' }, { 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }]; 6 +const cardTypeArray8 = ['居民身份证', '中国护照', '港澳居民居住证', '台湾居民居住证', '外国人永久居留身份证', '外国人工作许可证(A类)', '外国人工作许可证(B类)', '外国人工作许可证(C类)'];
  7 +// const cardTypeDicts = [{ 'code': '1', 'name': '居民身份证' }, { 'code': '2', 'name': '中国护照' }, { 'code': '3', 'name': '港澳居民来往内地通行证' }, { 'code': '4', 'name': '港澳居民居住证' }, { 'code': '5', 'name': '台湾居民来往大陆通行证' }, { 'code': '6', 'name': '台湾居民居住证' }, { 'code': '7', 'name': '外国护照' }, { 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)'}];
  8 +// const cardTypes8 = [{ 'code': '1', 'name': '居民身份证' }, { 'code': '2', 'name': '中国护照' }, { 'code': '4', 'name': '港澳居民居住证' }, { 'code': '6', 'name': '台湾居民居住证' }, { 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }];
8 9
9 Page({ 10 Page({
10 11
@@ -54,8 +55,8 @@ Page({ @@ -54,8 +55,8 @@ Page({
54 bindtype: 'cardtype', 55 bindtype: 'cardtype',
55 placeholder: '请选择证照类型', 56 placeholder: '请选择证照类型',
56 selected: '', 57 selected: '',
57 - values: cardTypes8,  
58 - range_key:'name', 58 + values: cardTypeArray8,
  59 + // range_key:'name',
59 // values: ["居民身份证", "军官证", '士兵证', '武警警官证', '港澳居民来往内地通行证', '外交官证', '中国护照', 60 // values: ["居民身份证", "军官证", '士兵证', '武警警官证', '港澳居民来往内地通行证', '外交官证', '中国护照',
60 // '外国护照', '香港永久性居民身份证', '澳门特别行政区永久性居民身份证', '台湾身份证', '台湾居民来往大陆通行证', '外国人永久居留证' 61 // '外国护照', '香港永久性居民身份证', '澳门特别行政区永久性居民身份证', '台湾身份证', '台湾居民来往大陆通行证', '外国人永久居留证'
61 // ], 62 // ],
@@ -68,7 +69,7 @@ Page({ @@ -68,7 +69,7 @@ Page({
68 placeholder: '请选择证照类型', 69 placeholder: '请选择证照类型',
69 selected: '', 70 selected: '',
70 values: [], 71 values: [],
71 - range_key: 'name', 72 + // range_key: 'name',
72 onChange: 'onPickerSelect' 73 onChange: 'onPickerSelect'
73 }, 74 },
74 countryData: { 75 countryData: {
@@ -398,17 +399,17 @@ Page({ @@ -398,17 +399,17 @@ Page({
398 } 399 }
399 400
400 this.data.personstatusData.selected = tax_info.taxpayer_status 401 this.data.personstatusData.selected = tax_info.taxpayer_status
401 - this.data.cardtypeData.selected = cardTypeDicts[parseInt(tax_info.id_card_type) - 1]['name']  
402 - this.data.cardtypeData.selected_code = tax_info.id_card_type 402 + this.data.cardtypeData.selected = tax_info.id_card_type //cardTypeDicts[parseInt(tax_info.id_card_type) - 1]['name']
  403 + // this.data.cardtypeData.selected_code = tax_info.id_card_type
403 this.data.card_number = tax_info.id_card_no 404 this.data.card_number = tax_info.id_card_no
404 405
405 - // this.data.otherCardtypeData.selected = cardTypeDicts[parseInt(tax_info.other_id_card_type) - 1]['name'] 406 + this.data.otherCardtypeData.selected = tax_info.other_id_card_type //cardTypeDicts[parseInt(tax_info.other_id_card_type) - 1]['name']
406 // this.data.otherCardtypeData.selected_code = tax_info.other_id_card_type 407 // this.data.otherCardtypeData.selected_code = tax_info.other_id_card_type
407 408
408 this.data.other_card_number = tax_info.other_id_card_no 409 this.data.other_card_number = tax_info.other_id_card_no
409 this.data.overseas = tax_info.is_overseas_personnel 410 this.data.overseas = tax_info.is_overseas_personnel
410 this.data.countryData.selected = tax_info.native 411 this.data.countryData.selected = tax_info.native
411 - this.data.birthCountryData.selected = tax_info.brith_native 412 + this.data.birthCountryData.selected = tax_info.birth_native
412 this.data.taxpayerTypeData.selected = tax_info.taxpayer_type =='resident'?'居民':'非居民' 413 this.data.taxpayerTypeData.selected = tax_info.taxpayer_type =='resident'?'居民':'非居民'
413 414
414 this.data.mobile = tax_info.mobile 415 this.data.mobile = tax_info.mobile
@@ -436,7 +437,7 @@ Page({ @@ -436,7 +437,7 @@ Page({
436 this.data.firstEntryDate.selected = (firstEntryDate.indexOf("NaN") == -1) ? firstEntryDate:'' 437 this.data.firstEntryDate.selected = (firstEntryDate.indexOf("NaN") == -1) ? firstEntryDate:''
437 this.data.predictLeaveDate.selected = (predictLeaveDate.indexOf("NaN") == -1) ? predictLeaveDate : '' 438 this.data.predictLeaveDate.selected = (predictLeaveDate.indexOf("NaN") == -1) ? predictLeaveDate : ''
438 439
439 - this.data.professionData.selected = tax_info.profession.three_level_name 440 + // this.data.professionData.selected = tax_info.profession.three_level_name
440 441
441 this.data.birthDate.end = curdate 442 this.data.birthDate.end = curdate
442 this.data.startDate.end = curdate 443 this.data.startDate.end = curdate
@@ -446,7 +447,7 @@ Page({ @@ -446,7 +447,7 @@ Page({
446 this.data.lieshuInfo.selected = tax_info.is_martyr_family 447 this.data.lieshuInfo.selected = tax_info.is_martyr_family
447 this.data.lonelyolderInfo.selected = tax_info.is_lonely_man 448 this.data.lonelyolderInfo.selected = tax_info.is_lonely_man
448 this.data.bankInfo.selected = tax_info.bank 449 this.data.bankInfo.selected = tax_info.bank
449 - // this.data.contactaddressInfo.selected = tax_info.contact_address.province + tax_info.contact_address.city + tax_info.contact_address.district 450 + this.data.contactaddressInfo.selected = tax_info.contact_address.province + tax_info.contact_address.city + tax_info.contact_address.district
450 this.data.currentaddressInfo.selected = tax_info.current_address.province + tax_info.current_address.city + tax_info.current_address.district 451 this.data.currentaddressInfo.selected = tax_info.current_address.province + tax_info.current_address.city + tax_info.current_address.district
451 this.data.birthaddressInfo.selected = (tax_info.huji_address.province + tax_info.huji_address.city + tax_info.huji_address.district).replace(/(^\s*)|(\s*$)/g, "") 452 this.data.birthaddressInfo.selected = (tax_info.huji_address.province + tax_info.huji_address.city + tax_info.huji_address.district).replace(/(^\s*)|(\s*$)/g, "")
452 this.data.employeeInfo.selected = tax_info.is_employee 453 this.data.employeeInfo.selected = tax_info.is_employee
@@ -485,7 +486,7 @@ Page({ @@ -485,7 +486,7 @@ Page({
485 endDate: this.data.endDate, 486 endDate: this.data.endDate,
486 firstEntryDate: this.data.firstEntryDate, 487 firstEntryDate: this.data.firstEntryDate,
487 predictLeaveDate: this.data.predictLeaveDate, 488 predictLeaveDate: this.data.predictLeaveDate,
488 - isIdCard: '1' == tax_info.id_card_type ? true : false, 489 + isIdCard: '居民身份证' == tax_info.id_card_type ? true : false,
489 card_number: this.data.card_number, 490 card_number: this.data.card_number,
490 other_card_number: this.data.other_card_number, 491 other_card_number: this.data.other_card_number,
491 countryData: this.data.countryData, 492 countryData: this.data.countryData,
@@ -648,7 +649,7 @@ Page({ @@ -648,7 +649,7 @@ Page({
648 649
649 var cardtypeData = that.data.cardtypeData 650 var cardtypeData = that.data.cardtypeData
650 cardtypeData.selected = '居民身份证' 651 cardtypeData.selected = '居民身份证'
651 - cardtypeData.selected_code = '1' 652 + // cardtypeData.selected_code = '1'
652 var gender_Data = that.data.genderData 653 var gender_Data = that.data.genderData
653 gender_Data.selected = id_info.gender 654 gender_Data.selected = id_info.gender
654 655
@@ -707,11 +708,12 @@ Page({ @@ -707,11 +708,12 @@ Page({
707 708
708 }, 709 },
709 710
710 - dealCardType: function (new_type_code){  
711 - console.log('cardtype_code', new_type_code) 711 + dealCardType: function (new_type){
  712 + // console.log('cardtype_code', new_type_code)
  713 + console.log('cardtype', new_type)
712 var is_idcard = this.data.isIdCard 714 var is_idcard = this.data.isIdCard
713 - const new_type = cardTypeDicts[parseInt(new_type_code)-1]['name']  
714 - this.data.cardtypeData.selected_code = new_type_code 715 + // const new_type = cardTypeDicts[parseInt(new_type_code)-1]['name']
  716 + // this.data.cardtypeData.selected_code = new_type_code
715 this.data.cardtypeData.selected = new_type 717 this.data.cardtypeData.selected = new_type
716 718
717 if ('居民身份证' == new_type) { 719 if ('居民身份证' == new_type) {
@@ -741,7 +743,7 @@ Page({ @@ -741,7 +743,7 @@ Page({
741 // if (new_type.indexOf('通行证') != -1){ 743 // if (new_type.indexOf('通行证') != -1){
742 // this.data.otherCardtypeData.values = [{ 'code': '4', 'name': '港澳居民居住证'}]; 744 // this.data.otherCardtypeData.values = [{ 'code': '4', 'name': '港澳居民居住证'}];
743 // }else{ 745 // }else{
744 - this.data.otherCardtypeData.values = [{ 'code': '3', 'name': '港澳居民来往内地通行证'}]; 746 + this.data.otherCardtypeData.values = ['港澳居民来往内地通行证'];// [{ 'code': '3', 'name': '港澳居民来往内地通行证'}];
745 // } 747 // }
746 } else if (new_type.indexOf("台湾") != -1) { 748 } else if (new_type.indexOf("台湾") != -1) {
747 this.data.countryData.selected = '中国台湾' 749 this.data.countryData.selected = '中国台湾'
@@ -750,7 +752,7 @@ Page({ @@ -750,7 +752,7 @@ Page({
750 // if (new_type.indexOf('通行证') != -1) { 752 // if (new_type.indexOf('通行证') != -1) {
751 // this.data.otherCardtypeData.values = [{ 'code': '6', 'name': '台湾居民居住证' }]; 753 // this.data.otherCardtypeData.values = [{ 'code': '6', 'name': '台湾居民居住证' }];
752 // } else { 754 // } else {
753 - this.data.otherCardtypeData.values = [{ 'code': '5', 'name': '台湾居民来往大陆通行证' }]; 755 + this.data.otherCardtypeData.values = ['台湾居民来往大陆通行证']; //[{ 'code': '5', 'name': '台湾居民来往大陆通行证' }];
754 // } 756 // }
755 757
756 } else { 758 } else {
@@ -762,7 +764,7 @@ Page({ @@ -762,7 +764,7 @@ Page({
762 // if (new_type.indexOf("外国护照") != -1) { 764 // if (new_type.indexOf("外国护照") != -1) {
763 // this.data.otherCardtypeData.values = [{ 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }]; 765 // this.data.otherCardtypeData.values = [{ 'code': '8', 'name': '外国人永久居留身份证' }, { 'code': '9', 'name': '外国人工作许可证(A类)' }, { 'code': '10', 'name': '外国人工作许可证(B类)' }, { 'code': '11', 'name': '外国人工作许可证(C类)' }];
764 // } else { 766 // } else {
765 - this.data.otherCardtypeData.values = [{ 'code': '7', 'name': '外国护照' }]; 767 + this.data.otherCardtypeData.values = ['外国护照']; //[{ 'code': '7', 'name': '外国护照' }];
766 // } 768 // }
767 } 769 }
768 this.setData({ 770 this.setData({
@@ -794,11 +796,11 @@ Page({ @@ -794,11 +796,11 @@ Page({
794 break; 796 break;
795 case 'cardtype': 797 case 'cardtype':
796 var cardtypeData = this.data.cardtypeData 798 var cardtypeData = this.data.cardtypeData
797 - var new_type = cardtypeData.values[e.detail.value]['name']  
798 - var new_type_code = cardtypeData.values[e.detail.value]['code'] 799 + var new_type = cardtypeData.values[e.detail.value] //['name']
  800 + // var new_type_code = cardtypeData.values[e.detail.value]['code']
799 var selected = cardtypeData.selected 801 var selected = cardtypeData.selected
800 if (new_type != selected) { 802 if (new_type != selected) {
801 - this.dealCardType(new_type_code) 803 + this.dealCardType(new_type)
802 var setData = { card_number: ''} 804 var setData = { card_number: ''}
803 if ((new_type.indexOf('外国人') != -1) && (selected.indexOf('外国人') != -1)) { 805 if ((new_type.indexOf('外国人') != -1) && (selected.indexOf('外国人') != -1)) {
804 console.log('外国人', new_type, selected) 806 console.log('外国人', new_type, selected)
@@ -812,12 +814,12 @@ Page({ @@ -812,12 +814,12 @@ Page({
812 break; 814 break;
813 case 'other_cardtype': 815 case 'other_cardtype':
814 var otherCardtypeData = this.data.otherCardtypeData 816 var otherCardtypeData = this.data.otherCardtypeData
815 - var new_type = otherCardtypeData.values[e.detail.value]['name']  
816 - var new_type_code = otherCardtypeData.values[e.detail.value]['code'] 817 + var new_type = otherCardtypeData.values[e.detail.value] //['name']
  818 + // var new_type_code = otherCardtypeData.values[e.detail.value]['code']
817 819
818 if (new_type != otherCardtypeData.selected) { 820 if (new_type != otherCardtypeData.selected) {
819 otherCardtypeData.selected = new_type 821 otherCardtypeData.selected = new_type
820 - otherCardtypeData.selected_code = new_type_code 822 + // otherCardtypeData.selected_code = new_type_code
821 this.setData({ 823 this.setData({
822 other_card_number: "", 824 other_card_number: "",
823 otherCardtypeData: this.data.otherCardtypeData 825 otherCardtypeData: this.data.otherCardtypeData
@@ -1310,9 +1312,10 @@ Page({ @@ -1310,9 +1312,10 @@ Page({
1310 "native": that.data.countryData.selected, 1312 "native": that.data.countryData.selected,
1311 "taxpayer_type": that.data.taxpayerTypeData.selected == '是' ? 'resident' :'non-resident', 1313 "taxpayer_type": that.data.taxpayerTypeData.selected == '是' ? 'resident' :'non-resident',
1312 "is_overseas_personnel": that.data.overseas, 1314 "is_overseas_personnel": that.data.overseas,
1313 - "id_card_type": ''+that.data.cardtypeData.selected_code, 1315 + 'birth_native': that.data.birthCountryData.selected,
  1316 + "id_card_type": that.data.cardtypeData.selected, //selected_code,
1314 "id_card_no": that.data.card_number, 1317 "id_card_no": that.data.card_number,
1315 - "other_id_card_type": that.data.otherCardtypeData.selected_code, 1318 + "other_id_card_type": that.data.otherCardtypeData.selected, //selected_code,
1316 "other_id_card_no": formdata.other_card_number, 1319 "other_id_card_no": formdata.other_card_number,
1317 "gender": that.data.genderData.selected, 1320 "gender": that.data.genderData.selected,
1318 "birth_date": that.data.long_birth_date, 1321 "birth_date": that.data.long_birth_date,
注册登录 后发表评论