提交 a04255cb58529a5e3c8656ef1f9e77c170c56cc8

作者 wangyu
1 个父辈 2cc119e0

优化

1 1 {
2   - "navigationBarTitleText": "自然人税收",
  2 + "navigationBarTitleText": "海峡易税",
3 3 "disableScroll" : true,
4 4 "navigationBarBackgroundColor": "#4478e3"
5 5
... ...
1 1 {
2   - "navigationBarTitleText": "自然人税收",
  2 + "navigationBarTitleText": "海峡易税",
3 3 "disableScroll": true,
4 4 "navigationBarBackgroundColor": "#4478e3"
5 5 }
\ No newline at end of file
... ...
1 1 {
2   - "navigationBarTitleText": "自然人税收",
  2 + "navigationBarTitleText": "海峡易税",
3 3 "navigationBarTextStyle": "black",
4 4 "navigationBarBackgroundColor": "#FFFFFF"
5 5 }
\ No newline at end of file
... ...
... ... @@ -2,7 +2,7 @@
2 2 var app = getApp();
3 3 var baseUrl = app.globalData.baseUrl;
4 4 Page({
5   - self_id:null,
  5 + self_id: null,
6 6 /**
7 7 * 页面的初始数据
8 8 */
... ... @@ -15,7 +15,7 @@ Page({
15 15 /**
16 16 * 生命周期函数--监听页面加载
17 17 */
18   - onLoad: function (options) {
  18 + onLoad: function(options) {
19 19 console.log('onLoad')
20 20 if (app.globalData.OSSUrl.length == 0) {
21 21 app.configOssUrl()
... ... @@ -26,20 +26,20 @@ Page({
26 26 /**
27 27 * 生命周期函数--监听页面初次渲染完成
28 28 */
29   - onReady: function () {
  29 + onReady: function() {
30 30
31 31 },
32 32
33 33 /**
34 34 * 生命周期函数--监听页面显示
35 35 */
36   - onShow: function () {
  36 + onShow: function() {
37 37
38 38 console.log('onShow')
39 39 this.getTaxList()
40 40 },
41 41
42   - getTaxList: function () {
  42 + getTaxList: function() {
43 43 var that = this;
44 44 wx.showLoading({
45 45 title: '加载中',
... ... @@ -59,7 +59,7 @@ Page({
59 59 data: {
60 60 'all': true
61 61 },
62   - success: function (res) {
  62 + success: function(res) {
63 63 console.log('succ', res)
64 64 if (res.statusCode == 200) {
65 65 that.handleData(res.data);
... ... @@ -93,7 +93,7 @@ Page({
93 93 })
94 94 },
95 95
96   - handleData: function (data) {
  96 + handleData: function(data) {
97 97 if (data.items && data.items.length > 0) {
98 98 var datalist = []
99 99
... ... @@ -101,13 +101,13 @@ Page({
101 101 data.items[i].newmobile = this.formatMobile(data.items[i].mobile)
102 102 data.items[i].newidnum = this.formatIdNum(data.items[i].id_card_no)
103 103 data.items[i].relative = data.items[i].family_ties
104   - if (data.items[i].family_ties=="本人"){
  104 + if (data.items[i].family_ties == "本人") {
105 105 this.self_id = data.items[i].id
106   - if (data.items[i].status!='0'){//0已完善 1未完善
  106 + if (data.items[i].status != '0') { //0已完善 1未完善
107 107 this.setData({
108 108 text_tip: '自然人信息不完善,立即完善'
109 109 })
110   - }else{
  110 + } else {
111 111 this.setData({
112 112 text_tip: '去查看'
113 113 })
... ... @@ -122,7 +122,7 @@ Page({
122 122 console.log('handleData', this.data.taxlist)
123 123 },
124 124
125   - formatMobile: function (mobile) {
  125 + formatMobile: function(mobile) {
126 126 if (mobile && mobile > 7) {
127 127 return mobile.replace(/(\d{3})\d{4}(\d{4})/, '$1****$2');
128 128 } else {
... ... @@ -130,7 +130,7 @@ Page({
130 130 }
131 131 },
132 132
133   - formatIdNum: function (idnum) {
  133 + formatIdNum: function(idnum) {
134 134 if (idnum && idnum.length >= 6 && idnum.length < 10) {
135 135 return idnum.substring(0, 2) + '****' + idnum.substring(idnum.length - 2, idnum.length);
136 136 } else if (idnum.length >= 10) {
... ... @@ -140,20 +140,20 @@ Page({
140 140 }
141 141 },
142 142
143   - goadd: function (e) {
  143 + goadd: function(e) {
144 144 console.log(e)
145 145 wx.navigateTo({
146 146 url: 'addinfo/addinfo',
147 147 })
148 148 },
149 149
150   - goedit: function (e) {
  150 + goedit: function(e) {
151 151 console.log(e)
152   - if (this.self_id != e.currentTarget.id){
  152 + if (this.self_id != e.currentTarget.id) {
153 153 wx.navigateTo({
154 154 url: 'addinfo/addinfo?id=' + e.currentTarget.id,
155 155 })
156   - }else {
  156 + } else {
157 157 wx.navigateTo({
158 158 url: 'editinfo/editinfo?id=' + e.currentTarget.id,
159 159 })
... ... @@ -163,35 +163,35 @@ Page({
163 163 /**
164 164 * 生命周期函数--监听页面隐藏
165 165 */
166   - onHide: function () {
  166 + onHide: function() {
167 167
168 168 },
169 169
170 170 /**
171 171 * 生命周期函数--监听页面卸载
172 172 */
173   - onUnload: function () {
  173 + onUnload: function() {
174 174
175 175 },
176 176
177 177 /**
178 178 * 页面相关事件处理函数--监听用户下拉动作
179 179 */
180   - onPullDownRefresh: function () {
  180 + onPullDownRefresh: function() {
181 181
182 182 },
183 183
184 184 /**
185 185 * 页面上拉触底事件的处理函数
186 186 */
187   - onReachBottom: function () {
  187 + onReachBottom: function() {
188 188
189 189 },
190 190
191 191 /**
192 192 * 用户点击右上角分享
193 193 */
194   - onShareAppMessage: function () {
  194 + onShareAppMessage: function() {
195 195
196 196 }
197   -})
  197 +})
\ No newline at end of file
... ...
1 1 {
2   - "navigationBarTitleText": "自然人税收"
  2 + "navigationBarTitleText": "海峡易税"
3 3 }
\ No newline at end of file
... ...
注册登录 后发表评论