Browse Source

优化

master
zhaoyongnian 6 years ago
parent
commit
e85c224f6c
  1. 11
      pages/heartNew/heartNew.js
  2. 4
      pages/heartNew/heartNew.wxml
  3. 4
      pages/heartNew/heartNew.wxss
  4. 10
      subpages/heart/pages/volunteer/volunteer.wxml
  5. 2
      subpages/heart/pages/volunteer/volunteer.wxss
  6. 7
      utils/activity.js
  7. 2
      utils/api.js

11
pages/heartNew/heartNew.js

@ -33,6 +33,7 @@ Page({
actId: '',//判断返回以后是否需要刷新列表 actId: '',//判断返回以后是否需要刷新列表
volunteerlist:[],//志愿者列表 volunteerlist:[],//志愿者列表
listLength:0,//数据长度判断是否需要加载 listLength:0,//数据长度判断是否需要加载
getImgUrl:''
}, },
/** /**
@ -40,6 +41,7 @@ Page({
*/ */
onLoad: function (options) { onLoad: function (options) {
this.bannerListV2() this.bannerListV2()
this.getImgUrl()//获取配置图片
this.setData({ this.setData({
statusHeight: app.globalData.deviceInfo.statusHeight, statusHeight: app.globalData.deviceInfo.statusHeight,
navigationHeight: app.globalData.deviceInfo.navigationHeight, navigationHeight: app.globalData.deviceInfo.navigationHeight,
@ -238,6 +240,15 @@ Page({
wx.stopPullDownRefresh(); wx.stopPullDownRefresh();
}) })
}, },
// 获取配置图片
getImgUrl:function(){//0:咨询热线
let that = this
api.getImgUrl('0').then(function (res) {
that.setData({
getImgUrl: res.data[0].imgUrl
})
})
},
/** /**
* 页面上拉触底事件的处理函数 * 页面上拉触底事件的处理函数
*/ */

4
pages/heartNew/heartNew.wxml

@ -4,7 +4,7 @@
<view class="goback" bindtap="goback"> <view class="goback" bindtap="goback">
<image src="../../images/goback.png" /> <image src="../../images/goback.png" />
</view> </view>
<view class="title"> <view class="title" bindtap="goback">
<view class="title-right">志愿者去哪儿</view> <view class="title-right">志愿者去哪儿</view>
</view> </view>
<!-- 志愿者去哪儿 --> <!-- 志愿者去哪儿 -->
@ -15,7 +15,7 @@
<image class="belong-grid-bg" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/06/rBAB7160-u6ATTx1AAEZrXGthow458.png" /> <image class="belong-grid-bg" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/06/rBAB7160-u6ATTx1AAEZrXGthow458.png" />
<view class="newbelong-grid"> <view class="newbelong-grid">
<view class="grid"> <view class="grid">
<image src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/09/rBAB717MflOADIYLAACi6KzN7k4722.png" /> <image src="{{getImgUrl}}" />
</view> </view>
<view class="volunteer" bindtap="govolunteer"> <view class="volunteer" bindtap="govolunteer">
<image src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/09/rBAB717MhrKAB80nAAApr5c7VJQ292.png" /> <image src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/09/rBAB717MhrKAB80nAAApr5c7VJQ292.png" />

4
pages/heartNew/heartNew.wxss

@ -50,7 +50,7 @@ page {
.header .navigation .title { .header .navigation .title {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; /* justify-content: center; */
width: calc(100% - 46rpx); width: calc(100% - 46rpx);
margin-left: 46rpx; margin-left: 46rpx;
color: rgba(255, 255, 255, 0.9); color: rgba(255, 255, 255, 0.9);
@ -59,7 +59,7 @@ page {
} }
.header .navigation .title .title-right { .header .navigation .title .title-right {
margin-right: 46rpx; /* margin-right: 46rpx; */
} }
.home { .home {

10
subpages/heart/pages/volunteer/volunteer.wxml

@ -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 value="{{volunteerSignature}}" placeholder="请输入您的签名" bindblur="volunteerSignature" bindinput="volunteerSignature" maxlength="20"></textarea> <textarea placeholder-class="placeholder-style" value="{{volunteerSignature}}" placeholder="请输入您的签名" bindblur="volunteerSignature" bindinput="volunteerSignature" maxlength="20"></textarea>
</view> </view>
</view> </view>
@ -99,15 +99,15 @@
<view class="clear"></view> <view class="clear"></view>
</view> </view>
<!-- <view class="info-box"> <view class="info-box">
<view class="address name"> <view class="address name">
{{gridName}} {{gridName}}
</view> </view>
</view> --> </view>
<view class="info-box"> <view class="info-box">
<view class="address name"> <view class="address name">
<input placeholder="请输入所在小区或所在道路" controlled value="{{road}}" bind:change="adInputStreet"></input> <input placeholder-class="placeholder-style" placeholder="请输入所在小区或所在道路" controlled value="{{road}}" bind:change="adInputStreet"></input>
</view> </view>
<view class="clear"></view> <view class="clear"></view>
</view> </view>
@ -138,7 +138,7 @@
<view class="info-box-last"> <view class="info-box-last">
<view class="introduce"> <view class="introduce">
<textarea value="{{introduce}}" placeholder="请输入自我介绍、是否参加过公益活动、参加了哪些公益活动" bindblur="adInputIntroduce" bindinput="adInputIntroduce" maxlength="500"></textarea> <textarea placeholder-class="placeholder-style" value="{{introduce}}" placeholder="请输入自我介绍、是否参加过公益活动、参加了哪些公益活动" bindblur="adInputIntroduce" bindinput="adInputIntroduce" maxlength="500"></textarea>
</view> </view>
</view> </view>
</view> </view>

2
subpages/heart/pages/volunteer/volunteer.wxss

@ -206,7 +206,7 @@ textarea {
overflow: hidden; overflow: hidden;
} }
.basic-info .list-item .right .placeholder-style { .placeholder-style {
font-size: 28rpx; font-size: 28rpx;
color: #999; color: #999;
} }

7
utils/activity.js

@ -3,7 +3,8 @@ module.exports = {
getActivityList: getActivityList, getActivityList: getActivityList,
bannerList, bannerList,
bannerListV2, bannerListV2,
volunteerlist volunteerlist,
getImgUrl
} }
function getActivityList(params) { function getActivityList(params) {
@ -21,3 +22,7 @@ function bannerListV2() {
function volunteerlist(params) { function volunteerlist(params) {
return fly.get('app-user/volunteer/list',params) return fly.get('app-user/volunteer/list',params)
} }
// 获取配置图片
function getImgUrl(imgType) {
return fly.get(`imgConfig/getImgUrl/${imgType}`)
}

2
utils/api.js

@ -133,7 +133,7 @@ function gridLeaderRegister(mobile, smsCode, wxCode) {
function prepareComplete() { function prepareComplete() {
return fly.get('app-user/user/getInfoById', {}) return fly.get('app-user/user/prepareComplete', {})
} }
function sendSms(mobile) { function sendSms(mobile) {

Loading…
Cancel
Save