Browse Source

首页升级

master
vee 3 years ago
parent
commit
5d5cf94658
  1. BIN
      .DS_Store
  2. 7
      manifest.json
  3. 90
      pages/home/index.vue
  4. 4
      pages/subscription/details.vue

BIN
.DS_Store

Binary file not shown.

7
manifest.json

@ -2,8 +2,8 @@
"name" : "Same home",
"appid" : "__UNI__C4028F6",
"description" : "",
"versionName" : "1.0.3",
"versionCode" : 103,
"versionName" : "1.0.4",
"versionCode" : 104,
"transformPx" : false,
/* 5+App */
"app-plus" : {
@ -16,6 +16,9 @@
"autoclose" : true,
"delay" : 0
},
"compatible" : {
"ignoreVersion" : true //trueHBuilderX1.9.0
},
/* */
"modules" : {
"VideoPlayer" : {}

90
pages/home/index.vue

@ -30,7 +30,7 @@
<!-- #endif -->
</u-swiper>
<!-- 消息 -->
<view class="message" @click="go('/pages/me/notification')">
<view class="message" @click="go('inner','/pages/me/notification')">
<u-icon class="icon" name="../../static/home/ic_proclamation.png" size="60rpx" width="60rpx">
</u-icon>
<!-- <view class="text">{{ i18n.homeMessage }}</view> -->
@ -62,18 +62,10 @@
</view>
</view>
<!-- 步数 -->
<view class="steps">
<view class="content">
<view class="title">{{ i18n.CaringForWomen }}</view>
<view class="slogan">{{ i18n.LoveFeminist }}<br>{{ i18n.LoveFeminist1 }}</view>
<!-- <canvas id="chart" ref="chart" style="width: 280rpx;height:280rpx; font-size: 40rpx;"></canvas> -->
<u-button class="button" color="#00E8A2" @click="getCharity">{{ i18n.checkTheDetails }}
</u-button>
<view v-for="(item, index) in middleList" :key="index">
<view class="steps" >
<image :src="baseURL+item.adImgPath" @click="go(item.content,item.adUrl)"></image>
</view>
</view>
@ -85,7 +77,7 @@
<!-- 播放器 -->
<view class="videoList" v-for="(item, index) in videoList" :key="index" @click="playVideo(item.adText)">
<view class="videoImage" :style="`background-image: url(${baseURL+item.adImgPath});background-repeat: no-repeat;
<view v-show="item.adText!=''" class="videoImage" :style="`background-image: url(${baseURL+item.adImgPath});background-repeat: no-repeat;
background-size: cover;`">
<view class="VideoBg">
<view class="VideoLogo"></view>
@ -182,16 +174,18 @@
stepsNum: 0, //
stepTarget: 5000, //
myChart: null,
middleList:null
}
},
onLoad() {
this.baseURL = constant.BASE_URL
this.getbanner();
this.getMiddle();
this.noticeList();
this.getUserInfoBalance();
// #ifdef APP-PLUS
// this.appVersion()
this.appVersion()
// #endif
},
@ -236,7 +230,13 @@
logOut() {
plus.runtime.openURL(this.conInfo.appUrl);
},
getMiddle(){
api.indexBanner({
'mark': 'APP_INDEX_MIDDLE'
}).then(res => {
this.middleList=res
})
},
// APP
appVersion() {
console.log("校验APP应用版本", uni.getSystemInfoSync().platform)
@ -250,7 +250,7 @@
// console.log(wgtinfo.versionCode, response.versionCode)
let param = {
'appId': uni.getSystemInfoSync().platform,
'versionCode': '1.0.0'
'versionCode': wgtinfo.version
}
console.log(param)
this.$api.appVersion(param).then(response => {
@ -332,13 +332,21 @@
},
bannerClick(i) {
// #ifdef APP-PLUS
plus.runtime.openURL(this.bannerList[i])
// #endif
// #ifdef H5
var href = this.bannerList[i]
window.open(href, '_blank');
// #endif
if(this.bannerList[i].content=='inner'){
uni.navigateTo({
url: this.bannerList[i].adUrl
})
}else{
// #ifdef APP-PLUS
plus.runtime.openURL(this.bannerList[i].adUrl)
// #endif
// #ifdef H5
var href = this.bannerList[i].adUrl
window.open(href, '_blank');
// #endif
}
},
//
@ -461,10 +469,21 @@
},
go(url) {
uni.navigateTo({
url: url
})
go(type,url) {
if(type=='inner'){
uni.navigateTo({
url: url
})
}else{
// #ifdef APP-PLUS
plus.runtime.openURL(url)
// #endif
// #ifdef H5
var href = url
window.open(href, '_blank');
// #endif
}
},
@ -491,7 +510,10 @@
// this.bannerList = res
for (var i = 0; i < res.length; i++) {
this.swiperList.push(this.baseURL + res[i].adImgPath)
this.bannerList.push(res[i].adUrl)
this.bannerList.push({
content:res[i].content,
adUrl:res[i].adUrl
})
}
this.videoList = res
// banner
@ -925,13 +947,13 @@
.steps {
margin: 0 32rpx;
width: 686rpx;
height: 472rpx;
background-color: #211F32;
background-image: url(../../static/home/img_People.png);
background-repeat: no-repeat;
background-size: contain;
border-radius: 16px;
margin-top: 32rpx;
image{
width: 100%;
border-radius: 16px;
}
.content {
//margin-left: 246rpx;

4
pages/subscription/details.vue

@ -54,8 +54,8 @@
<!-- ProjectDetails -->
<view class="contentTitle">
<view class="ProjectDetails">{{ i18n.ProjectDetails }}</view>
<view class="videoBtn" @click="playVideo(deinfo.sysCoinInfo.videoWebsite)">{{ i18n.Video }}</view>
<view class="whiteBook" @click="getContact('book')">{{ i18n.WhiteBook }}</view>
<view class="videoBtn" v-show="deinfo.sysCoinInfo.videoWebsite!=''" @click="playVideo(deinfo.sysCoinInfo.videoWebsite)">{{ i18n.Video }}</view>
<view class="whiteBook" v-show="deinfo.sysCoinInfo.whitePaperWebsite!=''" @click="getContact('book')">{{ i18n.WhiteBook }}</view>
</view>
<!-- 文字内容 -->

Loading…
Cancel
Save