首页banner图增加点击跳转页面

master
chen 2022-03-04 16:40:34 +08:00
parent 7aee8d4d55
commit dc4c52e857
8 changed files with 19 additions and 27 deletions

View File

@ -234,8 +234,6 @@
} }
}) })
this.dataList.concat(this.dataList); this.dataList.concat(this.dataList);
} else {
this.dataList = [];
} }
} else { } else {
this.$toolAll.tools.showToast(res.msg); this.$toolAll.tools.showToast(res.msg);

View File

@ -80,11 +80,4 @@
.container-loading .loading-box span:nth-child(2){border-radius: 50% 50% 50% 0;transform-origin: bottom left;animation-delay: .5s;} .container-loading .loading-box span:nth-child(2){border-radius: 50% 50% 50% 0;transform-origin: bottom left;animation-delay: .5s;}
.container-loading .loading-box span:nth-child(3){border-radius: 50% 0 50% 50%;transform-origin: top right;animation-delay: 1.5s;} .container-loading .loading-box span:nth-child(3){border-radius: 50% 0 50% 50%;transform-origin: top right;animation-delay: 1.5s;}
.container-loading .loading-box span:nth-child(4){border-radius: 0 50% 50% 50%;transform-origin: top left;animation-delay: 1s;} .container-loading .loading-box span:nth-child(4){border-radius: 0 50% 50% 50%;transform-origin: top left;animation-delay: 1s;}
scroll-view ::-webkit-scrollbar {
display: none !important;
width: 0 !important;
height: 0 !important;
-webkit-appearance: none;
background: transparent;
}
</style> </style>

View File

@ -96,6 +96,7 @@
// //
let pages = getCurrentPages(); let pages = getCurrentPages();
let route = pages[pages.length - 1].route; let route = pages[pages.length - 1].route;
console.log(route,99);
uni.setStorageSync('url',`/${route}?invite_code=${uni.getStorageSync('invite_code')}`); uni.setStorageSync('url',`/${route}?invite_code=${uni.getStorageSync('invite_code')}`);
this.log(route,'status-nav组件打印当前页面路径') this.log(route,'status-nav组件打印当前页面路径')
}, },

View File

@ -3,7 +3,7 @@
<view v-if="isDot" class="banner-box"> <view v-if="isDot" class="banner-box">
<swiper :current="bcurrent" @change="changeBanner" :style="{height: newHeight+'px'}" :autoplay="isplay" :circular="true" :interval="3000" :duration="500"> <swiper :current="bcurrent" @change="changeBanner" :style="{height: newHeight+'px'}" :autoplay="isplay" :circular="true" :interval="3000" :duration="500">
<swiper-item v-for="(item,index) in bannerList" :key="index"> <swiper-item v-for="(item,index) in bannerList" :key="index">
<view @tap="chooseImg(index)" class="img-box"> <view @tap="chooseImg(index,item.url)" class="img-box">
<image :style="{borderRadius:newRadius+'px',height:newHeight+'px'}" class="img animated fadeIn" :src="item.imgSrc" mode="aspectFill"></image> <image :style="{borderRadius:newRadius+'px',height:newHeight+'px'}" class="img animated fadeIn" :src="item.imgSrc" mode="aspectFill"></image>
<image @tap.stop="playVideo(index)" v-if="item.isVideo && isVedio" class="posia animated bounceIn" style="width: 126rpx;height: 126rpx;z-index: 1;" src="/static/public/video.png" mode=""></image> <image @tap.stop="playVideo(index)" v-if="item.isVideo && isVedio" class="posia animated bounceIn" style="width: 126rpx;height: 126rpx;z-index: 1;" src="/static/public/video.png" mode=""></image>
</view> </view>
@ -64,7 +64,7 @@
}; };
}, },
methods:{ methods:{
chooseImg(index){ chooseImg(index,url){
// console.log('banner',index); // console.log('banner',index);
this.bcurrent = index this.bcurrent = index
if(this.browseP){ if(this.browseP){
@ -95,7 +95,7 @@
}) })
} else { } else {
uni.navigateTo({ uni.navigateTo({
url:this.bannerList[index].url url:`/${url}`
}) })
} }
}, },

View File

@ -73,6 +73,11 @@ const request = (method, url, options) => {
if (res.data.code == 0) { if (res.data.code == 0) {
resolve(res.data) resolve(res.data)
} else { } else {
uni.showToast({
title:res.data.msg,
icon:'none',
position:'bottom'
})
resolve(res.data) resolve(res.data)
} }
} else { } else {

View File

@ -1,6 +1,6 @@
{ {
"name" : "佩利商城", "name" : "佩利商城",
"appid" : "__UNI__02EF3E2", "appid" : "__UNI__B0099F7",
"description" : "", "description" : "",
"versionName" : "1.0.0", "versionName" : "1.0.0",
"versionCode" : "100", "versionCode" : "100",
@ -68,10 +68,10 @@
/* */ /* */
"mp-weixin" : { "mp-weixin" : {
/* */ /* */
"appid" : "wxa02e44170bc722cd", "appid" : "wx2654bc27c419ada6",
"setting" : { "setting" : {
"urlCheck" : true, "urlCheck" : true,
"es6" : false "es6" : true
}, },
"usingComponents" : true, "usingComponents" : true,
"permission" : { "permission" : {

View File

@ -5,7 +5,7 @@
:ifTitle="true" :ifTitle="true"
:ifReturn="true" :ifReturn="true"
:ifCenter="true" :ifCenter="true"
:navBarTitle="'登录'"></status-nav> :navBarTitle="'用户服务协议'"></status-nav>
<!-- 容器 --> <!-- 容器 -->
<container-subgroup> <container-subgroup>
<view slot="content"> <view slot="content">
@ -19,20 +19,15 @@
export default { export default {
data(){ data(){
return { return {
content:'<p>1.用户协议谢谢洗诶诶黑货币的宁波</p>' content:'<p>1.用户协议谢谢授权的小姐姐,小哥哥。</p>'
} }
}, },
onLoad(options) { onLoad(options) {
if(uni.getStorageSync('phone_active')){ this.$requst.get('/api/index/agreement').then(res=>{
uni.removeStorageSync('transientUrl'); console.log(res,'用户协议');
} else { this.content = this.$toolAll.tools.escape2Html(res.data.content);
uni.setStorageSync('transientUrl',`/pages/login/agreement?invite_code=${options.invite_code}}`);
uni.navigateTo({
url:'/pages/login/login'
}) })
} }
this.$toolAll.tools.escape2Html(this.content)
}
} }
</script> </script>

View File

@ -21,7 +21,7 @@
<view v-if="isShowP" class="disjcac posAll"> <view v-if="isShowP" class="disjcac posAll">
<view class="bacf radius20 width100 tank-box"> <view class="bacf radius20 width100 tank-box">
<view class="tc tank-box-itemone">请授权绑定手机号</view> <view class="tc tank-box-itemone">请授权绑定手机号</view>
<view class="fon28 colf pad-x30 pad-zy30 tc disjb"> <view class="fon28 colf pad-sx30 pad-zy30 tc disjb">
<view class="pad-sx10 radius10 tank-btn" style="background-color: rgba(230, 230, 230,1);color: #000000;">暂不绑定</view> <view class="pad-sx10 radius10 tank-btn" style="background-color: rgba(230, 230, 230,1);color: #000000;">暂不绑定</view>
<view :style="{background:publicColor}" class="pad-sx10 radius10 tank-btn posir"> <view :style="{background:publicColor}" class="pad-sx10 radius10 tank-btn posir">
立即绑定 立即绑定