提交 bab549f28562b73228d389a09a11141c4be3467e

作者 pangy
2 个父辈 492d4e07 00a95a1b

Merge branch 'dev_py' into dev2.0

@@ -183,6 +183,14 @@ Page({ @@ -183,6 +183,14 @@ Page({
183 placeholder: '请选择教育类型', 183 placeholder: '请选择教育类型',
184 onChange: 'onPickerSelect' 184 onChange: 'onPickerSelect'
185 }, 185 },
  186 + certificateDate: {
  187 + label: '证书名称',
  188 + isrequre: true,
  189 + bindtype: 'certificate',
  190 + values: [],
  191 + placeholder: '请输入证书名称',
  192 + onChange: 'onPickerSelect'
  193 + },
186 edulevelData: { 194 edulevelData: {
187 label: '教育阶段', 195 label: '教育阶段',
188 isrequre: true, 196 isrequre: true,
@@ -535,6 +543,7 @@ Page({ @@ -535,6 +543,7 @@ Page({
535 this.getTaxList() 543 this.getTaxList()
536 } 544 }
537 } else if ("continuing_education" == options.status) { 545 } else if ("continuing_education" == options.status) {
  546 + this.getCertificates()
538 var studystart_date = this.data.studystartdate 547 var studystart_date = this.data.studystartdate
539 studystart_date.label = "入学时间起" 548 studystart_date.label = "入学时间起"
540 var studyend_date = this.data.studyenddate 549 var studyend_date = this.data.studyenddate
@@ -778,7 +787,9 @@ Page({ @@ -778,7 +787,9 @@ Page({
778 setData.applydate = applydate 787 setData.applydate = applydate
779 788
780 if (data.certification_name && data.certification_name.length) { 789 if (data.certification_name && data.certification_name.length) {
781 - setData.certification_name = data.certification_name 790 + var certificateDate = this.data.certificateDate
  791 + certificateDate.selected = data.certification_name
  792 + setData.certificateDate = certificateDate
782 } 793 }
783 if (data.certification_no && data.certification_no.length) { 794 if (data.certification_no && data.certification_no.length) {
784 setData.certification_no = data.certification_no 795 setData.certification_no = data.certification_no
@@ -1072,7 +1083,9 @@ Page({ @@ -1072,7 +1083,9 @@ Page({
1072 setData.applydate = applydate 1083 setData.applydate = applydate
1073 } 1084 }
1074 if (data.certification_name && data.certification_name.length) { 1085 if (data.certification_name && data.certification_name.length) {
1075 - setData.certification_name = data.certification_name 1086 + var certificateDate = this.data.certificateDate
  1087 + certificateDate.selected = data.certification_name
  1088 + setData.certificateDate = certificateDate
1076 } 1089 }
1077 if (data.certification_no && data.certification_no.length) { 1090 if (data.certification_no && data.certification_no.length) {
1078 setData.certification_no = data.certification_no 1091 setData.certification_no = data.certification_no
@@ -1350,7 +1363,29 @@ Page({ @@ -1350,7 +1363,29 @@ Page({
1350 } 1363 }
1351 }) 1364 })
1352 }, 1365 },
1353 - 1366 + getCertificates: function () {
  1367 + var that = this
  1368 + var Authorization = app.globalData.Authorization;
  1369 + var bank_info = that.data.bankInfo
  1370 + wx.request({
  1371 + url: baseUrl + 'persontax/v1/certification-list' ,
  1372 + header: {
  1373 + 'content-type': 'application/json', // 默认值
  1374 + "Authorization": Authorization
  1375 + },
  1376 + success: function (res) {
  1377 + console.log('certification', res)
  1378 + that.profs_cers = res.data.profession_certificates
  1379 + that.major_cers = res.data.major_certificates
  1380 + },
  1381 + fail(res) {
  1382 + console.log(res)
  1383 + },
  1384 + complete() {
  1385 + wx.hideLoading()
  1386 + }
  1387 + })
  1388 + },
1354 handleBankinfo: function(data) { 1389 handleBankinfo: function(data) {
1355 var bank_name = [] 1390 var bank_name = []
1356 for (var i = 0; i < data.length; i++) { 1391 for (var i = 0; i < data.length; i++) {
@@ -1497,10 +1532,14 @@ Page({ @@ -1497,10 +1532,14 @@ Page({
1497 return 1532 return
1498 } 1533 }
1499 } 1534 }
1500 - if (!formdata.certification_name || formdata.certification_name.length < 1) {  
1501 - this.showToast('请填写证书名称') 1535 + // if (!formdata.certification_name || formdata.certification_name.length < 1) {
  1536 + // this.showToast('请填写证书名称')
  1537 + // return
  1538 + // }
  1539 + if (this.data.certificateDate.selected.length < 1) {
  1540 + this.showToast('请选择证书名称')
1502 return 1541 return
1503 - } 1542 + }
1504 if (!formdata.certification_no || formdata.certification_no.length < 1) { 1543 if (!formdata.certification_no || formdata.certification_no.length < 1) {
1505 this.showToast('请填写证书编号') 1544 this.showToast('请填写证书编号')
1506 return 1545 return
@@ -1513,6 +1552,7 @@ Page({ @@ -1513,6 +1552,7 @@ Page({
1513 // newdata.edu_type_lable = '1' 1552 // newdata.edu_type_lable = '1'
1514 newdata.approval_date = this.data.applydate.datelong 1553 newdata.approval_date = this.data.applydate.datelong
1515 newdata.education_type = this.data.edustyleData.selected == '技能人员职业资格' ? 'profession' : 'major' 1554 newdata.education_type = this.data.edustyleData.selected == '技能人员职业资格' ? 'profession' : 'major'
  1555 + newdata.certification_name = this.data.certificateDate.selected
1516 } 1556 }
1517 break; 1557 break;
1518 case 'support_duty': 1558 case 'support_duty':
@@ -2180,8 +2220,19 @@ Page({ @@ -2180,8 +2220,19 @@ Page({
2180 case 'edu_style': 2220 case 'edu_style':
2181 var edustyle_data = this.data.edustyleData 2221 var edustyle_data = this.data.edustyleData
2182 edustyle_data.selected = edustyle_data.values[e.detail.value] 2222 edustyle_data.selected = edustyle_data.values[e.detail.value]
  2223 + var certificateDate = this.data.certificateDate
  2224 + certificateDate.values = e.detail.value == '0' ? this.profs_cers : this.major_cers
  2225 + certificateDate.selected = ''
  2226 + this.setData({
  2227 + edustyleData: edustyle_data,
  2228 + certificateDate: certificateDate
  2229 + })
  2230 + break;
  2231 + case 'certificate':
  2232 + var certificateDate = this.data.certificateDate
  2233 + certificateDate.selected = certificateDate.values[e.detail.value]
2183 this.setData({ 2234 this.setData({
2184 - edustyleData: edustyle_data 2235 + certificateDate: certificateDate
2185 }) 2236 })
2186 break; 2237 break;
2187 case 'edu_level': 2238 case 'edu_level':
@@ -94,11 +94,12 @@ @@ -94,11 +94,12 @@
94 <view class='divide_line_30'></view> 94 <view class='divide_line_30'></view>
95 <template is="picker_cell_normal" data="{{...applydate}}" /> 95 <template is="picker_cell_normal" data="{{...applydate}}" />
96 <view class='divide_line_30'></view> 96 <view class='divide_line_30'></view>
97 - <view style='height:90rpx'> 97 + <template is="picker_cell_normal" data="{{...certificateDate}}" />
  98 + <!-- <view style='height:90rpx'>
98 <text class='red_star_right_10'>*</text> 99 <text class='red_star_right_10'>*</text>
99 <text class='text_777_30 float_left'>证书名称</text> 100 <text class='text_777_30 float_left'>证书名称</text>
100 <input class='input_wrap' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right;color:#000;' placeholder='请输入证书名称' name='certification_name' value='{{certification_name}}'></input> 101 <input class='input_wrap' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right;color:#000;' placeholder='请输入证书名称' name='certification_name' value='{{certification_name}}'></input>
101 - </view> 102 + </view> -->
102 <view class='divide_line_30'></view> 103 <view class='divide_line_30'></view>
103 <view style='height:90rpx'> 104 <view style='height:90rpx'>
104 <text class='red_star_right_10'>*</text> 105 <text class='red_star_right_10'>*</text>
注册登录 后发表评论