正在显示
2 个修改的文件
包含
38 行增加
和
20 行删除
@@ -18,7 +18,7 @@ Page({ | @@ -18,7 +18,7 @@ Page({ | ||
18 | title: '', | 18 | title: '', |
19 | isIdCard:true, | 19 | isIdCard:true, |
20 | extrainfo_arr: ["请上传子女出生证明、学籍信息凭证、学费凭证、本人结婚证和分摊协议", "请上传学历学籍凭证", "请上传出生证明或关系证明、独生子女证、分摊协议、其他法定赡养人赡养证明", "请上传诊断书和医疗费用收据", "请上传首套房证明、还款证明、不动产登记证、结婚证和夫妻约定抵扣协议"], | 20 | extrainfo_arr: ["请上传子女出生证明、学籍信息凭证、学费凭证、本人结婚证和分摊协议", "请上传学历学籍凭证", "请上传出生证明或关系证明、独生子女证、分摊协议、其他法定赡养人赡养证明", "请上传诊断书和医疗费用收据", "请上传首套房证明、还款证明、不动产登记证、结婚证和夫妻约定抵扣协议"], |
21 | - cur_index: 'children_education', | 21 | + cur_index: 'medical_fund', |
22 | lovercardtypeData: { | 22 | lovercardtypeData: { |
23 | label: '身份证件类型', | 23 | label: '身份证件类型', |
24 | bindtype: 'lovercardtype', | 24 | bindtype: 'lovercardtype', |
@@ -45,11 +45,12 @@ Page({ | @@ -45,11 +45,12 @@ Page({ | ||
45 | }, | 45 | }, |
46 | taxperson_relativeData: { | 46 | taxperson_relativeData: { |
47 | label: '与纳税人的关系', | 47 | label: '与纳税人的关系', |
48 | + isrequre: true, | ||
48 | bindtype: 'taxperson_relative', | 49 | bindtype: 'taxperson_relative', |
49 | selected: '', | 50 | selected: '', |
50 | isblack: 'true', | 51 | isblack: 'true', |
51 | placeholder: '请选择与纳税人的关系', | 52 | placeholder: '请选择与纳税人的关系', |
52 | - values: ["父子", "父女", "母子", "母女"], | 53 | + values: ["本人", "配偶", "子女"], |
53 | onChange: 'onPickerSelect' | 54 | onChange: 'onPickerSelect' |
54 | }, | 55 | }, |
55 | childrencardtypeData: { | 56 | childrencardtypeData: { |
@@ -148,9 +149,11 @@ Page({ | @@ -148,9 +149,11 @@ Page({ | ||
148 | onChange: 'onPickerSelect' | 149 | onChange: 'onPickerSelect' |
149 | }, | 150 | }, |
150 | cardtypeData: { | 151 | cardtypeData: { |
151 | - label: '证件类型', | 152 | + label: '身份证件类型', |
153 | + isrequre: true, | ||
152 | bindtype: 'cardtype', | 154 | bindtype: 'cardtype', |
153 | - selected: '', | 155 | + selected: '居民身份证', |
156 | + disabled: true, | ||
154 | isblack: 'true', | 157 | isblack: 'true', |
155 | placeholder: '请选择证件类型', | 158 | placeholder: '请选择证件类型', |
156 | values: ["居民身份证", "军官证", '士兵证', '武警警官证', '港澳居民来往内地通行证', '外交官证', '中国护照', | 159 | values: ["居民身份证", "军官证", '士兵证', '武警警官证', '港澳居民来往内地通行证', '外交官证', '中国护照', |
@@ -529,8 +532,10 @@ Page({ | @@ -529,8 +532,10 @@ Page({ | ||
529 | console.log("formSubmit", e); | 532 | console.log("formSubmit", e); |
530 | var formdata = e.detail.value | 533 | var formdata = e.detail.value |
531 | var newdata = formdata; | 534 | var newdata = formdata; |
535 | + var subUrl = '' | ||
532 | switch (this.data.cur_index + '') { | 536 | switch (this.data.cur_index + '') { |
533 | case 'children_education': | 537 | case 'children_education': |
538 | + subUrl = 'persontax/v1/children-educations' | ||
534 | if (!formdata.children_id_card_no || formdata.children_id_card_no.length < 1) { | 539 | if (!formdata.children_id_card_no || formdata.children_id_card_no.length < 1) { |
535 | this.showToast('请填写子女证件号码') | 540 | this.showToast('请填写子女证件号码') |
536 | return | 541 | return |
@@ -595,6 +600,7 @@ Page({ | @@ -595,6 +600,7 @@ Page({ | ||
595 | newdata.nation = "中国" | 600 | newdata.nation = "中国" |
596 | break; | 601 | break; |
597 | case 'continuing_education': | 602 | case 'continuing_education': |
603 | + subUrl = 'persontax/v1/continuing-educations' | ||
598 | if (this.data.edutypeData.selected.length < 1) { | 604 | if (this.data.edutypeData.selected.length < 1) { |
599 | this.showToast('请选择教育类别') | 605 | this.showToast('请选择教育类别') |
600 | return | 606 | return |
@@ -639,6 +645,7 @@ Page({ | @@ -639,6 +645,7 @@ Page({ | ||
639 | } | 645 | } |
640 | break; | 646 | break; |
641 | case 'support_duty': | 647 | case 'support_duty': |
648 | + // subUrl = 'persontax/v1/continuing-educations' | ||
642 | if (this.data.supporttypeData.selected.length < 1) { | 649 | if (this.data.supporttypeData.selected.length < 1) { |
643 | this.showToast('请选择赡养类型') | 650 | this.showToast('请选择赡养类型') |
644 | return | 651 | return |
@@ -669,29 +676,34 @@ Page({ | @@ -669,29 +676,34 @@ Page({ | ||
669 | newdata.older_cardtype = this.data.oldercardtypeData.selected | 676 | newdata.older_cardtype = this.data.oldercardtypeData.selected |
670 | break; | 677 | break; |
671 | case 'medical_fund': | 678 | case 'medical_fund': |
679 | + subUrl = 'persontax/v1/medical-funds' | ||
672 | if (!formdata.name || formdata.name.length < 1) { | 680 | if (!formdata.name || formdata.name.length < 1) { |
673 | this.showToast('请填写姓名') | 681 | this.showToast('请填写姓名') |
674 | return | 682 | return |
675 | } else if (this.data.cardtypeData.selected.length < 1) { | 683 | } else if (this.data.cardtypeData.selected.length < 1) { |
676 | - this.showToast('请选择赡养人证件类型') | 684 | + this.showToast('请选择证件类型') |
677 | return | 685 | return |
678 | - } else if (!formdata.idno || formdata.idno.length < 1) { | 686 | + } else if (!formdata.id_card_no || formdata.id_card_no.length < 1) { |
679 | this.showToast('请填写证件号码') | 687 | this.showToast('请填写证件号码') |
680 | return | 688 | return |
681 | } else if (this.data.taxperson_relativeData.selected.length < 1) { | 689 | } else if (this.data.taxperson_relativeData.selected.length < 1) { |
682 | this.showToast('请选择与纳税人关系') | 690 | this.showToast('请选择与纳税人关系') |
683 | return | 691 | return |
684 | - } else if (!formdata.total_money || formdata.reduce_money < 0) { | 692 | + } else if (!formdata.total_amount || formdata.total_amount < 0) { |
685 | this.showToast('请填写医疗支出总金额') | 693 | this.showToast('请填写医疗支出总金额') |
686 | return | 694 | return |
687 | - } else if (!formdata.personal_money || formdata.personal_money < 0) { | 695 | + } else if (!formdata.amount_by_person || formdata.amount_by_person < 0) { |
688 | this.showToast('请填写个人负担金额') | 696 | this.showToast('请填写个人负担金额') |
689 | return | 697 | return |
690 | } | 698 | } |
691 | - newdata.cardtype = this.data.cardtypeData.selected | ||
692 | - newdata.taxperson_relative = this.data.taxperson_relativeData.selected | 699 | + |
700 | + newdata.total_amount = parseFloat(formdata.total_amount) | ||
701 | + newdata.amount_by_person = parseFloat(formdata.amount_by_person) | ||
702 | + newdata.id_card_type = this.data.cardtypeData.selected | ||
703 | + newdata.relationship = this.data.taxperson_relativeData.selected | ||
693 | break; | 704 | break; |
694 | case 'house_fund': | 705 | case 'house_fund': |
706 | + // subUrl = 'persontax/v1/medical-funds' | ||
695 | console.log('TITLE', this.data.title) | 707 | console.log('TITLE', this.data.title) |
696 | if (!formdata.lover_name || formdata.lover_name.length < 1) { | 708 | if (!formdata.lover_name || formdata.lover_name.length < 1) { |
697 | this.showToast('请填写配偶姓名') | 709 | this.showToast('请填写配偶姓名') |
@@ -779,14 +791,16 @@ Page({ | @@ -779,14 +791,16 @@ Page({ | ||
779 | // this.showToast('请填写扣除金额') | 791 | // this.showToast('请填写扣除金额') |
780 | // return | 792 | // return |
781 | // } | 793 | // } |
782 | - newdata.deduction_type = this.data.reducetypeData.selected | ||
783 | - newdata.deduction_amount = this.data.deduction_amount//formdata.reduce_money | 794 | + if (this.data.cur_index != 'medical_fund'){ |
795 | + newdata.deduction_type = this.data.reducetypeData.selected | ||
796 | + newdata.deduction_amount = this.data.deduction_amount//formdata.reduce_money | ||
797 | + } | ||
784 | newdata.legal_entity_id = this.legal_entity_id | 798 | newdata.legal_entity_id = this.legal_entity_id |
785 | newdata.legal_entity = this.legal_entity | 799 | newdata.legal_entity = this.legal_entity |
786 | - this.addDatas(newdata) | 800 | + this.addDatas(newdata, subUrl) |
787 | }, | 801 | }, |
788 | 802 | ||
789 | - addDatas: function (newdata){ | 803 | + addDatas: function (newdata,subUrl){ |
790 | wx.showModal({ | 804 | wx.showModal({ |
791 | title: '确认要提交申报吗?', | 805 | title: '确认要提交申报吗?', |
792 | content: '确认后将不能修改', | 806 | content: '确认后将不能修改', |
@@ -798,7 +812,7 @@ Page({ | @@ -798,7 +812,7 @@ Page({ | ||
798 | var that = this; | 812 | var that = this; |
799 | var Authorization = app.globalData.Authorization; | 813 | var Authorization = app.globalData.Authorization; |
800 | wx.request({ | 814 | wx.request({ |
801 | - url: baseUrl + 'persontax/v1/children-educations', | 815 | + url: baseUrl + subUrl, |
802 | method: "POST", | 816 | method: "POST", |
803 | header: { | 817 | header: { |
804 | 'content-type': 'application/json', | 818 | 'content-type': 'application/json', |
@@ -138,28 +138,32 @@ | @@ -138,28 +138,32 @@ | ||
138 | <!-- 大病医疗 --> | 138 | <!-- 大病医疗 --> |
139 | <view wx:if="{{cur_index=='medical_fund'}}" style='padding:0 30rpx;'> | 139 | <view wx:if="{{cur_index=='medical_fund'}}" style='padding:0 30rpx;'> |
140 | <view style='height:90rpx'> | 140 | <view style='height:90rpx'> |
141 | + <text style='color:red;font-size: 30rpx;line-height: 90rpx;float:left'>*</text> | ||
141 | <text class='text_black_30 float_left'>姓名</text> | 142 | <text class='text_black_30 float_left'>姓名</text> |
142 | - <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入姓名' name='name'></input> | 143 | + <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入姓名' name='name' value='{{name}}'></input> |
143 | </view> | 144 | </view> |
144 | <view class='divide_line_f5f5f5'></view> | 145 | <view class='divide_line_f5f5f5'></view> |
145 | 146 | ||
146 | <template is="picker_cell_normal" data="{{...cardtypeData}}" /> | 147 | <template is="picker_cell_normal" data="{{...cardtypeData}}" /> |
147 | <view class='divide_line_f5f5f5'></view> | 148 | <view class='divide_line_f5f5f5'></view> |
148 | <view style='height:90rpx'> | 149 | <view style='height:90rpx'> |
150 | + <text style='color:red;font-size: 30rpx;line-height: 90rpx;float:left'>*</text> | ||
149 | <text class='text_black_30 float_left'>身份证件号码</text> | 151 | <text class='text_black_30 float_left'>身份证件号码</text> |
150 | - <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入身份证件号码' name='idno'></input> | 152 | + <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入身份证件号码' name='id_card_no' value='{{id_card_no}}'></input> |
151 | </view> | 153 | </view> |
152 | <view class='divide_line_f5f5f5'></view> | 154 | <view class='divide_line_f5f5f5'></view> |
153 | <template is="picker_cell_normal" data="{{...taxperson_relativeData}}" /> | 155 | <template is="picker_cell_normal" data="{{...taxperson_relativeData}}" /> |
154 | <view class='divide_line_f5f5f5'></view> | 156 | <view class='divide_line_f5f5f5'></view> |
155 | <view style='height:90rpx'> | 157 | <view style='height:90rpx'> |
158 | + <text style='color:red;font-size: 30rpx;line-height: 90rpx;float:left'>*</text> | ||
156 | <text class='text_black_30 float_left'>医疗支出总金额</text> | 159 | <text class='text_black_30 float_left'>医疗支出总金额</text> |
157 | - <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入总金额' type='digit' name='total_money'></input> | 160 | + <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入总金额' type='digit' name='total_amount' value='{{total_amount}}'></input> |
158 | </view> | 161 | </view> |
159 | <view class='divide_line_f5f5f5'></view> | 162 | <view class='divide_line_f5f5f5'></view> |
160 | <view style='height:90rpx'> | 163 | <view style='height:90rpx'> |
164 | + <text style='color:red;font-size: 30rpx;line-height: 90rpx;float:left'>*</text> | ||
161 | <text class='text_black_30 float_left'>个人负担金额</text> | 165 | <text class='text_black_30 float_left'>个人负担金额</text> |
162 | - <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入金额' type='digit' name='personal_money'></input> | 166 | + <input class='input_wrap float_right' placeholder-class='text_999_30 float_right' style='line-height: 90rpx;text-align: right' placeholder='请输入金额' type='digit' name='amount_by_person' value='{{total_amount}}'></input> |
163 | </view> | 167 | </view> |
164 | </view> | 168 | </view> |
165 | <!-- 住房 --> | 169 | <!-- 住房 --> |
@@ -220,7 +224,7 @@ | @@ -220,7 +224,7 @@ | ||
220 | </view> | 224 | </view> |
221 | </view> | 225 | </view> |
222 | 226 | ||
223 | - <view style='padding:0 30rpx;'> | 227 | + <view style='padding:0 30rpx;' wx:if="{{cur_index!='medical_fund'}}"> |
224 | <view class='divide_line_f5f5f5'></view> | 228 | <view class='divide_line_f5f5f5'></view> |
225 | <template is="picker_cell_normal" data="{{...reducetypeData}}" /> | 229 | <template is="picker_cell_normal" data="{{...reducetypeData}}" /> |
226 | <view class='divide_line_f5f5f5'></view> | 230 | <view class='divide_line_f5f5f5'></view> |
请
注册
或
登录
后发表评论