正在显示
18 个修改的文件
包含
506 行增加
和
265 行删除
1 | { | 1 | { |
2 | - "pages": [ | 2 | + "pages": [ |
3 | "pages/main/guide/guide", | 3 | "pages/main/guide/guide", |
4 | "pages/getPhone/getPhone", | 4 | "pages/getPhone/getPhone", |
5 | "pages/main/smartchat/chat", | 5 | "pages/main/smartchat/chat", |
@@ -26,7 +26,6 @@ | @@ -26,7 +26,6 @@ | ||
26 | 26 | ||
27 | "pages/main/finalpay/home", | 27 | "pages/main/finalpay/home", |
28 | "pages/main/finalpay/incomeDetail/incomeDetail", | 28 | "pages/main/finalpay/incomeDetail/incomeDetail", |
29 | - "pages/main/finalpay/incomeAddition/incomeAddition", | ||
30 | "pages/main/finalpay/addUnitInfo/addUnitInfo", | 29 | "pages/main/finalpay/addUnitInfo/addUnitInfo", |
31 | "pages/main/finalpay/refundInfo/refundInfo", | 30 | "pages/main/finalpay/refundInfo/refundInfo", |
32 | "pages/main/finalpay/refundDetail/refundDetail", | 31 | "pages/main/finalpay/refundDetail/refundDetail", |
1 | // pages/main/finalpay/addUnitInfo/addUnitInfo.js | 1 | // pages/main/finalpay/addUnitInfo/addUnitInfo.js |
2 | + | ||
3 | +var app = getApp(); | ||
4 | +var baseUrl = app.globalData.baseUrl; | ||
2 | Page({ | 5 | Page({ |
3 | 6 | ||
4 | 7 | ||
5 | data: { | 8 | data: { |
6 | - | 9 | + year: 2019, |
10 | + unit_id:"", | ||
7 | }, | 11 | }, |
8 | 12 | ||
9 | 13 | ||
10 | onLoad: function(options) { | 14 | onLoad: function(options) { |
11 | - | 15 | + this.setData({ |
16 | + unit_id:options.unit_id | ||
17 | + }) | ||
12 | }, | 18 | }, |
13 | 19 | ||
14 | 20 | ||
@@ -21,9 +27,48 @@ Page({ | @@ -21,9 +27,48 @@ Page({ | ||
21 | 27 | ||
22 | }, | 28 | }, |
23 | 29 | ||
24 | - formSubmit: function(e) {//提交 | 30 | + formSubmit: function(e) { //提交 |
25 | console.log("formSubmit", e); | 31 | console.log("formSubmit", e); |
26 | var formdata = e.detail.value | 32 | var formdata = e.detail.value |
33 | + if (formdata.total_salary || formdata.total_salary || formdata.remuneration_labor || formdata.author_payment || formdata.special_manage_cost || formdata.other_free_income || formdata.personal_endowment || formdata.personal_medical || formdata.personal_unemployment || formdata.personal_house_fund || formdata.childrens_education || formdata.continuing_education || formdata.housing_loan_interest || formdata.housing_rent || formdata.caring_old_people || formdata.serious_illness_medical || formdata.annuity || formdata.commercial_insurance || formdata.tax_extension || formdata.other_fee || formdata.donation_deducted || formdata.years_bouns || formdata.tax_savings || formdata.accumulated_withholding_tax){ | ||
34 | + this.submitRequest(formdata) | ||
35 | + }else{ | ||
36 | + this.showToast("请输入内容") | ||
37 | + return | ||
38 | + } | ||
39 | + }, | ||
40 | + | ||
41 | + submitRequest: function(request_data) { | ||
42 | + var that = this | ||
43 | + this.Authorization = getApp().globalData.Authorization; | ||
44 | + wx.request({ | ||
45 | + url: baseUrl + "payroll/v1/settlement-tax/record", | ||
46 | + header: { | ||
47 | + 'Authorization': this.Authorization | ||
48 | + }, | ||
49 | + method: "POST", | ||
50 | + data: { | ||
51 | + "declaring_unit_id":that.data.unit_id, | ||
52 | + "item": request_data, | ||
53 | + "years": that.data.year | ||
54 | + }, | ||
55 | + success: function(result) { | ||
56 | + console.log("refund", result) | ||
57 | + if (result.statusCode == 200) { | ||
58 | + that.showToast("提交成功!") | ||
59 | + } | ||
60 | + }, | ||
61 | + }) | ||
62 | + }, | ||
63 | + | ||
64 | + showToast: function(data) { | ||
65 | + if (data && data.length > 0) { | ||
66 | + wx.showToast({ | ||
67 | + title: data, | ||
68 | + icon: "none", | ||
69 | + duration: 2000 | ||
70 | + }) | ||
71 | + } | ||
27 | }, | 72 | }, |
28 | 73 | ||
29 | onHide: function() { | 74 | onHide: function() { |
@@ -11,22 +11,22 @@ | @@ -11,22 +11,22 @@ | ||
11 | <view class='divide_line_30'></view> | 11 | <view class='divide_line_30'></view> |
12 | <view style="height:104rpx;padding:0 30rpx"> | 12 | <view style="height:104rpx;padding:0 30rpx"> |
13 | <text class="text_gray7_34" style="line-height:104rpx">工资薪金收入</text> | 13 | <text class="text_gray7_34" style="line-height:104rpx">工资薪金收入</text> |
14 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='total_salary'></input> | 14 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='total_salary'></input> |
15 | </view> | 15 | </view> |
16 | <view class='divide_line_30'></view> | 16 | <view class='divide_line_30'></view> |
17 | <view style="height:104rpx;padding:0 30rpx"> | 17 | <view style="height:104rpx;padding:0 30rpx"> |
18 | <text class="text_gray7_34" style="line-height:104rpx">劳务报酬收入</text> | 18 | <text class="text_gray7_34" style="line-height:104rpx">劳务报酬收入</text> |
19 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='remuneration_labor'></input> | 19 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='remuneration_labor'></input> |
20 | </view> | 20 | </view> |
21 | <view class='divide_line_30'></view> | 21 | <view class='divide_line_30'></view> |
22 | <view style="height:104rpx;padding:0 30rpx"> | 22 | <view style="height:104rpx;padding:0 30rpx"> |
23 | <text class="text_gray7_34" style="line-height:104rpx">稿酬收入</text> | 23 | <text class="text_gray7_34" style="line-height:104rpx">稿酬收入</text> |
24 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='author_payment'></input> | 24 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='author_payment'></input> |
25 | </view> | 25 | </view> |
26 | <view class='divide_line_30'></view> | 26 | <view class='divide_line_30'></view> |
27 | <view style="height:104rpx;padding:0 30rpx"> | 27 | <view style="height:104rpx;padding:0 30rpx"> |
28 | <text class="text_gray7_34" style="line-height:104rpx">特许经营权</text> | 28 | <text class="text_gray7_34" style="line-height:104rpx">特许经营权</text> |
29 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='special_manage_cost'></input> | 29 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='special_manage_cost'></input> |
30 | </view> | 30 | </view> |
31 | </view> | 31 | </view> |
32 | <!-- 免税收入 --> | 32 | <!-- 免税收入 --> |
@@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
37 | <view class='divide_line_30'></view> | 37 | <view class='divide_line_30'></view> |
38 | <view style="height:104rpx;padding:0 30rpx"> | 38 | <view style="height:104rpx;padding:0 30rpx"> |
39 | <text class="text_gray7_34" style="line-height:104rpx">其他免税收入</text> | 39 | <text class="text_gray7_34" style="line-height:104rpx">其他免税收入</text> |
40 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='other_free_income'></input> | 40 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='other_free_income'></input> |
41 | </view> | 41 | </view> |
42 | </view> | 42 | </view> |
43 | <!-- 专项扣除 --> | 43 | <!-- 专项扣除 --> |
@@ -48,22 +48,22 @@ | @@ -48,22 +48,22 @@ | ||
48 | <view class='divide_line_30'></view> | 48 | <view class='divide_line_30'></view> |
49 | <view style="height:104rpx;padding:0 30rpx"> | 49 | <view style="height:104rpx;padding:0 30rpx"> |
50 | <text class="text_gray7_34" style="line-height:104rpx">养老保险</text> | 50 | <text class="text_gray7_34" style="line-height:104rpx">养老保险</text> |
51 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='personal_endowment'></input> | 51 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='personal_endowment'></input> |
52 | </view> | 52 | </view> |
53 | <view class='divide_line_30'></view> | 53 | <view class='divide_line_30'></view> |
54 | <view style="height:104rpx;padding:0 30rpx"> | 54 | <view style="height:104rpx;padding:0 30rpx"> |
55 | <text class="text_gray7_34" style="line-height:104rpx">医疗保险</text> | 55 | <text class="text_gray7_34" style="line-height:104rpx">医疗保险</text> |
56 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='personal_medical'></input> | 56 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='personal_medical'></input> |
57 | </view> | 57 | </view> |
58 | <view class='divide_line_30'></view> | 58 | <view class='divide_line_30'></view> |
59 | <view style="height:104rpx;padding:0 30rpx"> | 59 | <view style="height:104rpx;padding:0 30rpx"> |
60 | <text class="text_gray7_34" style="line-height:104rpx">失业保险</text> | 60 | <text class="text_gray7_34" style="line-height:104rpx">失业保险</text> |
61 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='personal_unemployment'></input> | 61 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='personal_unemployment'></input> |
62 | </view> | 62 | </view> |
63 | <view class='divide_line_30'></view> | 63 | <view class='divide_line_30'></view> |
64 | <view style="height:104rpx;padding:0 30rpx"> | 64 | <view style="height:104rpx;padding:0 30rpx"> |
65 | <text class="text_gray7_34" style="line-height:104rpx">住房公积金</text> | 65 | <text class="text_gray7_34" style="line-height:104rpx">住房公积金</text> |
66 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='personal_house_fund'></input> | 66 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='personal_house_fund'></input> |
67 | </view> | 67 | </view> |
68 | </view> | 68 | </view> |
69 | <!-- 专项附加扣除 --> | 69 | <!-- 专项附加扣除 --> |
@@ -74,32 +74,32 @@ | @@ -74,32 +74,32 @@ | ||
74 | <view class='divide_line_30'></view> | 74 | <view class='divide_line_30'></view> |
75 | <view style="height:104rpx;padding:0 30rpx"> | 75 | <view style="height:104rpx;padding:0 30rpx"> |
76 | <text class="text_gray7_34" style="line-height:104rpx">子女教育</text> | 76 | <text class="text_gray7_34" style="line-height:104rpx">子女教育</text> |
77 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='childrens_education'></input> | 77 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='childrens_education'></input> |
78 | </view> | 78 | </view> |
79 | <view class='divide_line_30'></view> | 79 | <view class='divide_line_30'></view> |
80 | <view style="height:104rpx;padding:0 30rpx"> | 80 | <view style="height:104rpx;padding:0 30rpx"> |
81 | <text class="text_gray7_34" style="line-height:104rpx">继续教育</text> | 81 | <text class="text_gray7_34" style="line-height:104rpx">继续教育</text> |
82 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='continuing_education'></input> | 82 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='continuing_education'></input> |
83 | </view> | 83 | </view> |
84 | <view class='divide_line_30'></view> | 84 | <view class='divide_line_30'></view> |
85 | <view style="height:104rpx;padding:0 30rpx"> | 85 | <view style="height:104rpx;padding:0 30rpx"> |
86 | <text class="text_gray7_34" style="line-height:104rpx">住房贷款利息</text> | 86 | <text class="text_gray7_34" style="line-height:104rpx">住房贷款利息</text> |
87 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='housing_loan_interest'></input> | 87 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='housing_loan_interest'></input> |
88 | </view> | 88 | </view> |
89 | <view class='divide_line_30'></view> | 89 | <view class='divide_line_30'></view> |
90 | <view style="height:104rpx;padding:0 30rpx"> | 90 | <view style="height:104rpx;padding:0 30rpx"> |
91 | <text class="text_gray7_34" style="line-height:104rpx">住房租金</text> | 91 | <text class="text_gray7_34" style="line-height:104rpx">住房租金</text> |
92 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='housing_rent'></input> | 92 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='housing_rent'></input> |
93 | </view> | 93 | </view> |
94 | <view class='divide_line_30'></view> | 94 | <view class='divide_line_30'></view> |
95 | <view style="height:104rpx;padding:0 30rpx"> | 95 | <view style="height:104rpx;padding:0 30rpx"> |
96 | <text class="text_gray7_34" style="line-height:104rpx">赡养老人</text> | 96 | <text class="text_gray7_34" style="line-height:104rpx">赡养老人</text> |
97 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='caring_old_people'></input> | 97 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='caring_old_people'></input> |
98 | </view> | 98 | </view> |
99 | <view class='divide_line_30'></view> | 99 | <view class='divide_line_30'></view> |
100 | <view style="height:104rpx;padding:0 30rpx"> | 100 | <view style="height:104rpx;padding:0 30rpx"> |
101 | <text class="text_gray7_34" style="line-height:104rpx">大病医疗</text> | 101 | <text class="text_gray7_34" style="line-height:104rpx">大病医疗</text> |
102 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='serious_illness_medical'></input> | 102 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='serious_illness_medical'></input> |
103 | </view> | 103 | </view> |
104 | </view> | 104 | </view> |
105 | <!-- 其他扣除 --> | 105 | <!-- 其他扣除 --> |
@@ -110,22 +110,22 @@ | @@ -110,22 +110,22 @@ | ||
110 | <view class='divide_line_30'></view> | 110 | <view class='divide_line_30'></view> |
111 | <view style="height:104rpx;padding:0 30rpx"> | 111 | <view style="height:104rpx;padding:0 30rpx"> |
112 | <text class="text_gray7_34" style="line-height:104rpx">年金</text> | 112 | <text class="text_gray7_34" style="line-height:104rpx">年金</text> |
113 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='annuity'></input> | 113 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='annuity'></input> |
114 | </view> | 114 | </view> |
115 | <view class='divide_line_30'></view> | 115 | <view class='divide_line_30'></view> |
116 | <view style="height:104rpx;padding:0 30rpx"> | 116 | <view style="height:104rpx;padding:0 30rpx"> |
117 | <text class="text_gray7_34" style="line-height:104rpx">商业健康保险</text> | 117 | <text class="text_gray7_34" style="line-height:104rpx">商业健康保险</text> |
118 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='commercial_insurance'></input> | 118 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='commercial_insurance'></input> |
119 | </view> | 119 | </view> |
120 | <view class='divide_line_30'></view> | 120 | <view class='divide_line_30'></view> |
121 | <view style="height:104rpx;padding:0 30rpx"> | 121 | <view style="height:104rpx;padding:0 30rpx"> |
122 | <text class="text_gray7_34" style="line-height:104rpx">税延养老保险</text> | 122 | <text class="text_gray7_34" style="line-height:104rpx">税延养老保险</text> |
123 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='tax_extension'></input> | 123 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='tax_extension'></input> |
124 | </view> | 124 | </view> |
125 | <view class='divide_line_30'></view> | 125 | <view class='divide_line_30'></view> |
126 | <view style="height:104rpx;padding:0 30rpx"> | 126 | <view style="height:104rpx;padding:0 30rpx"> |
127 | <text class="text_gray7_34" style="line-height:104rpx">其他</text> | 127 | <text class="text_gray7_34" style="line-height:104rpx">其他</text> |
128 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='other_fee'></input> | 128 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='other_fee'></input> |
129 | </view> | 129 | </view> |
130 | </view> | 130 | </view> |
131 | <!-- 捐赠扣除 --> | 131 | <!-- 捐赠扣除 --> |
@@ -136,12 +136,12 @@ | @@ -136,12 +136,12 @@ | ||
136 | <view class='divide_line_30'></view> | 136 | <view class='divide_line_30'></view> |
137 | <view style="height:104rpx;padding:0 30rpx"> | 137 | <view style="height:104rpx;padding:0 30rpx"> |
138 | <text class="text_gray7_34" style="line-height:104rpx">准予扣除的捐赠额</text> | 138 | <text class="text_gray7_34" style="line-height:104rpx">准予扣除的捐赠额</text> |
139 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='donation_deducted'></input> | 139 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='donation_deducted'></input> |
140 | </view> | 140 | </view> |
141 | <view class='divide_line_30'></view> | 141 | <view class='divide_line_30'></view> |
142 | <view style="height:104rpx;padding:0 30rpx"> | 142 | <view style="height:104rpx;padding:0 30rpx"> |
143 | <text class="text_gray7_34" style="line-height:104rpx">全年一次性奖金</text> | 143 | <text class="text_gray7_34" style="line-height:104rpx">全年一次性奖金</text> |
144 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='years_bouns'></input> | 144 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='years_bouns'></input> |
145 | </view> | 145 | </view> |
146 | </view> | 146 | </view> |
147 | <!-- 减免/已缴纳税额 --> | 147 | <!-- 减免/已缴纳税额 --> |
@@ -152,12 +152,12 @@ | @@ -152,12 +152,12 @@ | ||
152 | <view class='divide_line_30'></view> | 152 | <view class='divide_line_30'></view> |
153 | <view style="height:104rpx;padding:0 30rpx"> | 153 | <view style="height:104rpx;padding:0 30rpx"> |
154 | <text class="text_gray7_34" style="line-height:104rpx">减免税额</text> | 154 | <text class="text_gray7_34" style="line-height:104rpx">减免税额</text> |
155 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='tax_savings'></input> | 155 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='tax_savings'></input> |
156 | </view> | 156 | </view> |
157 | <view class='divide_line_30'></view> | 157 | <view class='divide_line_30'></view> |
158 | <view style="height:104rpx;padding:0 30rpx"> | 158 | <view style="height:104rpx;padding:0 30rpx"> |
159 | <text class="text_gray7_34" style="line-height:104rpx">已缴税额</text> | 159 | <text class="text_gray7_34" style="line-height:104rpx">已缴税额</text> |
160 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='accumulated_withholding_tax'></input> | 160 | + <input class='input_wrap' style='text-align: right;color:#000;' type="digit" placeholder='请输入' name='accumulated_withholding_tax'></input> |
161 | </view> | 161 | </view> |
162 | </view> | 162 | </view> |
163 | </view> | 163 | </view> |
1 | // pages/main/finalpay/home.js | 1 | // pages/main/finalpay/home.js |
2 | var app = getApp(); | 2 | var app = getApp(); |
3 | var baseUrl = app.globalData.baseUrl; | 3 | var baseUrl = app.globalData.baseUrl; |
4 | +var format = require('../../../utils/util.js'); | ||
4 | Page({ | 5 | Page({ |
5 | 6 | ||
6 | 7 | ||
7 | data: { | 8 | data: { |
8 | - declare_status: "",//申报状态"0" //待申报 "1" //申报成功 | ||
9 | - refund_status: "",//退税状态 "0" 无需退税; "1" 待退税;"2" 退税中;"3" 退税成功;"4"退税失败;"5"放弃退税 | ||
10 | - pay_status: "",//补税状态 "0" 无需补税; "1" 待补税;"2" 补税成功 | ||
11 | - declaring_unit_status: "4",//1:本单位申报,2:本单位其他申报,3:其他单位申报,4:待确认申报//用户自行申报 | ||
12 | - payinfo:{}, | 9 | + year: "2019", |
10 | + declare_status: "", //申报状态"0" //待申报 "1" //申报成功 | ||
11 | + refund_status: "", //退税状态 "0" 无需退税; "1" 待退税;"2" 退税中;"3" 退税成功;"4"退税失败;"5"放弃退税 | ||
12 | + pay_status: "", //补税状态 "0" 无需补税; "1" 待补税;"2" 补税成功 | ||
13 | + declaring_unit_status: "", //1:本单位申报,2:本单位其他申报,3:其他单位申报,4:待确认申报//用户自行申报 | ||
14 | + payinfo: {}, | ||
13 | unitInfo: [], | 15 | unitInfo: [], |
14 | - showUnit:false, | ||
15 | - declaring_unit_id:"", | ||
16 | - showModal_selfDeclare:false, | ||
17 | - declare_status_arr:["待申报","申报成功"], | ||
18 | - refund_status_arr: ["待退税", "退税中", "退税成功", "退税失败","放弃退税"], | ||
19 | - pay_status_arr: ["无需补税", "待补税","补税成功"], | 16 | + showUnit: false, |
17 | + declaring_unit_id: "", | ||
18 | + showModal_selfDeclare: false, | ||
19 | + uniqual_title01:"", | ||
20 | + new_refund_tax:0, | ||
21 | + declare_end_date:"", | ||
22 | + declare_end_days: 0, | ||
23 | + show_other_unit_view:false, | ||
20 | }, | 24 | }, |
21 | 25 | ||
22 | 26 | ||
@@ -38,7 +42,7 @@ Page({ | @@ -38,7 +42,7 @@ Page({ | ||
38 | 42 | ||
39 | }, | 43 | }, |
40 | 44 | ||
41 | - getPayInfo:function(){ | 45 | + getPayInfo: function() { |
42 | var that = this | 46 | var that = this |
43 | this.Authorization = getApp().globalData.Authorization; | 47 | this.Authorization = getApp().globalData.Authorization; |
44 | wx.request({ | 48 | wx.request({ |
@@ -46,11 +50,29 @@ Page({ | @@ -46,11 +50,29 @@ Page({ | ||
46 | header: { | 50 | header: { |
47 | 'Authorization': this.Authorization | 51 | 'Authorization': this.Authorization |
48 | }, | 52 | }, |
49 | - data: { 'years': '2019' }, | ||
50 | - success: function (result) { | ||
51 | - console.log("payinfo",result) | ||
52 | - if (result.statusCode==200) { | 53 | + data: { |
54 | + 'years': that.data.year | ||
55 | + }, | ||
56 | + success: function(result) { | ||
57 | + console.log("payinfo", result) | ||
58 | + var text01="应补退税额" | ||
59 | + if (result.statusCode == 200) { | ||
60 | + if (that.data.declare_status=='1'){//申报成功 | ||
61 | + if (result.data.refund_tax > 0 || result.data.refund_tax == 0){ | ||
62 | + text01="应补税额" | ||
63 | + } else { | ||
64 | + text01 = "应退税额" | ||
65 | + } | ||
66 | + } | ||
53 | that.setData({ | 67 | that.setData({ |
68 | + declare_status: result.data.declare_status, | ||
69 | + refund_status: result.data.refund_status, | ||
70 | + pay_status: result.data.pay_status, | ||
71 | + declaring_unit_status: result.data.declaring_unit_status, | ||
72 | + new_refund_tax: Math.abs(result.data.refund_tax), | ||
73 | + uniqual_title01:text01, | ||
74 | + declare_end_date: format.yearFormString(result.data.declare_end_time) + "年" + format.monthFormString(result.data.declare_end_time) + "月" + format.dayFormString(result.data.declare_end_time) + "日", | ||
75 | + declare_end_days: format.daysTillNow(Date.parse(new Date())/1000,result.data.declare_end_time), | ||
54 | payinfo: result.data | 76 | payinfo: result.data |
55 | }) | 77 | }) |
56 | } | 78 | } |
@@ -58,7 +80,7 @@ Page({ | @@ -58,7 +80,7 @@ Page({ | ||
58 | }) | 80 | }) |
59 | }, | 81 | }, |
60 | 82 | ||
61 | - getUnitInfo:function(){//获取申报单位 | 83 | + getUnitInfo: function() { //获取申报单位 |
62 | var that = this | 84 | var that = this |
63 | this.Authorization = getApp().globalData.Authorization; | 85 | this.Authorization = getApp().globalData.Authorization; |
64 | that.setData({ | 86 | that.setData({ |
@@ -69,8 +91,8 @@ Page({ | @@ -69,8 +91,8 @@ Page({ | ||
69 | header: { | 91 | header: { |
70 | 'Authorization': this.Authorization | 92 | 'Authorization': this.Authorization |
71 | }, | 93 | }, |
72 | - data: { }, | ||
73 | - success: function (result) { | 94 | + data: {}, |
95 | + success: function(result) { | ||
74 | console.log("unitInfo", result.data) | 96 | console.log("unitInfo", result.data) |
75 | if (result.statusCode == 200) { | 97 | if (result.statusCode == 200) { |
76 | that.setData({ | 98 | that.setData({ |
@@ -78,15 +100,15 @@ Page({ | @@ -78,15 +100,15 @@ Page({ | ||
78 | }) | 100 | }) |
79 | } | 101 | } |
80 | }, | 102 | }, |
81 | - complete:function(e){ | 103 | + complete: function(e) { |
82 | that.setData({ | 104 | that.setData({ |
83 | - showUnit:true | 105 | + showUnit: true |
84 | }) | 106 | }) |
85 | } | 107 | } |
86 | }) | 108 | }) |
87 | }, | 109 | }, |
88 | 110 | ||
89 | - updateDeclareState: function (id) {//是否在本单位申报 | 111 | + updateDeclareState: function(id) { //是否在本单位申报 |
90 | var that = this | 112 | var that = this |
91 | this.Authorization = getApp().globalData.Authorization; | 113 | this.Authorization = getApp().globalData.Authorization; |
92 | wx.request({ | 114 | wx.request({ |
@@ -94,20 +116,26 @@ Page({ | @@ -94,20 +116,26 @@ Page({ | ||
94 | header: { | 116 | header: { |
95 | 'Authorization': this.Authorization | 117 | 'Authorization': this.Authorization |
96 | }, | 118 | }, |
97 | - data: { 'declaring_unit_id': id }, | ||
98 | - success: function (result) { | 119 | + method: "PUT", |
120 | + data: { | ||
121 | + "years":that.data.year, | ||
122 | + 'declaring_unit_id': id, | ||
123 | + "declaring_unit_status": id?'':'5', | ||
124 | + }, | ||
125 | + success: function(result) { | ||
99 | console.log("declareinfo", result) | 126 | console.log("declareinfo", result) |
100 | if (result.statusCode == 200) { | 127 | if (result.statusCode == 200) { |
101 | that.setData({ | 128 | that.setData({ |
102 | - | 129 | + |
103 | }) | 130 | }) |
131 | + that.getPayInfo(); | ||
104 | } | 132 | } |
105 | }, | 133 | }, |
106 | }) | 134 | }) |
107 | }, | 135 | }, |
108 | 136 | ||
109 | // 是否放弃退税,(是:"5",否:"") | 137 | // 是否放弃退税,(是:"5",否:"") |
110 | - forgiveRefund: function () { | 138 | + forgiveRefund: function(s) { |
111 | var that = this | 139 | var that = this |
112 | this.Authorization = getApp().globalData.Authorization; | 140 | this.Authorization = getApp().globalData.Authorization; |
113 | wx.request({ | 141 | wx.request({ |
@@ -115,10 +143,15 @@ Page({ | @@ -115,10 +143,15 @@ Page({ | ||
115 | header: { | 143 | header: { |
116 | 'Authorization': this.Authorization | 144 | 'Authorization': this.Authorization |
117 | }, | 145 | }, |
118 | - data: { 'refund_status': '' }, | ||
119 | - success: function (result) { | 146 | + method: "PUT", |
147 | + data: { | ||
148 | + "years": that.data.year, | ||
149 | + 'refund_status': '' | ||
150 | + }, | ||
151 | + success: function(result) { | ||
120 | console.log("refund", result) | 152 | console.log("refund", result) |
121 | if (result.statusCode == 200) { | 153 | if (result.statusCode == 200) { |
154 | + that.getPayInfo(); | ||
122 | that.setData({ | 155 | that.setData({ |
123 | 156 | ||
124 | }) | 157 | }) |
@@ -128,7 +161,7 @@ Page({ | @@ -128,7 +161,7 @@ Page({ | ||
128 | }, | 161 | }, |
129 | 162 | ||
130 | // 确认提交申请退税 | 163 | // 确认提交申请退税 |
131 | - forgiveRefund: function () { | 164 | + commitRefund: function() { |
132 | var that = this | 165 | var that = this |
133 | this.Authorization = getApp().globalData.Authorization; | 166 | this.Authorization = getApp().globalData.Authorization; |
134 | wx.request({ | 167 | wx.request({ |
@@ -136,13 +169,15 @@ Page({ | @@ -136,13 +169,15 @@ Page({ | ||
136 | header: { | 169 | header: { |
137 | 'Authorization': this.Authorization | 170 | 'Authorization': this.Authorization |
138 | }, | 171 | }, |
172 | + method: "PUT", | ||
139 | data: { | 173 | data: { |
140 | - "name": "xxxx", //姓名, | ||
141 | - "bank": "xxxx", //开户行, | ||
142 | - "bank_card_no": "xxxx", //银行卡号, | ||
143 | - "bank_province": "xxxx", //银行省份, | 174 | + "years": that.data.year, |
175 | + "name": "xxxx", //姓名, | ||
176 | + "bank": "xxxx", //开户行, | ||
177 | + "bank_card_no": "xxxx", //银行卡号, | ||
178 | + "bank_province": "xxxx", //银行省份, | ||
144 | }, | 179 | }, |
145 | - success: function (result) { | 180 | + success: function(result) { |
146 | console.log("refund", result) | 181 | console.log("refund", result) |
147 | if (result.statusCode == 200) { | 182 | if (result.statusCode == 200) { |
148 | that.setData({ | 183 | that.setData({ |
@@ -167,7 +202,7 @@ Page({ | @@ -167,7 +202,7 @@ Page({ | ||
167 | }) | 202 | }) |
168 | }, | 203 | }, |
169 | 204 | ||
170 | - finalpay_detail: function() { | 205 | + finalpay_detail: function() {// |
171 | wx.navigateTo({ | 206 | wx.navigateTo({ |
172 | url: 'incomeDetail/incomeDetail', | 207 | url: 'incomeDetail/incomeDetail', |
173 | }) | 208 | }) |
@@ -194,51 +229,71 @@ Page({ | @@ -194,51 +229,71 @@ Page({ | ||
194 | }) | 229 | }) |
195 | }, | 230 | }, |
196 | 231 | ||
197 | - unitPick:function(e){//选择申报单位 | ||
198 | - console.log("unitPick",e) | 232 | + unitPick: function(e) { //选择申报单位 |
233 | + console.log("unitPick", e) | ||
199 | this.setData({ | 234 | this.setData({ |
200 | declaring_unit_id: e.currentTarget.id, | 235 | declaring_unit_id: e.currentTarget.id, |
201 | - showUnit: false | 236 | + showUnit: false, |
237 | + show_other_unit_view:true, | ||
202 | }) | 238 | }) |
203 | - this.updateDeclareState(e.currentTarget.id) | ||
204 | }, | 239 | }, |
205 | 240 | ||
206 | - selfdeclare_close(){//关闭自行申报弹窗 | 241 | + selfdeclare_close() { //关闭自行申报弹窗 |
207 | this.setData({ | 242 | this.setData({ |
208 | showModal_selfDeclare: false | 243 | showModal_selfDeclare: false |
209 | }) | 244 | }) |
210 | }, | 245 | }, |
211 | 246 | ||
212 | - declareBySelf:function(){//查看自行申报方式 | 247 | + declareBySelf: function() { //查看自行申报方式 |
213 | this.setData({ | 248 | this.setData({ |
214 | showModal_selfDeclare: true | 249 | showModal_selfDeclare: true |
215 | }) | 250 | }) |
216 | }, | 251 | }, |
217 | 252 | ||
218 | - godeclareHistory:function(){ | 253 | + godeclareHistory: function() { |
219 | wx.redirectTo({ | 254 | wx.redirectTo({ |
220 | url: '../advancepayment/adPayHome', | 255 | url: '../advancepayment/adPayHome', |
221 | }) | 256 | }) |
222 | }, | 257 | }, |
223 | 258 | ||
224 | - noOtherUnitInfo:function(){//没有其他单位个税申报 | ||
225 | - | 259 | + noOtherUnitInfo: function() { //没有其他单位个税申报 |
260 | + this.updateDeclareState(e.currentTarget.id) | ||
261 | + this.setData({ | ||
262 | + show_other_unit_view:false | ||
263 | + }) | ||
226 | }, | 264 | }, |
227 | 265 | ||
228 | - otherUnitInfo: function () {//有其他单位个税申报 | 266 | + otherUnitInfo: function() { //有其他单位个税申报 |
229 | wx.navigateTo({ | 267 | wx.navigateTo({ |
230 | - url: 'addUnitInfo/addUnitInfo', | 268 | + url: 'addUnitInfo/addUnitInfo?unit_id='+this.data.declaring_unit_id, |
269 | + }) | ||
270 | + this.setData({ | ||
271 | + show_other_unit_view: false | ||
231 | }) | 272 | }) |
232 | }, | 273 | }, |
233 | 274 | ||
234 | -// 申请退税 | ||
235 | - doRefund:function(){ | ||
236 | - | 275 | + // 申请退税 |
276 | + doRefund: function() { | ||
277 | + wx.navigateTo({ | ||
278 | + url: 'refundInfo/refundInfo', | ||
279 | + }) | ||
237 | }, | 280 | }, |
238 | 281 | ||
239 | -// 放弃退税 | ||
240 | - doNotRefund:function(){ | ||
241 | - | 282 | + // 放弃退税 |
283 | + doNotRefund: function() { | ||
284 | + wx.showModal({ | ||
285 | + title: '确认放弃退税吗?', | ||
286 | + content: '', | ||
287 | + confirmColor: '#357aeb', | ||
288 | + success(res) { | ||
289 | + if (res.confirm) { | ||
290 | + console.log('用户点击确定') | ||
291 | + this.forgiveRefund("5") | ||
292 | + } else if (res.cancel) { | ||
293 | + console.log('用户点击取消') | ||
294 | + } | ||
295 | + } | ||
296 | + }) | ||
242 | }, | 297 | }, |
243 | 298 | ||
244 | onHide: function() { | 299 | onHide: function() { |
@@ -4,72 +4,82 @@ | @@ -4,72 +4,82 @@ | ||
4 | <view wx:if="{{!showUnit}}"> | 4 | <view wx:if="{{!showUnit}}"> |
5 | <view style="background:#fff;padding:28rpx" bindtap="yearPick"> | 5 | <view style="background:#fff;padding:28rpx" bindtap="yearPick"> |
6 | <text class="text_black_bold">2019年度个人综合所得汇算清缴</text> | 6 | <text class="text_black_bold">2019年度个人综合所得汇算清缴</text> |
7 | - <view class="float_right"> | 7 | + <view wx:if="{{year>2020}}" class="float_right"> |
8 | <image class="arrow_wrap" src="/images/arrow_down.png"></image> | 8 | <image class="arrow_wrap" src="/images/arrow_down.png"></image> |
9 | </view> | 9 | </view> |
10 | </view> | 10 | </view> |
11 | - | ||
12 | - <view style="background:#fff;padding:30rpx 30rpx 50rpx 30rpx;margin-top:20rpx"> | ||
13 | - <text class="text_gray3_26">了解汇算清缴具体内容,请阅读 </text> | ||
14 | - <text class="text_blue_26" bindtap="skipH5_01"> 《2019年度汇算清缴事项公告》 </text> | ||
15 | - <text class="text_blue_26" bindtap="skipH5_02"> 《国家税务总局办理2019年度个人所得税综合所得汇算清缴事项的公告 》</text> | ||
16 | - <text class="text_blue_26"> 的解读 </text> | ||
17 | - </view> | ||
18 | - | ||
19 | - <view style="background:#fff9f0;padding:24rpx;display: flex;"> | ||
20 | - <view style="margin-right:12rpx"> | ||
21 | - <image style="width:28rpx;height:28rpx;" src="/images/warn_yellow.png"></image> | ||
22 | - </view> | ||
23 | - <view wx:if="{{declaring_unit_status=='4'}}"> | ||
24 | - <text class="text_gray6_28">请于 </text> | ||
25 | - <text class="text_yellow_28"> 2020年10月1日前 </text> | ||
26 | - <text class="text_gray6_28">确认是否在本单位进行汇算清缴,否则默认为您在其他单位申报或自行申报。 </text> | ||
27 | - </view> | ||
28 | - <view wx:elif="{{declaring_unit_status=='5'}}"> | ||
29 | - <text class="text_gray6_28">您已选择自行申报,可继续查看在本单位的个税申报记录 </text> | ||
30 | - </view> | ||
31 | - <view wx:else> | ||
32 | - <text class="text_gray6_28">您将在 北京小爱智能科技有限公司 完成2019年度的个人综合所得汇算清缴。 </text> | 11 | + <scroll-view style="margin-bottom: 360rpx;"> |
12 | + <view style="background:#fff;padding:30rpx 30rpx 50rpx 30rpx;margin-top:20rpx"> | ||
13 | + <text class="text_gray3_26">了解汇算清缴具体内容,请阅读 </text> | ||
14 | + <text class="text_blue_26" bindtap="skipH5_01"> 《2019年度汇算清缴事项公告》 </text> | ||
15 | + <text class="text_blue_26" bindtap="skipH5_02"> 《国家税务总局办理2019年度个人所得税综合所得汇算清缴事项的公告 》</text> | ||
16 | + <text class="text_blue_26"> 的解读 </text> | ||
33 | </view> | 17 | </view> |
34 | - </view> | ||
35 | 18 | ||
36 | - <view wx:if="{{declaring_unit_status!='4'&&declaring_unit_status!='5'}}" style="background:#fff;padding:0 30rpx"> | ||
37 | - <text class="text_black_bold" style="margin-top:30rpx">汇算清缴申报中…</text> | ||
38 | - <view style="display: flex;margin:20rpx 0"> | ||
39 | - <image style="width:28rpx;height:28rpx;margin-right:12rpx;margin-top:4rpx" src="/images/warn_yellow.png"></image> | ||
40 | - <text class="text_gray6_28">请等候申报结果 </text> | ||
41 | - </view> | ||
42 | - <view class="divide_line_f5f5f5"></view> | ||
43 | - <view style="margin-top:20rpx"> | ||
44 | - <text class="text_gray6_28">收入总额:</text> | ||
45 | - <text class="text_gray3_28 float_right" style="line-height:50rpx">¥12939</text> | ||
46 | - </view> | ||
47 | - <view class="view_gray_bg" style="padding:16rpx 20rpx;flex-direction: column"> | ||
48 | - <view class="text_gray9_26">其中本单位收入额:</view> | ||
49 | - <text class="text_gray9_26">其中其他单位收入额:</text> | ||
50 | - </view> | ||
51 | - <view style="margin:20rpx 0"> | ||
52 | - <text class="text_gray6_28">累计应纳税额:</text> | ||
53 | - <text class="text_gray3_28 float_right" style="line-height:50rpx">¥12939</text> | ||
54 | - </view> | ||
55 | - <view class="divide_line_f5f5f5"></view> | ||
56 | - <view style="margin:20rpx 0"> | ||
57 | - <text class="text_gray6_28">已缴费税额:</text> | ||
58 | - <text class="text_gray3_28 float_right" style="line-height:50rpx">¥12939</text> | ||
59 | - </view> | ||
60 | - <view class="divide_line_f5f5f5"></view> | ||
61 | - <view style="margin:20rpx 0"> | ||
62 | - <text class="text_black_bold">应补退税额:</text> | ||
63 | - <text class="text_gray3_28 float_right" style="line-height:50rpx">¥12939</text> | ||
64 | - </view> | ||
65 | - <view class="divide_line_f5f5f5"></view> | ||
66 | - <text class="text_blue_28 float_right" style="line-height:50rpx" bindtap="finalpay_detail">查看详情</text> | ||
67 | - </view> | 19 | + <view style="background:#fff9f0;padding:24rpx;display: flex;"> |
20 | + <view style="margin-right:12rpx"> | ||
21 | + <image style="width:28rpx;height:28rpx;" src="/images/warn_yellow.png"></image> | ||
22 | + </view> | ||
23 | + <view wx:if="{{declaring_unit_status=='4'}}"> | ||
24 | + <text class="text_gray6_28">请于 </text> | ||
25 | + <text class="text_yellow_28"> {{declare_end_date}}前 </text> | ||
26 | + <text class="text_gray6_28">确认是否在本单位进行汇算清缴,否则默认为您在其他单位申报或自行申报。 </text> | ||
27 | + </view> | ||
28 | + <view wx:elif="{{declaring_unit_status=='5'}}"> | ||
29 | + <text class="text_gray6_28">您已选择自行申报,可继续查看在本单位的个税申报记录 </text> | ||
30 | + </view> | ||
31 | + <view wx:else> | ||
32 | + <text class="text_gray6_28">您选择在 北京小爱智能科技有限公司 完成2019年度的个人综合所得汇算清缴。 </text> | ||
33 | + </view> | ||
34 | + </view> | ||
68 | 35 | ||
69 | - <view wx:if="{{declaring_unit_status=='4'}}" style="width:100%;height:300rpx;position: fixed;bottom: 0;"> | ||
70 | - <view style="display: flex;justify-content: center;"> | 36 | + <view wx:if="{{declaring_unit_status!='4'&&declaring_unit_status!='5'&&!show_other_unit_view}}" style="background:#fff;padding:30rpx 30rpx 50rpx 30rpx;"> |
37 | + <text class="text_black_bold">{{declare_status=='0'?'汇算清缴申报中…':'汇算清缴申报完成!'}}</text> | ||
38 | + <view style="display: flex;margin:20rpx 0"> | ||
39 | + <image style="width:28rpx;height:28rpx;margin-right:12rpx;margin-top:4rpx" src="/images/warn_yellow.png"></image> | ||
40 | + <text class="text_gray6_28">请等候申报结果 </text> | ||
41 | + </view> | ||
42 | + <view class="divide_line_f5f5f5"></view> | ||
43 | + <view style="margin-top:20rpx"> | ||
44 | + <text class="text_gray6_28">收入总额:</text> | ||
45 | + <text class="text_gray3_28 float_right" style="line-height:50rpx">¥{{payinfo.total_salary}}</text> | ||
46 | + </view> | ||
47 | + <view class="view_gray_bg" style="padding:16rpx 20rpx;flex-direction: column"> | ||
48 | + <view class="text_gray9_26">其中本单位收入额:{{payinfo.total_salary_on}}</view> | ||
49 | + <text class="text_gray9_26">其中其他单位收入额:{{payinfo.total_salary_else}}</text> | ||
50 | + </view> | ||
51 | + <view style="margin:20rpx 0"> | ||
52 | + <text class="text_gray6_28">累计应纳税额:</text> | ||
53 | + <text class="text_gray3_28 float_right" style="line-height:50rpx">¥{{payinfo.accumulated_payable_tax}}</text> | ||
54 | + </view> | ||
55 | + <view class="divide_line_f5f5f5"></view> | ||
56 | + <view style="margin:20rpx 0"> | ||
57 | + <text class="text_gray6_28">已缴费税额:</text> | ||
58 | + <text class="text_gray3_28 float_right" style="line-height:50rpx">¥{{payinfo.accumulated_prepay_tax}}</text> | ||
59 | + </view> | ||
60 | + <view class="divide_line_f5f5f5"></view> | ||
61 | + <view style="margin:20rpx 0"> | ||
62 | + <text class="text_black_bold">{{uniqual_title01}}:</text> | ||
63 | + <text wx:if="{{declare_status=='0'}}" class="text_gray3_28 float_right" style="line-height:50rpx">计算中</text> | ||
64 | + <text wx:else class="text_orange_28 float_right" style="line-height:50rpx">¥{{new_refund_tax}}</text> | ||
65 | + <view wx:if="{{refund_status=='5'}}" class="light_gray_bg"> | ||
66 | + <text style="font-size:11px;color:rgba(0,0,0,0.35);margin: 0 auto">已放弃</text> | ||
67 | + </view> | ||
68 | + <view wx:elif="{{refund_status=='4'}}" class="light_red_bg"> | ||
69 | + <text style="font-size:11px;color:#fff;margin: 0 auto">退税失败</text> | ||
70 | + </view> | ||
71 | + <view wx:elif="{{refund_status=='4'}}" class="light_yellow_bg"> | ||
72 | + <text style="font-size:11px;color:#fff;margin: 0 auto">申请中</text> | ||
73 | + </view> | ||
74 | + </view> | ||
75 | + <view class="divide_line_f5f5f5"></view> | ||
76 | + <view class="text_blue_28 float_right" style="line-height:50rpx;" bindtap="finalpay_detail">查看详情</view> | ||
77 | + </view> | ||
78 | + </scroll-view> | ||
79 | + <view wx:if="{{declaring_unit_status=='4'}}" style="width:100%;height:300rpx;position: fixed;bottom: 0;background-color:#fff"> | ||
80 | + <view style="display: flex;justify-content: center;margin-top:20rpx"> | ||
71 | <text class="text_gray6_28">距离确认是否在本单位进行汇算清缴时间还有 </text> | 81 | <text class="text_gray6_28">距离确认是否在本单位进行汇算清缴时间还有 </text> |
72 | - <text class="text_yellow_28"> 28 </text> | 82 | + <text class="text_yellow_28"> {{declare_end_days}} </text> |
73 | <text class="text_gray6_28">天</text> | 83 | <text class="text_gray6_28">天</text> |
74 | </view> | 84 | </view> |
75 | <view bindtap="declareNotHere" class="btn_blue_radius" style="margin:20rpx 30rpx "> | 85 | <view bindtap="declareNotHere" class="btn_blue_radius" style="margin:20rpx 30rpx "> |
@@ -80,7 +90,7 @@ | @@ -80,7 +90,7 @@ | ||
80 | </view> | 90 | </view> |
81 | </view> | 91 | </view> |
82 | 92 | ||
83 | - <view wx:if="{{declaring_unit_status=='5'}}" style="width:100%;height:260rpx;position: fixed;bottom: 0;"> | 93 | + <view wx:elif="{{declaring_unit_status=='5'}}" style="width:100%;height:260rpx;position: fixed;bottom: 0;background-color:#fff"> |
84 | <view bindtap="declareBySelf" class="btn_blue_radius" style="margin:20rpx 30rpx "> | 94 | <view bindtap="declareBySelf" class="btn_blue_radius" style="margin:20rpx 30rpx "> |
85 | <view class="text_white_34">查看自行申报方式</view> | 95 | <view class="text_white_34">查看自行申报方式</view> |
86 | </view> | 96 | </view> |
@@ -89,10 +99,10 @@ | @@ -89,10 +99,10 @@ | ||
89 | </view> | 99 | </view> |
90 | </view> | 100 | </view> |
91 | 101 | ||
92 | - <view wx:if="{{declaring_unit_status=='1'||declaring_unit_status=='2'}}" style="width:100%;height:300rpx;position: fixed;bottom: 0;"> | ||
93 | - <view style="display: flex;justify-content: center;"> | ||
94 | - <text class="text_gray6_28">距离确认是否在本单位进行汇算清缴时间还有 </text> | ||
95 | - <text class="text_yellow_28"> 28 </text> | 102 | + <view wx:if="{{declaring_unit_status=='4'&&show_other_unit_view}}" style="width:100%;height:300rpx;position: fixed;bottom: 0;background-color:#fff"> |
103 | + <view style="display: flex;justify-content: center;margin-top:20rpx"> | ||
104 | + <text class="text_gray6_28">距离确认填报其他单位个税申报明细时间还有 </text> | ||
105 | + <text class="text_yellow_28"> {{declare_end_days}} </text> | ||
96 | <text class="text_gray6_28">天</text> | 106 | <text class="text_gray6_28">天</text> |
97 | </view> | 107 | </view> |
98 | <view bindtap="noOtherUnitInfo" class="btn_blue_radius" style="margin:20rpx 30rpx "> | 108 | <view bindtap="noOtherUnitInfo" class="btn_blue_radius" style="margin:20rpx 30rpx "> |
@@ -103,10 +113,10 @@ | @@ -103,10 +113,10 @@ | ||
103 | </view> | 113 | </view> |
104 | </view> | 114 | </view> |
105 | 115 | ||
106 | - <view wx:if="{{refund_status=='1'}}" style="width:100%;height:300rpx;position: fixed;bottom: 0;"> | ||
107 | - <view style="display: flex;justify-content: center;"> | ||
108 | - <text class="text_gray6_28">距离确认是否在本单位进行汇算清缴时间还有 </text> | ||
109 | - <text class="text_yellow_28"> 28 </text> | 116 | + <view wx:if="{{refund_status=='1'}}" style="width:100%;height:300rpx;position: fixed;bottom: 0;background-color:#fff"> |
117 | + <view style="display: flex;justify-content: center;margin-top:20rpx"> | ||
118 | + <text class="text_gray6_28">距离确认是否申请退税时间还有 </text> | ||
119 | + <text class="text_yellow_28"> {{declare_end_days}} </text> | ||
110 | <text class="text_gray6_28">天</text> | 120 | <text class="text_gray6_28">天</text> |
111 | </view> | 121 | </view> |
112 | <view bindtap="doRefund" class="btn_blue_radius" style="margin:20rpx 30rpx "> | 122 | <view bindtap="doRefund" class="btn_blue_radius" style="margin:20rpx 30rpx "> |
@@ -137,7 +147,7 @@ | @@ -137,7 +147,7 @@ | ||
137 | <view class="text_gray3_34" style="padding:30rpx">选择申报单位</view> | 147 | <view class="text_gray3_34" style="padding:30rpx">选择申报单位</view> |
138 | <view class="divide_line"></view> | 148 | <view class="divide_line"></view> |
139 | <view wx:for="{{unitInfo}}" style="height:104rpx;margin-left:50rpx;margin-right:30rpx" bindtap="unitPick" id="{{item.declaring_unit_id}}"> | 149 | <view wx:for="{{unitInfo}}" style="height:104rpx;margin-left:50rpx;margin-right:30rpx" bindtap="unitPick" id="{{item.declaring_unit_id}}"> |
140 | - <text class="text_gray3_32" style="line-height:104rpx" >{{item.declaring_unit}}</text> | 150 | + <text class="text_gray3_32" style="line-height:104rpx">{{item.declaring_unit}}</text> |
141 | <image class="icon_choosed" hidden="true" src="/images/icon_chat_choosed.png"></image> | 151 | <image class="icon_choosed" hidden="true" src="/images/icon_chat_choosed.png"></image> |
142 | <view class="divide_line"></view> | 152 | <view class="divide_line"></view> |
143 | </view> | 153 | </view> |
@@ -128,6 +128,41 @@ | @@ -128,6 +128,41 @@ | ||
128 | line-height: 40rpx; | 128 | line-height: 40rpx; |
129 | } | 129 | } |
130 | 130 | ||
131 | +.light_gray_bg { | ||
132 | + float: right; | ||
133 | + width: 50px; | ||
134 | + margin:10rpx ; | ||
135 | + background: rgba(228, 231, 240, 1); | ||
136 | + border-radius: 2px; | ||
137 | + display: flex; | ||
138 | +} | ||
139 | + | ||
140 | +.light_yellow_bg { | ||
141 | + float: right; | ||
142 | + width: 40px; | ||
143 | + margin:10rpx ; | ||
144 | + background: rgba(255, 143, 31, 1); | ||
145 | + border-radius: 2px; | ||
146 | + display: flex; | ||
147 | +} | ||
148 | + | ||
149 | +.light_red_bg { | ||
150 | + float: right; | ||
151 | + width: 40px; | ||
152 | + margin:10rpx ; | ||
153 | + background: rgba(255, 96, 16, 1); | ||
154 | + border-radius: 2px; | ||
155 | + display: flex; | ||
156 | +} | ||
157 | + | ||
158 | +.text_orange_28 { | ||
159 | + font-size: 17px; | ||
160 | + font-family: PingFangSC-Medium, PingFang SC; | ||
161 | + font-weight: 500; | ||
162 | + color: rgba(255, 143, 31, 1); | ||
163 | + line-height: 52px; | ||
164 | +} | ||
165 | + | ||
131 | /* 遮罩层 */ | 166 | /* 遮罩层 */ |
132 | 167 | ||
133 | .mask { | 168 | .mask { |
1 | -// pages/main/finalpay/incomeAddition/incomeAddition.js | ||
2 | -Page({ | ||
3 | - | ||
4 | - /** | ||
5 | - * Page initial data | ||
6 | - */ | ||
7 | - data: { | ||
8 | - | ||
9 | - }, | ||
10 | - | ||
11 | - /** | ||
12 | - * Lifecycle function--Called when page load | ||
13 | - */ | ||
14 | - onLoad: function (options) { | ||
15 | - | ||
16 | - }, | ||
17 | - | ||
18 | - /** | ||
19 | - * Lifecycle function--Called when page is initially rendered | ||
20 | - */ | ||
21 | - onReady: function () { | ||
22 | - | ||
23 | - }, | ||
24 | - | ||
25 | - /** | ||
26 | - * Lifecycle function--Called when page show | ||
27 | - */ | ||
28 | - onShow: function () { | ||
29 | - | ||
30 | - }, | ||
31 | - | ||
32 | - /** | ||
33 | - * Lifecycle function--Called when page hide | ||
34 | - */ | ||
35 | - onHide: function () { | ||
36 | - | ||
37 | - }, | ||
38 | - | ||
39 | - /** | ||
40 | - * Lifecycle function--Called when page unload | ||
41 | - */ | ||
42 | - onUnload: function () { | ||
43 | - | ||
44 | - }, | ||
45 | - | ||
46 | - /** | ||
47 | - * Page event handler function--Called when user drop down | ||
48 | - */ | ||
49 | - onPullDownRefresh: function () { | ||
50 | - | ||
51 | - }, | ||
52 | - | ||
53 | - /** | ||
54 | - * Called when page reach bottom | ||
55 | - */ | ||
56 | - onReachBottom: function () { | ||
57 | - | ||
58 | - }, | ||
59 | - | ||
60 | - /** | ||
61 | - * Called when user click on the top right corner to share | ||
62 | - */ | ||
63 | - onShareAppMessage: function () { | ||
64 | - | ||
65 | - } | ||
66 | -}) |
1 | -/* pages/main/finalpay/incomeAddition/incomeAddition.wxss */ |
1 | // pages/main/finalpay/incomeDetail/incomeDetail.js | 1 | // pages/main/finalpay/incomeDetail/incomeDetail.js |
2 | +var app = getApp(); | ||
3 | +var baseUrl = app.globalData.baseUrl; | ||
2 | Page({ | 4 | Page({ |
3 | 5 | ||
4 | /** | 6 | /** |
5 | * Page initial data | 7 | * Page initial data |
6 | */ | 8 | */ |
7 | data: { | 9 | data: { |
8 | - currentTab:0, | 10 | + currentTab:1, |
11 | + year:2019, | ||
12 | + incomeInfo:{}, | ||
9 | }, | 13 | }, |
10 | 14 | ||
11 | /** | 15 | /** |
12 | * Lifecycle function--Called when page load | 16 | * Lifecycle function--Called when page load |
13 | */ | 17 | */ |
14 | onLoad: function (options) { | 18 | onLoad: function (options) { |
15 | - | 19 | + this.getIncomeDetail() |
16 | }, | 20 | }, |
17 | 21 | ||
18 | /** | 22 | /** |
@@ -38,9 +42,34 @@ Page({ | @@ -38,9 +42,34 @@ Page({ | ||
38 | that.setData({ | 42 | that.setData({ |
39 | currentTab: e.target.dataset.current | 43 | currentTab: e.target.dataset.current |
40 | }) | 44 | }) |
45 | + this.getIncomeDetail() | ||
41 | } | 46 | } |
42 | }, | 47 | }, |
43 | 48 | ||
49 | + //获取收入明细 | ||
50 | + getIncomeDetail:function(){ | ||
51 | + var that = this | ||
52 | + this.Authorization = getApp().globalData.Authorization; | ||
53 | + wx.request({ | ||
54 | + url: baseUrl + "payroll/v1/settlement-tax/record", | ||
55 | + header: { | ||
56 | + 'Authorization': this.Authorization | ||
57 | + }, | ||
58 | + data: { | ||
59 | + "years":that.data.year, | ||
60 | + "declaring_unit_status": that.data.currentTab | ||
61 | + }, | ||
62 | + success: function (result) { | ||
63 | + console.log("incomeInfo", result) | ||
64 | + if (result.statusCode == 200) { | ||
65 | + that.setData({ | ||
66 | + incomeInfo:result.data.item | ||
67 | + }) | ||
68 | + } | ||
69 | + }, | ||
70 | + }) | ||
71 | + }, | ||
72 | + | ||
44 | /** | 73 | /** |
45 | * Lifecycle function--Called when page hide | 74 | * Lifecycle function--Called when page hide |
46 | */ | 75 | */ |
@@ -2,9 +2,9 @@ | @@ -2,9 +2,9 @@ | ||
2 | <view class="page"> | 2 | <view class="page"> |
3 | 3 | ||
4 | <view class="swiper-tab" style='display:flex'> | 4 | <view class="swiper-tab" style='display:flex'> |
5 | - <view class="swiper-tab-list {{currentTab==0 ? 'on' : ''}}" style="margin:0 10rpx" data-current="0" bindtap="swichNav">本单位收入</view> | ||
6 | - <view class="swiper-tab-list {{currentTab==1 ? 'on' : ''}}" style="margin:0 10rpx" data-current="1" bindtap="swichNav">本单位其他收入</view> | ||
7 | - <view class="swiper-tab-list {{currentTab==2 ? 'on' : ''}}" style="margin:0 10rpx" data-current="2" bindtap="swichNav">其他单位收入</view> | 5 | + <view class="swiper-tab-list {{currentTab==1 ? 'on' : ''}}" style="margin:0 10rpx" data-current="1" bindtap="swichNav">本单位收入</view> |
6 | + <view class="swiper-tab-list {{currentTab==2 ? 'on' : ''}}" style="margin:0 10rpx" data-current="2" bindtap="swichNav">本单位其他收入</view> | ||
7 | + <view class="swiper-tab-list {{currentTab==3 ? 'on' : ''}}" style="margin:0 10rpx" data-current="3" bindtap="swichNav">其他单位收入</view> | ||
8 | </view> | 8 | </view> |
9 | 9 | ||
10 | <scroll-view class="swiper-box page" style="height:100%;" bindchange="bindChange"> | 10 | <scroll-view class="swiper-box page" style="height:100%;" bindchange="bindChange"> |
@@ -15,23 +15,23 @@ | @@ -15,23 +15,23 @@ | ||
15 | </view> | 15 | </view> |
16 | <view> | 16 | <view> |
17 | <text class="text_black6_32">工资薪金收入</text> | 17 | <text class="text_black6_32">工资薪金收入</text> |
18 | - <text class="text_black6_32 float_right">100000</text> | 18 | + <text class="text_black6_32 float_right">{{incomeInfo.total_salary}}</text> |
19 | </view> | 19 | </view> |
20 | <view> | 20 | <view> |
21 | <text class="text_black6_32">劳务报酬收入</text> | 21 | <text class="text_black6_32">劳务报酬收入</text> |
22 | - <text class="text_black6_32 float_right">100000</text> | 22 | + <text class="text_black6_32 float_right">{{incomeInfo.remuneration_labor}}</text> |
23 | </view> | 23 | </view> |
24 | <view> | 24 | <view> |
25 | <text class="text_black6_32">稿酬收入</text> | 25 | <text class="text_black6_32">稿酬收入</text> |
26 | - <text class="text_black6_32 float_right">100000</text> | 26 | + <text class="text_black6_32 float_right">{{incomeInfo.author_payment}}</text> |
27 | </view> | 27 | </view> |
28 | <view> | 28 | <view> |
29 | <text class="text_black6_32">特许经营权</text> | 29 | <text class="text_black6_32">特许经营权</text> |
30 | - <text class="text_black6_32 float_right">100000</text> | 30 | + <text class="text_black6_32 float_right">{{incomeInfo.special_manage_cost}}</text> |
31 | </view> | 31 | </view> |
32 | <view> | 32 | <view> |
33 | <text class="text_black6_32">其他免税收入</text> | 33 | <text class="text_black6_32">其他免税收入</text> |
34 | - <text class="text_black6_32 float_right">100000</text> | 34 | + <text class="text_black6_32 float_right">{{incomeInfo.other_free_income}}</text> |
35 | </view> | 35 | </view> |
36 | </view> | 36 | </view> |
37 | <!-- 免税收入 --> | 37 | <!-- 免税收入 --> |
@@ -41,7 +41,7 @@ | @@ -41,7 +41,7 @@ | ||
41 | </view> | 41 | </view> |
42 | <view> | 42 | <view> |
43 | <text class="text_black6_32">其他免税收入</text> | 43 | <text class="text_black6_32">其他免税收入</text> |
44 | - <text class="text_black6_32 float_right">2000</text> | 44 | + <text class="text_black6_32 float_right">{{incomeInfo.other_free_income}}</text> |
45 | </view> | 45 | </view> |
46 | </view> | 46 | </view> |
47 | <!-- 专项扣除 --> | 47 | <!-- 专项扣除 --> |
@@ -51,19 +51,19 @@ | @@ -51,19 +51,19 @@ | ||
51 | </view> | 51 | </view> |
52 | <view> | 52 | <view> |
53 | <text class="text_black6_32">养老保险</text> | 53 | <text class="text_black6_32">养老保险</text> |
54 | - <text class="text_black6_32 float_right">100000</text> | 54 | + <text class="text_black6_32 float_right">{{incomeInfo.personal_endowment}}</text> |
55 | </view> | 55 | </view> |
56 | <view> | 56 | <view> |
57 | <text class="text_black6_32">医疗保险</text> | 57 | <text class="text_black6_32">医疗保险</text> |
58 | - <text class="text_black6_32 float_right">100000</text> | 58 | + <text class="text_black6_32 float_right">{{incomeInfo.personal_medical}}</text> |
59 | </view> | 59 | </view> |
60 | <view> | 60 | <view> |
61 | <text class="text_black6_32">失业保险</text> | 61 | <text class="text_black6_32">失业保险</text> |
62 | - <text class="text_black6_32 float_right">100000</text> | 62 | + <text class="text_black6_32 float_right">{{incomeInfo.personal_unemployment}}</text> |
63 | </view> | 63 | </view> |
64 | <view> | 64 | <view> |
65 | <text class="text_black6_32">住房公积金</text> | 65 | <text class="text_black6_32">住房公积金</text> |
66 | - <text class="text_black6_32 float_right">100000</text> | 66 | + <text class="text_black6_32 float_right">{{incomeInfo.personal_house_fund}}</text> |
67 | </view> | 67 | </view> |
68 | </view> | 68 | </view> |
69 | <!-- 专项附加扣除 --> | 69 | <!-- 专项附加扣除 --> |
@@ -73,27 +73,27 @@ | @@ -73,27 +73,27 @@ | ||
73 | </view> | 73 | </view> |
74 | <view> | 74 | <view> |
75 | <text class="text_black6_32">子女教育</text> | 75 | <text class="text_black6_32">子女教育</text> |
76 | - <text class="text_black6_32 float_right">100000</text> | 76 | + <text class="text_black6_32 float_right">{{incomeInfo.childrens_education}}</text> |
77 | </view> | 77 | </view> |
78 | <view> | 78 | <view> |
79 | <text class="text_black6_32">继续教育</text> | 79 | <text class="text_black6_32">继续教育</text> |
80 | - <text class="text_black6_32 float_right">100000</text> | 80 | + <text class="text_black6_32 float_right">{{incomeInfo.continuing_education}}</text> |
81 | </view> | 81 | </view> |
82 | <view> | 82 | <view> |
83 | <text class="text_black6_32">住房贷款利息</text> | 83 | <text class="text_black6_32">住房贷款利息</text> |
84 | - <text class="text_black6_32 float_right">100000</text> | 84 | + <text class="text_black6_32 float_right">{{incomeInfo.housing_loan_interest}}</text> |
85 | </view> | 85 | </view> |
86 | <view> | 86 | <view> |
87 | <text class="text_black6_32">住房租金</text> | 87 | <text class="text_black6_32">住房租金</text> |
88 | - <text class="text_black6_32 float_right">100000</text> | 88 | + <text class="text_black6_32 float_right">{{incomeInfo.housing_rent}}</text> |
89 | </view> | 89 | </view> |
90 | <view> | 90 | <view> |
91 | <text class="text_black6_32">赡养老人</text> | 91 | <text class="text_black6_32">赡养老人</text> |
92 | - <text class="text_black6_32 float_right">100000</text> | 92 | + <text class="text_black6_32 float_right">{{incomeInfo.caring_old_people}}</text> |
93 | </view> | 93 | </view> |
94 | <view> | 94 | <view> |
95 | <text class="text_black6_32">大病医疗</text> | 95 | <text class="text_black6_32">大病医疗</text> |
96 | - <text class="text_black6_32 float_right">100000</text> | 96 | + <text class="text_black6_32 float_right">{{incomeInfo.serious_illness_medical}}</text> |
97 | </view> | 97 | </view> |
98 | </view> | 98 | </view> |
99 | <!-- 其他扣除 --> | 99 | <!-- 其他扣除 --> |
@@ -103,19 +103,19 @@ | @@ -103,19 +103,19 @@ | ||
103 | </view> | 103 | </view> |
104 | <view> | 104 | <view> |
105 | <text class="text_black6_32">年金</text> | 105 | <text class="text_black6_32">年金</text> |
106 | - <text class="text_black6_32 float_right">100000</text> | 106 | + <text class="text_black6_32 float_right">{{incomeInfo.annuity}}</text> |
107 | </view> | 107 | </view> |
108 | <view> | 108 | <view> |
109 | <text class="text_black6_32">商业健康保险</text> | 109 | <text class="text_black6_32">商业健康保险</text> |
110 | - <text class="text_black6_32 float_right">100000</text> | 110 | + <text class="text_black6_32 float_right">{{incomeInfo.commercial_insurance}}</text> |
111 | </view> | 111 | </view> |
112 | <view> | 112 | <view> |
113 | <text class="text_black6_32">税延养老保险</text> | 113 | <text class="text_black6_32">税延养老保险</text> |
114 | - <text class="text_black6_32 float_right">100000</text> | 114 | + <text class="text_black6_32 float_right">{{incomeInfo.tax_extension}}</text> |
115 | </view> | 115 | </view> |
116 | <view> | 116 | <view> |
117 | <text class="text_black6_32">其他</text> | 117 | <text class="text_black6_32">其他</text> |
118 | - <text class="text_black6_32 float_right">100000</text> | 118 | + <text class="text_black6_32 float_right">{{incomeInfo.other_fee}}</text> |
119 | </view> | 119 | </view> |
120 | </view> | 120 | </view> |
121 | <!-- 捐赠扣除 --> | 121 | <!-- 捐赠扣除 --> |
@@ -125,11 +125,11 @@ | @@ -125,11 +125,11 @@ | ||
125 | </view> | 125 | </view> |
126 | <view> | 126 | <view> |
127 | <text class="text_black6_32">准予扣除的捐赠额</text> | 127 | <text class="text_black6_32">准予扣除的捐赠额</text> |
128 | - <text class="text_black6_32 float_right">100000</text> | 128 | + <text class="text_black6_32 float_right">{{incomeInfo.donation_deducted}}</text> |
129 | </view> | 129 | </view> |
130 | <view> | 130 | <view> |
131 | <text class="text_black6_32">全年一次性奖金</text> | 131 | <text class="text_black6_32">全年一次性奖金</text> |
132 | - <text class="text_black6_32 float_right">100000</text> | 132 | + <text class="text_black6_32 float_right">{{incomeInfo.years_bouns}}</text> |
133 | </view> | 133 | </view> |
134 | </view> | 134 | </view> |
135 | <!-- 减免/已缴纳税额 --> | 135 | <!-- 减免/已缴纳税额 --> |
@@ -139,11 +139,11 @@ | @@ -139,11 +139,11 @@ | ||
139 | </view> | 139 | </view> |
140 | <view> | 140 | <view> |
141 | <text class="text_black6_32">减免税额</text> | 141 | <text class="text_black6_32">减免税额</text> |
142 | - <text class="text_black6_32 float_right">100000</text> | 142 | + <text class="text_black6_32 float_right">{{incomeInfo.tax_savings}}</text> |
143 | </view> | 143 | </view> |
144 | <view> | 144 | <view> |
145 | <text class="text_black6_32">已缴税额</text> | 145 | <text class="text_black6_32">已缴税额</text> |
146 | - <text class="text_black6_32 float_right">100000</text> | 146 | + <text class="text_black6_32 float_right">{{incomeInfo.accumulated_withholding_tax}}</text> |
147 | </view> | 147 | </view> |
148 | </view> | 148 | </view> |
149 | </scroll-view> | 149 | </scroll-view> |
1 | // pages/main/finalpay/refundDetail/refundDetail.js | 1 | // pages/main/finalpay/refundDetail/refundDetail.js |
2 | +var app = getApp(); | ||
3 | +var baseUrl = app.globalData.baseUrl; | ||
2 | Page({ | 4 | Page({ |
3 | 5 | ||
4 | /** | 6 | /** |
5 | * Page initial data | 7 | * Page initial data |
6 | */ | 8 | */ |
7 | data: { | 9 | data: { |
8 | - | 10 | + year:"2019", |
11 | + refundInfo:{} | ||
9 | }, | 12 | }, |
10 | 13 | ||
11 | /** | 14 | /** |
12 | * Lifecycle function--Called when page load | 15 | * Lifecycle function--Called when page load |
13 | */ | 16 | */ |
14 | onLoad: function (options) { | 17 | onLoad: function (options) { |
15 | - | 18 | + this.getRefundDetail() |
16 | }, | 19 | }, |
17 | 20 | ||
18 | /** | 21 | /** |
@@ -29,6 +32,28 @@ Page({ | @@ -29,6 +32,28 @@ Page({ | ||
29 | 32 | ||
30 | }, | 33 | }, |
31 | 34 | ||
35 | + getRefundDetail: function () {//退税明细 | ||
36 | + var that = this | ||
37 | + this.Authorization = getApp().globalData.Authorization; | ||
38 | + wx.request({ | ||
39 | + url: baseUrl + "payroll/v1/settlement-tax/refund-detail", | ||
40 | + header: { | ||
41 | + 'Authorization': this.Authorization | ||
42 | + }, | ||
43 | + data: { | ||
44 | + years:that.data.year, | ||
45 | + }, | ||
46 | + success: function (result) { | ||
47 | + console.log("declareinfo", result) | ||
48 | + if (result.statusCode == 200) { | ||
49 | + that.setData({ | ||
50 | + refundInfo:result.data | ||
51 | + }) | ||
52 | + } | ||
53 | + }, | ||
54 | + }) | ||
55 | + }, | ||
56 | + | ||
32 | /** | 57 | /** |
33 | * Lifecycle function--Called when page hide | 58 | * Lifecycle function--Called when page hide |
34 | */ | 59 | */ |
@@ -7,7 +7,7 @@ Page({ | @@ -7,7 +7,7 @@ Page({ | ||
7 | * Page initial data | 7 | * Page initial data |
8 | */ | 8 | */ |
9 | data: { | 9 | data: { |
10 | - | 10 | + show_modal:false |
11 | }, | 11 | }, |
12 | 12 | ||
13 | /** | 13 | /** |
@@ -97,7 +97,25 @@ Page({ | @@ -97,7 +97,25 @@ Page({ | ||
97 | }) | 97 | }) |
98 | }, | 98 | }, |
99 | 99 | ||
100 | - formSubmit: function() { | 100 | + formSubmit: function(e) { |
101 | + console.log("formSubmit", e); | ||
102 | + var formdata = e.detail.value | ||
103 | + this.setData({ | ||
104 | + show_modal:true | ||
105 | + }) | ||
106 | + }, | ||
107 | + | ||
108 | + commitCancel:function(){ | ||
109 | + this.setData({ | ||
110 | + show_modal: false | ||
111 | + }) | ||
112 | + }, | ||
113 | + | ||
114 | + | ||
115 | + commitConfirm: function () { | ||
116 | + this.setData({ | ||
117 | + show_modal: false | ||
118 | + }) | ||
101 | // 是否放弃退税,(是:"5",否:"") | 119 | // 是否放弃退税,(是:"5",否:"") |
102 | var that = this | 120 | var that = this |
103 | this.Authorization = getApp().globalData.Authorization; | 121 | this.Authorization = getApp().globalData.Authorization; |
@@ -106,13 +124,14 @@ Page({ | @@ -106,13 +124,14 @@ Page({ | ||
106 | header: { | 124 | header: { |
107 | 'Authorization': this.Authorization | 125 | 'Authorization': this.Authorization |
108 | }, | 126 | }, |
127 | + method:"PUT", | ||
109 | data: { | 128 | data: { |
110 | 'name': '', | 129 | 'name': '', |
111 | "bank": '', | 130 | "bank": '', |
112 | "bank_card_no": '', | 131 | "bank_card_no": '', |
113 | "bank_card_province": '' | 132 | "bank_card_province": '' |
114 | }, | 133 | }, |
115 | - success: function(result) { | 134 | + success: function (result) { |
116 | console.log("submit", result) | 135 | console.log("submit", result) |
117 | if (result.statusCode == 200) { | 136 | if (result.statusCode == 200) { |
118 | that.setData({ | 137 | that.setData({ |
@@ -121,7 +140,7 @@ Page({ | @@ -121,7 +140,7 @@ Page({ | ||
121 | } | 140 | } |
122 | }, | 141 | }, |
123 | }) | 142 | }) |
124 | - }, | 143 | + }, |
125 | 144 | ||
126 | /** | 145 | /** |
127 | * Lifecycle function--Called when page hide | 146 | * Lifecycle function--Called when page hide |
@@ -3,28 +3,56 @@ | @@ -3,28 +3,56 @@ | ||
3 | <form style="width:100%;" bindsubmit='formSubmit'> | 3 | <form style="width:100%;" bindsubmit='formSubmit'> |
4 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff;margin-bottom:1rpx"> | 4 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff;margin-bottom:1rpx"> |
5 | <text class="text_gray7_34">开户人姓名</text> | 5 | <text class="text_gray7_34">开户人姓名</text> |
6 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='' value="汪闲僧"></input> | 6 | + <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='name' value="汪闲僧"></input> |
7 | </view> | 7 | </view> |
8 | <view class='divide_line_30'></view> | 8 | <view class='divide_line_30'></view> |
9 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff"> | 9 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff"> |
10 | <text class="text_gray7_34" style="line-height:104rpx">银行卡号</text> | 10 | <text class="text_gray7_34" style="line-height:104rpx">银行卡号</text> |
11 | <image class='image_camera' src='/images/camera.png' bindtap='bindbank'></image> | 11 | <image class='image_camera' src='/images/camera.png' bindtap='bindbank'></image> |
12 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name=''></input> | 12 | + <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='bank_card_no'></input> |
13 | </view> | 13 | </view> |
14 | <view class='divide_line_30'></view> | 14 | <view class='divide_line_30'></view> |
15 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff"> | 15 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff"> |
16 | <text class="text_gray7_34" style="line-height:104rpx">开户银行名称</text> | 16 | <text class="text_gray7_34" style="line-height:104rpx">开户银行名称</text> |
17 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name=''></input> | 17 | + <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='bank'></input> |
18 | </view> | 18 | </view> |
19 | <view class='divide_line_30'></view> | 19 | <view class='divide_line_30'></view> |
20 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff"> | 20 | <view style="height:104rpx;padding:0 30rpx;background-color:#fff"> |
21 | <text class="text_gray7_34" style="line-height:104rpx">开户银行省份</text> | 21 | <text class="text_gray7_34" style="line-height:104rpx">开户银行省份</text> |
22 | - <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name=''></input> | 22 | + <input class='input_wrap' style='text-align: right;color:#000;' placeholder='请输入' name='bank_card_province'></input> |
23 | </view> | 23 | </view> |
24 | 24 | ||
25 | -<view class="btn_bottom" > | 25 | + <view class="btn_bottom"> |
26 | <button class="btn_bottom" formType="submit">保存</button> | 26 | <button class="btn_bottom" formType="submit">保存</button> |
27 | </view> | 27 | </view> |
28 | </form> | 28 | </form> |
29 | + <view class="mask" wx:if="{{show_modal}}"></view> | ||
30 | + <view class='modal_lg' style='' wx:if="{{show_modal}}"> | ||
31 | + <!-- <view style='width:100%;display:flex;flex-direction:column;max-height:560rpx;overflow-y: scroll;'></view> --> | ||
32 | + <view class="text_title"> 确认提交吗?</view> | ||
33 | + <view style="margin:2rpx 40rpx"> | ||
34 | + <text class="text_gray6_28">姓名:</text> | ||
35 | + <text class="text_gray6_28 float_right">张三</text> | ||
36 | + </view> | ||
37 | + <view style="margin:2rpx 40rpx"> | ||
38 | + <text class="text_gray6_28">银行卡号:</text> | ||
39 | + <text class="text_gray6_28 float_right">4832588325825925</text> | ||
40 | + </view> | ||
41 | + <view style="margin:2rpx 40rpx"> | ||
42 | + <text class="text_gray6_28">开户行名称:</text> | ||
43 | + <text class="text_gray6_28 float_right">中国邮政储蓄银行</text> | ||
44 | + </view> | ||
45 | + <view style="margin:2rpx 40rpx"> | ||
46 | + <text class="text_gray6_28">开户行省份:</text> | ||
47 | + <text class="text_gray6_28 float_right">湖北</text> | ||
48 | + </view> | ||
49 | + <view class='divide_line_f5f5f5' style="margin-top:30rpx"></view> | ||
50 | + | ||
51 | + <view style='width:100%;display: flex;'> | ||
52 | + <text class='text_cancel' bindtap='commitCancel'>取消</text> | ||
53 | + <view style='width:1px;background:#F5F5F5;'></view> | ||
54 | + <text class='text_confirm' bindtap='commitConfirm'>确认</text> | ||
55 | + </view> | ||
29 | 56 | ||
57 | + </view> | ||
30 | </view> | 58 | </view> |
@@ -20,6 +20,12 @@ | @@ -20,6 +20,12 @@ | ||
20 | line-height: 104rpx; | 20 | line-height: 104rpx; |
21 | } | 21 | } |
22 | 22 | ||
23 | +.text_gray6_28 { | ||
24 | + font-family: PingFangSC-Regular, PingFang SC; | ||
25 | + font-size: 28rpx; | ||
26 | + color: #666; | ||
27 | +} | ||
28 | + | ||
23 | .input_wrap { | 29 | .input_wrap { |
24 | max-width: 600rpx; | 30 | max-width: 600rpx; |
25 | height: 104rpx; | 31 | height: 104rpx; |
@@ -29,7 +35,7 @@ | @@ -29,7 +35,7 @@ | ||
29 | overflow: hidden; | 35 | overflow: hidden; |
30 | text-overflow: ellipsis; | 36 | text-overflow: ellipsis; |
31 | white-space: nowrap; | 37 | white-space: nowrap; |
32 | - float: right | 38 | + float: right; |
33 | } | 39 | } |
34 | 40 | ||
35 | .image_camera { | 41 | .image_camera { |
@@ -38,4 +44,59 @@ | @@ -38,4 +44,59 @@ | ||
38 | margin-left: 10rpx; | 44 | margin-left: 10rpx; |
39 | margin-top: 30rpx; | 45 | margin-top: 30rpx; |
40 | float: right; | 46 | float: right; |
41 | -} | ||
47 | +} | ||
48 | + | ||
49 | +/* 遮罩层 */ | ||
50 | + | ||
51 | +.mask { | ||
52 | + width: 100%; | ||
53 | + height: 100%; | ||
54 | + position: fixed; | ||
55 | + top: 0; | ||
56 | + left: 0; | ||
57 | + background: #000; | ||
58 | + opacity: 0.7; | ||
59 | + z-index: 10; | ||
60 | +} | ||
61 | + | ||
62 | +.modal_lg { | ||
63 | + width: 72%; | ||
64 | + position: fixed; | ||
65 | + left: 0; | ||
66 | + right: 0; | ||
67 | + margin: 0 auto; | ||
68 | + background-color: #fff; | ||
69 | + border-radius: 7px; | ||
70 | + display: flex; | ||
71 | + flex-direction: column; | ||
72 | + top: 260rpx; | ||
73 | + z-index: 10; | ||
74 | +} | ||
75 | + | ||
76 | +.text_cancel { | ||
77 | + font-family: PingFangSC-Regular; | ||
78 | + font-size: 36rpx; | ||
79 | + color: #999; | ||
80 | + letter-spacing: 0; | ||
81 | + text-align: center; | ||
82 | + flex: 1; | ||
83 | + padding: 30rpx; | ||
84 | +} | ||
85 | + | ||
86 | +.text_confirm { | ||
87 | + font-family: PingFangSC-Medium, PingFang SC; | ||
88 | + font-size: 36rpx; | ||
89 | + color: #357aeb; | ||
90 | + letter-spacing: 0; | ||
91 | + text-align: center; | ||
92 | + flex: 1; | ||
93 | + padding: 30rpx; | ||
94 | +} | ||
95 | + | ||
96 | +.text_title { | ||
97 | + font-size: 18px; | ||
98 | + font-family: PingFangSC-Medium, PingFang SC; | ||
99 | + color: rgba(51, 51, 51, 1); | ||
100 | + padding: 40rpx; | ||
101 | + text-align: center; | ||
102 | +} |
@@ -59,6 +59,12 @@ function dayFormString(dateStr) { | @@ -59,6 +59,12 @@ function dayFormString(dateStr) { | ||
59 | return day | 59 | return day |
60 | } | 60 | } |
61 | 61 | ||
62 | +// 两个日期间隔天数 | ||
63 | +function daysTillNow(startDate, endDate){ | ||
64 | + var days = (endDate - startDate) / (24 * 60 * 60 ); | ||
65 | + return Math.floor(days); | ||
66 | +} | ||
67 | + | ||
62 | //获取当前时间,格式YYYY-MM-DD | 68 | //获取当前时间,格式YYYY-MM-DD |
63 | function curDateTime() { | 69 | function curDateTime() { |
64 | var d = new Date(); | 70 | var d = new Date(); |
@@ -252,5 +258,6 @@ module.exports = { | @@ -252,5 +258,6 @@ module.exports = { | ||
252 | isMobile: isMobile, | 258 | isMobile: isMobile, |
253 | getAge: getAge, | 259 | getAge: getAge, |
254 | banknoCheck: banknoCheck, | 260 | banknoCheck: banknoCheck, |
255 | - checkEmail: checkEmail | 261 | + checkEmail: checkEmail, |
262 | + daysTillNow: daysTillNow | ||
256 | } | 263 | } |
请
注册
或
登录
后发表评论