Browse Source

Merge branch 'release'

master tagv1.5.3
lihenian 5 years ago
parent
commit
80da62a4f8
  1. 26
      pages/indexNew/indexNew.js
  2. 3
      pages/indexNew/indexNew.wxml
  3. 12
      pages/indexNew/indexNew.wxss
  4. 2
      pages/toRegister/toRegister.js
  5. 13
      project.config.json
  6. 3
      utils/api.js

26
pages/indexNew/indexNew.js

@ -50,11 +50,9 @@ Page({
title: "e锦水", //导航栏 中间的标题 title: "e锦水", //导航栏 中间的标题
}, },
height: app.globalData.height * 2 + 20, height: app.globalData.height * 2 + 20,
infoObj: { infoObj: [],
time: "", informationNum: 0, //新消息数量
title: "", unreadSignUpActNum: 0, //未查看报名中活动数量
amount: ""
},
noticeList: [], noticeList: [],
innerHtmlStatus: true, innerHtmlStatus: true,
visibilityStatus: true, visibilityStatus: true,
@ -292,14 +290,21 @@ Page({
getFirstInfo: function () { getFirstInfo: function () {
let that = this let that = this
api.getFirstInfo().then(function (res) { api.getFirstInfo().then(function (res) {
// console.log('infoObj', res.data)
if (res.data !== null) { if (res.data !== null) {
that.data.infoObj = [ ...res.data ]
that.data.infoObj.forEach(item => {
if (item.dataType == 'informationNum') {
that.setData({ that.setData({
infoObj: res.data informationNum: item.num
})
}
if (item.dataType == 'unreadSignUpActNum') {
that.setData({
unreadSignUpActNum: item.num
})
}
}) })
} }
// console.log('zheli', that.data.infoObj)
}) })
}, },
getNoticeList: function () { getNoticeList: function () {
@ -310,14 +315,11 @@ Page({
} }
let that = this let that = this
api.noticelist(para).then(function (res) { api.noticelist(para).then(function (res) {
// console.log('infoObj', res.data)
if (res.data !== null) { if (res.data !== null) {
that.setData({ that.setData({
noticeList: res.data noticeList: res.data
}) })
} }
// console.log('zheli', that.data.infoObj)
}) })
}, },
// 根据微信code查询用户当前状态 // 根据微信code查询用户当前状态

3
pages/indexNew/indexNew.wxml

@ -20,7 +20,7 @@
<image src="../../images/home/signined.png" wx:else /> <image src="../../images/home/signined.png" wx:else />
</view> </view>
<view class="my-and-news"> <view class="my-and-news">
<image wx:if="{{infoObj.title == ''}}" bindtap="noMore" class="news" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/05/rBAB716nk4yASWCrAAAKA-kIkt0142.png" /> <image wx:if="{{informationNum == 0}}" bindtap="noMore" class="news" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/05/rBAB716nk4yASWCrAAAKA-kIkt0142.png" />
<image wx:else bindtap="toInfoList" class="news" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/07/rBAB7161EWKAIXwXAAAD4DwRkd4543.png" /> <image wx:else bindtap="toInfoList" class="news" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/07/rBAB7161EWKAIXwXAAAD4DwRkd4543.png" />
<!-- <image bindtap="toMine" class="my" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/06/rBAB716n_HiAZ9BOAAAIkMWBOnA191.png" /> --> <!-- <image bindtap="toMine" class="my" src="https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/06/rBAB716n_HiAZ9BOAAAIkMWBOnA191.png" /> -->
</view> </view>
@ -99,6 +99,7 @@
</button> </button>
<view class="weui-btn-right"> <view class="weui-btn-right">
<button bindtap="goheart" class="weui-btn-top" form-type='submit' plain='true' hover-class="hover-btn"> <button bindtap="goheart" class="weui-btn-top" form-type='submit' plain='true' hover-class="hover-btn">
<view class="is-unread" wx:if="{{unreadSignUpActNum > 0}}"></view>
<image src='https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/06/rBAB7161BqiAGT25AADji64eXU8518.png'></image> <image src='https://epdc-kongcun.elinkit.com.cn/epdcFile/M00/00/06/rBAB7161BqiAGT25AADji64eXU8518.png'></image>
</button> </button>
<button bindtap="dqhd" class="weui-btn-top" form-type='submit' plain='true' hover-class="hover-btn"> <button bindtap="dqhd" class="weui-btn-top" form-type='submit' plain='true' hover-class="hover-btn">

12
pages/indexNew/indexNew.wxss

@ -473,12 +473,24 @@ page {
width: 100%; width: 100%;
padding: 0; padding: 0;
border: none; border: none;
position: relative;
} }
.weui-btn-top+.weui-btn-top { .weui-btn-top+.weui-btn-top {
margin-top: 0 !important; margin-top: 0 !important;
} }
.grid-all-new .weui-btn-right .weui-btn-top .is-unread {
width: 14rpx;
height: 14rpx;
background-color: red;
border-radius: 50%;
border: 2rpx solid white;
position: absolute;
right: 50rpx;
top: 30rpx;
}
.grid-all-new .weui-btn-right .weui-btn-top image { .grid-all-new .weui-btn-right .weui-btn-top image {
height: 100%; height: 100%;
width: 100%; width: 100%;

2
pages/toRegister/toRegister.js

@ -21,7 +21,7 @@ Page({
// } // }
// }) // })
let that = this let that = this
const versionNum = "1.5.2" const versionNum = "1.5.3"
api.getScanSwitch(versionNum).then(function (res) { api.getScanSwitch(versionNum).then(function (res) {
console.log(res.data) console.log(res.data)
let state = res.data.scanFlag let state = res.data.scanFlag

13
project.config.json

@ -43,28 +43,19 @@
"hidedInDevtools": [] "hidedInDevtools": []
}, },
"scripts": {}, "scripts": {},
"simulatorType": "wechat",
"simulatorPluginLibVersion": {},
"condition": { "condition": {
"search": {
"current": -1,
"list": []
},
"conversation": {
"current": -1,
"list": []
},
"plugin": { "plugin": {
"current": -1,
"list": [] "list": []
}, },
"game": { "game": {
"list": [] "list": []
}, },
"gamePlugin": { "gamePlugin": {
"current": -1,
"list": [] "list": []
}, },
"miniprogram": { "miniprogram": {
"current": -1,
"list": [ "list": [
{ {
"id": 0, "id": 0,

3
utils/api.js

@ -80,7 +80,8 @@ function getProjectList (param) {
} }
function getFirstInfo () { function getFirstInfo () {
return fly.post("news/information/first") // return fly.post("news/information/first")
return fly.post("news/v2/information/first")
} }
function noticelist (param) { function noticelist (param) {

Loading…
Cancel
Save