Browse Source

优化

master
zhaoyongnian 5 years ago
parent
commit
fd3112274c
  1. 34
      pages/heartNew/heartNew.js
  2. 4
      subpages/heart/pages/leaderboardNew/leaderboardNew.js
  3. 2
      subpages/heart/pages/leaderboardNew/leaderboardNew.wxml
  4. 3
      subpages/heart/pages/leaderboardNew/leaderboardNew.wxss
  5. 15
      subpages/heart/pages/volunteer/volunteer.js
  6. 6
      subpages/heart/pages/volunteer/volunteer.wxml

34
pages/heartNew/heartNew.js

@ -67,22 +67,24 @@ Page({
* 生命周期函数--监听页面显示 * 生命周期函数--监听页面显示
*/ */
onShow: function () { onShow: function () {
// if (this.data.selectedTab === 'tab3') { this.setData({
// this.setData({ loadMoreVisible: false,
// selectedTab: 'tab0', loadMoreType: 'none',
// dingdan: false,//判断订单列表隐藏 indexPage: 1,
// jingcai: true,//判断精彩列表隐藏 })
// qkdat: true if(this.data.selectedTab == 'tab1'){//刷新志友
// }) this.setData({
// let parms = { dingdan: true,
// pageIndex: 1, jingcai: true,
// pageSize: this.data.pageSize, volunteerlist:[],//列表置空
// qkdat: this.data.qkdat, listLength:0
// timestamp: getTimestamp(), })
// actType: 0 let parms = {
// } pageIndex: this.data.indexPage,
// this.selectComponent("#state-0").getActivityList(parms) pageSize: this.data.pageSize,
// } }
this.volunteerlist(parms)
}
if (this.data.actId) { if (this.data.actId) {
this.updateActivityList() this.updateActivityList()
} }

4
subpages/heart/pages/leaderboardNew/leaderboardNew.js

@ -102,7 +102,9 @@ Page({
* 生命周期函数--监听页面显示 * 生命周期函数--监听页面显示
*/ */
onShow: function () { onShow: function () {
this.pulldownRefresh() if(this.data.selectTab == 'tab2'){
this.pulldownRefresh()
}
if (!app.globalData.previewImage) { if (!app.globalData.previewImage) {
console.log('过滤previewImage引起的onShow') console.log('过滤previewImage引起的onShow')
} }

2
subpages/heart/pages/leaderboardNew/leaderboardNew.wxml

@ -8,7 +8,7 @@
</view> </view>
<!-- 积分排行 --> <!-- 积分排行 -->
<block wx:if="{{selectTab === 'tab1'}}"> <block wx:if="{{selectTab === 'tab1'}}">
<view class="bottom"> <view class="bottom padding">
<block wx:if="{{loveRankingList.length === 0 && preloadVisible}}"> <block wx:if="{{loveRankingList.length === 0 && preloadVisible}}">
<preload-loveranking-item wx:for="{{[1,2,3,4]}}" wx:for-index="index" wx:key="index"> <preload-loveranking-item wx:for="{{[1,2,3,4]}}" wx:for-index="index" wx:key="index">
</preload-loveranking-item> </preload-loveranking-item>

3
subpages/heart/pages/leaderboardNew/leaderboardNew.wxss

@ -103,6 +103,9 @@ button::after {
margin-top: 17rpx; margin-top: 17rpx;
/* padding: 0 30rpx; */ /* padding: 0 30rpx; */
} }
.padding{
padding: 0 30rpx;
}
.bottom .love-ranking-list { .bottom .love-ranking-list {

15
subpages/heart/pages/volunteer/volunteer.js

@ -37,6 +37,7 @@ Page({
getMobileType: 'wx', getMobileType: 'wx',
smsCodeText: '获取验证码', smsCodeText: '获取验证码',
uploadImageList: [], uploadImageList: [],
disabled:false
}, },
onLoad: function(options) { onLoad: function(options) {
this.getPrepareComplete().then(res => { this.getPrepareComplete().then(res => {
@ -377,6 +378,7 @@ Page({
_this.setData({ _this.setData({
uploadImageList: [], uploadImageList: [],
disabled:true
}) })
$wuxActionSheet().showSheet({ $wuxActionSheet().showSheet({
buttons: [ buttons: [
@ -417,7 +419,8 @@ Page({
}) })
_this.setData({ _this.setData({
volunteerFaceImg:uploadImageList[0].ossUrl volunteerFaceImg:uploadImageList[0].ossUrl,
disabled:false
}) })
console.log('>>>>>>>>>>>'+_this.data.volunteerFaceImg) console.log('>>>>>>>>>>>'+_this.data.volunteerFaceImg)
} }
@ -465,7 +468,8 @@ Page({
// }) // })
_this.setData({ _this.setData({
volunteerFaceImg:uploadImageList[0].ossUrl volunteerFaceImg:uploadImageList[0].ossUrl,
disabled:false
}) })
} }
}) })
@ -477,7 +481,12 @@ Page({
return true return true
}, },
cancelText: '取消', cancelText: '取消',
cancel() {}, cancel() {
_this.setData({
disabled:false
})
console.log(':::::::::::::::')
},
destructiveButtonClicked() {}, destructiveButtonClicked() {},
}) })
}, },

6
subpages/heart/pages/volunteer/volunteer.wxml

@ -74,7 +74,7 @@
<view class="head-portrait"> <view class="head-portrait">
<view class="head-portrait-name">昵称</view> <view class="head-portrait-name">昵称</view>
<view class="nickname"> <view class="nickname">
<input maxlength="10" class="nicknameinput" bindblur="nickname" bindinput="nickname" value="{{volunteerNickname}}" placeholder-class="placeholder-style" placeholder="请输入您的昵称" /> <input class="nicknameinput" bindblur="nickname" bindinput="nickname" value="{{volunteerNickname}}" placeholder-class="placeholder-style" placeholder="请输入您的昵称" />
</view> </view>
</view> </view>
@ -83,7 +83,7 @@
</view> </view>
<view class="info-box-last-v2"> <view class="info-box-last-v2">
<view class="introduce"> <view class="introduce">
<textarea placeholder-class="placeholder-style" value="{{volunteerSignature}}" placeholder="请输入您的签名" bindblur="volunteerSignature" bindinput="volunteerSignature" maxlength="20"></textarea> <textarea disabled= '{{disabled}}' placeholder-class="placeholder-style" value="{{volunteerSignature}}" placeholder="请输入您的签名" bindblur="volunteerSignature" bindinput="volunteerSignature" maxlength="20"></textarea>
</view> </view>
</view> </view>
@ -138,7 +138,7 @@
<view class="info-box-last"> <view class="info-box-last">
<view class="introduce"> <view class="introduce">
<textarea placeholder-class="placeholder-style" value="{{introduce}}" placeholder="请输入自我介绍、是否参加过公益活动、参加了哪些公益活动" bindblur="adInputIntroduce" bindinput="adInputIntroduce" maxlength="500"></textarea> <textarea disabled= '{{disabled}}' placeholder-class="placeholder-style" value="{{introduce}}" placeholder="请输入自我介绍、是否参加过公益活动、参加了哪些公益活动" bindblur="adInputIntroduce" bindinput="adInputIntroduce" maxlength="500"></textarea>
</view> </view>
</view> </view>
</view> </view>

Loading…
Cancel
Save