正在显示
6 个修改的文件
包含
66 行增加
和
29 行删除
| @@ -9,6 +9,7 @@ Page({ | @@ -9,6 +9,7 @@ Page({ | ||
| 9 | */ | 9 | */ |
| 10 | data: { | 10 | data: { |
| 11 | cur_status: "", | 11 | cur_status: "", |
| 12 | + handle_finished:false, | ||
| 12 | legal_entity_id: "", | 13 | legal_entity_id: "", |
| 13 | legal_entity: "", | 14 | legal_entity: "", |
| 14 | house_type: "", | 15 | house_type: "", |
| @@ -106,6 +107,9 @@ Page({ | @@ -106,6 +107,9 @@ Page({ | ||
| 106 | onLoad: function(options) { | 107 | onLoad: function(options) { |
| 107 | var that = this | 108 | var that = this |
| 108 | var housetype, housestatus | 109 | var housetype, housestatus |
| 110 | + wx.showLoading({ | ||
| 111 | + title: '', | ||
| 112 | + }) | ||
| 109 | console.log("options", options); | 113 | console.log("options", options); |
| 110 | if (options.status == 'house_fund_rent') { | 114 | if (options.status == 'house_fund_rent') { |
| 111 | housetype = 'house_fund_rent' | 115 | housetype = 'house_fund_rent' |
| @@ -160,6 +164,9 @@ Page({ | @@ -160,6 +164,9 @@ Page({ | ||
| 160 | console.log("res", res) | 164 | console.log("res", res) |
| 161 | that.handleAddition(res.data) | 165 | that.handleAddition(res.data) |
| 162 | } | 166 | } |
| 167 | + }, | ||
| 168 | + fail:function(res){ | ||
| 169 | + wx.hideLoading() | ||
| 163 | } | 170 | } |
| 164 | }) | 171 | }) |
| 165 | }, | 172 | }, |
| @@ -252,10 +259,12 @@ Page({ | @@ -252,10 +259,12 @@ Page({ | ||
| 252 | console.log("housetype_new", housetype_new) | 259 | console.log("housetype_new", housetype_new) |
| 253 | this.setData({ | 260 | this.setData({ |
| 254 | house_type: housetype_new, | 261 | house_type: housetype_new, |
| 262 | + handle_finished:true, | ||
| 255 | person_total_amount: data.person_total_amount ? data.person_total_amount : 0, | 263 | person_total_amount: data.person_total_amount ? data.person_total_amount : 0, |
| 256 | remaining_amount: data.remaining_amount ? data.remaining_amount : 0, | 264 | remaining_amount: data.remaining_amount ? data.remaining_amount : 0, |
| 257 | additionInfo: newdata | 265 | additionInfo: newdata |
| 258 | }) | 266 | }) |
| 267 | + wx.hideLoading() | ||
| 259 | }, | 268 | }, |
| 260 | 269 | ||
| 261 | goaddSupporter: function() { | 270 | goaddSupporter: function() { |
| @@ -385,7 +385,8 @@ | @@ -385,7 +385,8 @@ | ||
| 385 | 385 | ||
| 386 | </view> | 386 | </view> |
| 387 | 387 | ||
| 388 | - <view class='bottom_btn_wrap' hidden="{{additionInfo&&additionInfo.length>0&&cur_status=='house_fund'&&house_type=='house_fund_loan'}}"> | 388 | + <view class='bottom_btn_wrap' hidden="{{handle_finished&&additionInfo&&additionInfo.length>0&&cur_status=='house_fund'&&house_type=='house_fund_loan'}}"> |
| 389 | + <!-- <view class='bottom_btn_wrap' wx:if="{{(cur_status!='house_fund'&&additionInfo.length<1)&&cur_status=='house_fund'&&house_type=='house_fund_loan'}}"> --> | ||
| 389 | <view class='btn_blue_radius' bindtap="goadd"> | 390 | <view class='btn_blue_radius' bindtap="goadd"> |
| 390 | <view class='text_white_34'>添加</view> | 391 | <view class='text_white_34'>添加</view> |
| 391 | </view> | 392 | </view> |
| @@ -20,7 +20,7 @@ Page({ | @@ -20,7 +20,7 @@ Page({ | ||
| 20 | onLoad: function(options) { | 20 | onLoad: function(options) { |
| 21 | var mydate = new Date(); | 21 | var mydate = new Date(); |
| 22 | this.setData({ | 22 | this.setData({ |
| 23 | - choosed_date: mydate.getFullYear() + "年" , | 23 | + choosed_date: mydate.getFullYear() + "年", |
| 24 | long_date: mydate.getTime() / 1000 | 24 | long_date: mydate.getTime() / 1000 |
| 25 | }) | 25 | }) |
| 26 | 26 | ||
| @@ -37,13 +37,13 @@ Page({ | @@ -37,13 +37,13 @@ Page({ | ||
| 37 | animation: true, | 37 | animation: true, |
| 38 | canvasId: 'pieCanvas', | 38 | canvasId: 'pieCanvas', |
| 39 | type: 'pie', | 39 | type: 'pie', |
| 40 | - series: [ { | ||
| 41 | - name: '子女教育可扣除金额', | ||
| 42 | - data: 35, | ||
| 43 | - }, { | 40 | + series: [{ |
| 41 | + name: '子女教育可扣除金额', | ||
| 42 | + data: 35, | ||
| 43 | + }, { | ||
| 44 | name: '子女教育已扣除金额', | 44 | name: '子女教育已扣除金额', |
| 45 | - data: 78, | ||
| 46 | - }, | 45 | + data: 78, |
| 46 | + }, | ||
| 47 | { | 47 | { |
| 48 | name: '继续教育可扣除金额', | 48 | name: '继续教育可扣除金额', |
| 49 | data: 35, | 49 | data: 35, |
| @@ -76,7 +76,8 @@ Page({ | @@ -76,7 +76,8 @@ Page({ | ||
| 76 | }, { | 76 | }, { |
| 77 | name: '剩余扣除额度已扣除金额', | 77 | name: '剩余扣除额度已扣除金额', |
| 78 | data: 78, | 78 | data: 78, |
| 79 | - },], | 79 | + }, |
| 80 | + ], | ||
| 80 | width: windowWidth, | 81 | width: windowWidth, |
| 81 | height: 320, | 82 | height: 320, |
| 82 | dataLabel: true, | 83 | dataLabel: true, |
| @@ -103,21 +104,21 @@ Page({ | @@ -103,21 +104,21 @@ Page({ | ||
| 103 | }) | 104 | }) |
| 104 | }, | 105 | }, |
| 105 | 106 | ||
| 106 | - gohistory: function (e) { | 107 | + gohistory: function(e) { |
| 107 | wx.navigateTo({ | 108 | wx.navigateTo({ |
| 108 | url: 'historylist/historylist', | 109 | url: 'historylist/historylist', |
| 109 | }) | 110 | }) |
| 110 | }, | 111 | }, |
| 111 | 112 | ||
| 112 | - datePickerChange: function (e) { | 113 | + datePickerChange: function(e) { |
| 113 | console.log("e", e) | 114 | console.log("e", e) |
| 114 | var datelong = Date.parse(new Date(e.detail.value)) / 1000 | 115 | var datelong = Date.parse(new Date(e.detail.value)) / 1000 |
| 115 | console.log('datelong', datelong) | 116 | console.log('datelong', datelong) |
| 116 | this.setData({ | 117 | this.setData({ |
| 117 | long_date: datelong, | 118 | long_date: datelong, |
| 118 | - choosed_date: format.yearFormString(datelong) + "年" | 119 | + choosed_date: format.yearFormString(datelong) + "年" |
| 119 | }) | 120 | }) |
| 120 | - }, | 121 | + }, |
| 121 | 122 | ||
| 122 | /** | 123 | /** |
| 123 | * Lifecycle function--Called when page hide | 124 | * Lifecycle function--Called when page hide |
| @@ -12,6 +12,7 @@ Page({ | @@ -12,6 +12,7 @@ Page({ | ||
| 12 | comlist: [], | 12 | comlist: [], |
| 13 | com_id: "", | 13 | com_id: "", |
| 14 | choosed_index: 0, | 14 | choosed_index: 0, |
| 15 | + scrollview_h:0, | ||
| 15 | chat_idx:"Toview"+0, | 16 | chat_idx:"Toview"+0, |
| 16 | chatlist: [] | 17 | chatlist: [] |
| 17 | }, | 18 | }, |
| @@ -21,6 +22,15 @@ Page({ | @@ -21,6 +22,15 @@ Page({ | ||
| 21 | */ | 22 | */ |
| 22 | onLoad: function(options) { | 23 | onLoad: function(options) { |
| 23 | this.getComList() | 24 | this.getComList() |
| 25 | + var that = this | ||
| 26 | + wx.getSystemInfo({ | ||
| 27 | + success: function (res) { | ||
| 28 | + that.setData({ | ||
| 29 | + scrollview_h: res.windowHeight-66 | ||
| 30 | + }) | ||
| 31 | + console.log("windowHeight",res.windowHeight) | ||
| 32 | + } | ||
| 33 | + }) | ||
| 24 | }, | 34 | }, |
| 25 | 35 | ||
| 26 | /** | 36 | /** |
| @@ -104,8 +114,15 @@ Page({ | @@ -104,8 +114,15 @@ Page({ | ||
| 104 | chatlist: that.data.chatlist | 114 | chatlist: that.data.chatlist |
| 105 | }) | 115 | }) |
| 106 | console.log("chatlist", that.data.chatlist) | 116 | console.log("chatlist", that.data.chatlist) |
| 117 | + wx.pageScrollTo({ | ||
| 118 | + scrollTop: 20000, | ||
| 119 | + duration: 300 | ||
| 120 | + }) | ||
| 107 | // that.getChatinfo() | 121 | // that.getChatinfo() |
| 108 | - that.bottom() | 122 | + // setTimeout(function(){ |
| 123 | + // that.bottom() | ||
| 124 | + // },400); | ||
| 125 | + | ||
| 109 | } | 126 | } |
| 110 | } | 127 | } |
| 111 | }) | 128 | }) |
| @@ -198,17 +215,21 @@ Page({ | @@ -198,17 +215,21 @@ Page({ | ||
| 198 | 215 | ||
| 199 | //聊天消息始终显示最底端 | 216 | //聊天消息始终显示最底端 |
| 200 | bottom: function () { | 217 | bottom: function () { |
| 201 | - var query = wx.createSelectorQuery() | ||
| 202 | - query.select('#flag').boundingClientRect() | ||
| 203 | - query.selectViewport().scrollOffset() | ||
| 204 | - query.exec(function (res) { | 218 | + // var query = wx.createSelectorQuery() |
| 219 | + // query.select('#flag').boundingClientRect() | ||
| 220 | + // query.selectViewport().scrollOffset() | ||
| 221 | + // query.exec(function (res) { | ||
| 222 | + // wx.pageScrollTo({ | ||
| 223 | + // scrollTop: res[0].bottom // #the-id节点的下边界坐标 | ||
| 224 | + // }) | ||
| 225 | + // res[1].scrollTop // 显示区域的竖直滚动位置 | ||
| 226 | + // }) | ||
| 227 | + wx.createSelectorQuery().select('#flag').boundingClientRect(function (rect) { | ||
| 228 | + // 使页面滚动到底部 | ||
| 205 | wx.pageScrollTo({ | 229 | wx.pageScrollTo({ |
| 206 | - scrollTop: res[0].bottom // #the-id节点的下边界坐标 | 230 | + scrollTop: rect.bottom |
| 207 | }) | 231 | }) |
| 208 | - res[1].scrollTop // 显示区域的竖直滚动位置 | ||
| 209 | - }) | ||
| 210 | - // var d = SmsListView.ActualHeight; | ||
| 211 | - // xxx.ScrollToVerticalOffset(d); | 232 | + }).exec() |
| 212 | }, | 233 | }, |
| 213 | 234 | ||
| 214 | /** | 235 | /** |
| 1 | <!--pages/main/smartchat/chat.wxml--> | 1 | <!--pages/main/smartchat/chat.wxml--> |
| 2 | <import src="../../../common/picker_cell" /> | 2 | <import src="../../../common/picker_cell" /> |
| 3 | 3 | ||
| 4 | -<view> | ||
| 5 | - <scroll-view style='background:#fff;margin-bottom:150rpx' scroll-y="true" > | 4 | +<view class='page'> |
| 5 | + <view style='background:#fff;margin-bottom:60px;width:100%;'> | ||
| 6 | <view wx:for="{{chatlist}}" wx:for-item="item" style='display:flex;flex-direction:column'> | 6 | <view wx:for="{{chatlist}}" wx:for-item="item" style='display:flex;flex-direction:column'> |
| 7 | <view style='margin:50rpx 60rpx 0 36rpx;display:flex;flex-direction:row' wx:if="{{item.type=='0'}}"> | 7 | <view style='margin:50rpx 60rpx 0 36rpx;display:flex;flex-direction:row' wx:if="{{item.type=='0'}}"> |
| 8 | <image style='width:102rpx;height:92rpx' src="/images/icon_robot.png"></image> | 8 | <image style='width:102rpx;height:92rpx' src="/images/icon_robot.png"></image> |
| @@ -19,17 +19,17 @@ | @@ -19,17 +19,17 @@ | ||
| 19 | </view> | 19 | </view> |
| 20 | </view> | 20 | </view> |
| 21 | </view> | 21 | </view> |
| 22 | - <view id="flag"></view> | ||
| 23 | - | ||
| 24 | - </scroll-view> | 22 | + <view id="flag"></view> |
| 23 | + </view> | ||
| 25 | <view class='bottom_wrap' id='bottom'> | 24 | <view class='bottom_wrap' id='bottom'> |
| 26 | <input class='input_wrap' placeholder-class='input_placeholder_wrap' bindinput="bindKeyInput" placeholder='请输入您要咨询的问题' value='{{inputValue}}'></input> | 25 | <input class='input_wrap' placeholder-class='input_placeholder_wrap' bindinput="bindKeyInput" placeholder='请输入您要咨询的问题' value='{{inputValue}}'></input> |
| 27 | <view class='btn_send_wrap' bindtap='sendMsg'>发送</view> | 26 | <view class='btn_send_wrap' bindtap='sendMsg'>发送</view> |
| 28 | </view> | 27 | </view> |
| 29 | </view> | 28 | </view> |
| 30 | 29 | ||
| 30 | + | ||
| 31 | <!-- 自定义弹窗 --> | 31 | <!-- 自定义弹窗 --> |
| 32 | -<view class="mask" catchtouchmove="preventTouchMove" hidden="{{!showModal}}"></view> | 32 | +<view class="mask" hidden="{{!showModal}}"></view> |
| 33 | <view class='modal_lg' hidden="{{!showModal}}"> | 33 | <view class='modal_lg' hidden="{{!showModal}}"> |
| 34 | <text class="text_title">您在多个单位有任职信息,请选择您要在哪家单位咨询问题。</text> | 34 | <text class="text_title">您在多个单位有任职信息,请选择您要在哪家单位咨询问题。</text> |
| 35 | <view class='divide_line_f5f5f5'></view> | 35 | <view class='divide_line_f5f5f5'></view> |
请
注册
或
登录
后发表评论