index
This commit is contained in:
parent
9e65d5d6e4
commit
3819a96576
@ -2,7 +2,9 @@ import {request} from "../../utils/bin"
|
|||||||
Page({
|
Page({
|
||||||
data:{
|
data:{
|
||||||
list:[],
|
list:[],
|
||||||
huilv:""
|
huilv:"",
|
||||||
|
background: ['#000', '#00ff00', '#ff0000'],
|
||||||
|
adlist:[]
|
||||||
},
|
},
|
||||||
onLoad(){
|
onLoad(){
|
||||||
request({
|
request({
|
||||||
@ -24,6 +26,14 @@ Page({
|
|||||||
huilv:res.data.data.exchange
|
huilv:res.data.data.exchange
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
request({
|
||||||
|
url:"index/adlist"
|
||||||
|
}).then((res)=>{
|
||||||
|
console.log(res)
|
||||||
|
this.setData({
|
||||||
|
adlist:res.data.data
|
||||||
|
})
|
||||||
|
})
|
||||||
},
|
},
|
||||||
searchs(){
|
searchs(){
|
||||||
console.log(10)
|
console.log(10)
|
||||||
|
@ -5,5 +5,19 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
.tishi{
|
||||||
|
width: 100%;
|
||||||
|
padding: 20rpx 40rpx;
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #333;
|
||||||
|
border-top:10rpx solid #eee;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
.oxs{
|
||||||
|
view:last-child{
|
||||||
|
border-bottom:10rpx solid #eee;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,20 @@
|
|||||||
<view class="box">
|
<view class="box">
|
||||||
<search bind:tap="searchs"></search>
|
<search bind:tap="searchs"></search>
|
||||||
|
<swiper indicator-dots="{{indicatorDots}}"
|
||||||
|
autoplay="{{true}}" interval="{{5000}}" duration="{{500}}" style="width:750rpx;height:375rpx;margin-top:20rpx">
|
||||||
|
<block wx:for="{{adlist.banners}}" wx:key="*this">
|
||||||
|
<swiper-item>
|
||||||
|
<image src="{{item.ad_code}}" style="width:100%;height:100%"></image>
|
||||||
|
</swiper-item>
|
||||||
|
</block>
|
||||||
|
</swiper>
|
||||||
|
<view class="oxs">
|
||||||
|
<view class="tishi" wx:for="{{adlist.texts}}">{{item.ad_name}}</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<!-- <view class="tishi">123123123123123123123</view> -->
|
||||||
|
<!-- <view class="tishi">123123123123123123123</view> -->
|
||||||
|
|
||||||
<list list="{{list}}" huilv="{{huilv}}"></list>
|
<list list="{{list}}" huilv="{{huilv}}"></list>
|
||||||
</view>
|
</view>
|
@ -1 +1 @@
|
|||||||
.box{border-top:#eaeaea solid 1rpx;width:750rpx;display:flex;align-items:center;flex-direction:column}
|
.box{border-top:#eaeaea solid 1rpx;width:750rpx;display:flex;align-items:center;flex-direction:column}.box .tishi{width:100%;padding:20rpx 40rpx;font-size:26rpx;color:#333;border-top:10rpx solid #eee;box-sizing:border-box}.box .oxs view:last-child{border-bottom:10rpx solid #eee}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user