| @@ -5,7 +5,8 @@ | |||||
| <view class='banner'> | <view class='banner'> | ||||
| <image src='{{data.coverImg}}'></image> | <image src='{{data.coverImg}}'></image> | ||||
| </view> | </view> | ||||
| <view class='act'> | |||||
| </view> | |||||
| <view class='act'> | |||||
| <text class='txt001'>{{data.title}}</text> | <text class='txt001'>{{data.title}}</text> | ||||
| <text class='txt002'>{{data.subTitle}}</text> | <text class='txt002'>{{data.subTitle}}</text> | ||||
| <view class="proct"> | <view class="proct"> | ||||
| @@ -21,8 +22,6 @@ | |||||
| <text><text class='spot'></text>{{data.detail}}</text> | <text><text class='spot'></text>{{data.detail}}</text> | ||||
| </view> | </view> | ||||
| </view> | </view> | ||||
| </view> | |||||
| <view class='contain clearfix'> | <view class='contain clearfix'> | ||||
| <!-- 优惠券 --> | <!-- 优惠券 --> | ||||
| <navigator wx:for="{{data.coupons}}" wx:key="{{index}}" url="/pages/coupon/detail/index?couponChannelId={{item.id}}&couponId={{item.couponId}}"> | <navigator wx:for="{{data.coupons}}" wx:key="{{index}}" url="/pages/coupon/detail/index?couponChannelId={{item.id}}&couponId={{item.couponId}}"> | ||||
| @@ -10,21 +10,24 @@ page { | |||||
| } | } | ||||
| .coupons-body { | .coupons-body { | ||||
| padding:40rpx 40rpx; | |||||
| flex: 1; | flex: 1; | ||||
| /* overflow: auto; */ | /* overflow: auto; */ | ||||
| } | } | ||||
| .banner { | .banner { | ||||
| position: relative; | position: relative; | ||||
| width: 750rpx; | |||||
| height: 280rpx; | |||||
| width: 670rpx; | |||||
| height: 300rpx; | |||||
| overflow: hidden; | overflow: hidden; | ||||
| box-shadow:0px 14px 26px 0px rgba(199,203,211,1); | box-shadow:0px 14px 26px 0px rgba(199,203,211,1); | ||||
| } | } | ||||
| .banner image { | .banner image { | ||||
| width: 750rpx; | |||||
| height: 280rpx; | |||||
| width: 670rpx; | |||||
| height: 300rpx; | |||||
| border-radius: 12rpx; | |||||
| } | } | ||||
| .act { | .act { | ||||
| @@ -34,7 +37,7 @@ page { | |||||
| border-radius: 12rpx; | border-radius: 12rpx; | ||||
| width: 100%; | width: 100%; | ||||
| /* height: 212rpx; */ | /* height: 212rpx; */ | ||||
| margin:44rpx auto 0; | |||||
| /* margin:44rpx auto 0; */ | |||||
| padding-bottom: 20rpx; | padding-bottom: 20rpx; | ||||
| } | } | ||||
| @@ -43,6 +43,7 @@ Page({ | |||||
| duihuan: imgurl.duihuan.url, | duihuan: imgurl.duihuan.url, | ||||
| market: app.globalData.market, | market: app.globalData.market, | ||||
| list: [], | list: [], | ||||
| xslist:[], | |||||
| loading: true, | loading: true, | ||||
| fistLogin: null, | fistLogin: null, | ||||
| alphaData: null, | alphaData: null, | ||||
| @@ -66,7 +67,11 @@ Page({ | |||||
| optionsData: null, | optionsData: null, | ||||
| credit: 0, | credit: 0, | ||||
| score: '0', | score: '0', | ||||
| page: 1 // 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载 | |||||
| page: 1 ,// 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载 | |||||
| // Ttitle:'', | |||||
| // xstitle:null, | |||||
| // priceStr:null, | |||||
| // salePriceStr:null, | |||||
| }, | }, | ||||
| close: function() { | close: function() { | ||||
| this.setData({ | this.setData({ | ||||
| @@ -329,6 +334,7 @@ Page({ | |||||
| that.getmemberId(app.globalData.token); | that.getmemberId(app.globalData.token); | ||||
| that.getBannerlist(); | that.getBannerlist(); | ||||
| that.topicShow(); | that.topicShow(); | ||||
| that.getxsList(); | |||||
| that.getMallInfo(app.globalData.token); | that.getMallInfo(app.globalData.token); | ||||
| if (app.couponChannelListCallback) { | if (app.couponChannelListCallback) { | ||||
| app.couponChannelListCallback(app.globalData.token); | app.couponChannelListCallback(app.globalData.token); | ||||
| @@ -444,6 +450,33 @@ Page({ | |||||
| // 不需要错误提示 | // 不需要错误提示 | ||||
| }); | }); | ||||
| }, | }, | ||||
| //获取限时抢购列表 | |||||
| getxsList(){ | |||||
| let that = this; | |||||
| Http.get({ | |||||
| url: config.api.couponChannelList, | |||||
| data: { | |||||
| pageNum: 1, | |||||
| pageSize: 3, | |||||
| targetAd: 2 | |||||
| } | |||||
| }).then(res => { | |||||
| if (res && res.data) { | |||||
| that.setData({ | |||||
| xslist: res.data.list, | |||||
| }); | |||||
| } | |||||
| }) | |||||
| .catch(err => { | |||||
| console.log(err) | |||||
| wx.showToast({ | |||||
| title: err.errMsg, | |||||
| icon: 'none', | |||||
| duration: 2000, | |||||
| mask: false | |||||
| }); | |||||
| }) | |||||
| }, | |||||
| /** | /** | ||||
| * banner | * banner | ||||
| */ | */ | ||||
| @@ -480,7 +513,7 @@ Page({ | |||||
| that.setData({ | that.setData({ | ||||
| name: res.data.name, | name: res.data.name, | ||||
| cover: res.data.cover, | cover: res.data.cover, | ||||
| title: res.data.title, | |||||
| Ttitle: res.data.title, | |||||
| id: res.data.id, | id: res.data.id, | ||||
| showTopic: true | showTopic: true | ||||
| }) | }) | ||||
| @@ -62,21 +62,24 @@ | |||||
| <view class='imgBox'> | <view class='imgBox'> | ||||
| <image src='{{toutiao}}' mode='aspectFill'></image> | <image src='{{toutiao}}' mode='aspectFill'></image> | ||||
| </view> | </view> | ||||
| <text>今日好货推荐,满1000减200元…</text> | |||||
| <view> | |||||
| 今日好物推荐, | |||||
| <text>'{{xslist[0].title}}'</text>原价 <text>{{xslist[0].priceStr}}</text> 现价... | |||||
| </view> | |||||
| <view class='qg' style='border-color:{{qg}}'><text>抢购</text></view> | <view class='qg' style='border-color:{{qg}}'><text>抢购</text></view> | ||||
| </view> | </view> | ||||
| <!-- 专题 --> | <!-- 专题 --> | ||||
| <view class='product' wx:if="{{showTopic}}"> | |||||
| <!-- <view class='ztTitle'>点击进入{{title}}</view> --> | |||||
| <view class='gift'> | |||||
| <image src='{{giftHr}}' bindtap='gotoTopic' mode='aspectFill' ></image> | |||||
| <view class='product' wx:if="{{showTopic}}" bindtap='gotoTopic'> | |||||
| <!-- <view class='ztTitle'>点击进入{{Ttitle}}</view> --> | |||||
| <view class='gift' > | |||||
| <image src='{{giftHr}}' mode='aspectFill' ></image> | |||||
| </view> | </view> | ||||
| <view class='textBox'> | <view class='textBox'> | ||||
| <view class='name'>{{name}}</view> | <view class='name'>{{name}}</view> | ||||
| <view class='title'>{{title}}</view> | <view class='title'>{{title}}</view> | ||||
| </view> | </view> | ||||
| <view class='next'> | <view class='next'> | ||||
| <image src='{{next}}' bindtap='gotoTopic' mode='aspectFill' ></image> | |||||
| <image src='{{next}}' mode='aspectFill' ></image> | |||||
| </view> | </view> | ||||
| <!-- <image src='{{cover}}' bindtap='gotoTopic' mode='aspectFill'></image> --> | <!-- <image src='{{cover}}' bindtap='gotoTopic' mode='aspectFill'></image> --> | ||||
| </view> | </view> | ||||
| @@ -426,12 +426,23 @@ progress{ | |||||
| margin-top: 18rpx; | margin-top: 18rpx; | ||||
| margin-bottom:18rpx; | margin-bottom:18rpx; | ||||
| } | } | ||||
| .toutiao text{ | |||||
| .toutiao view:nth-child(2){ | |||||
| font-size:26rpx; | font-size:26rpx; | ||||
| font-family:PingFangSC-Regular; | font-family:PingFangSC-Regular; | ||||
| font-weight:400; | font-weight:400; | ||||
| color:rgba(60,60,60,1); | color:rgba(60,60,60,1); | ||||
| float: left; | float: left; | ||||
| width: 500rpx; | |||||
| overflow: hidden; | |||||
| text-overflow:ellipsis; | |||||
| white-space: nowrap; | |||||
| } | |||||
| .toutiao view:nth-child(2) text:nth-child(1){ | |||||
| color: red; | |||||
| } | |||||
| .toutiao view:nth-child(2) text:nth-child(2){ | |||||
| text-decoration: line-through; | |||||
| color: red; | |||||
| } | } | ||||
| .toutiao .imgBox{ | .toutiao .imgBox{ | ||||
| width: 64rpx; | width: 64rpx; | ||||
| @@ -9,7 +9,8 @@ | |||||
| <view class='banner'> | <view class='banner'> | ||||
| <image src='{{data.coverImg}}' mode='widthFix'></image> | <image src='{{data.coverImg}}' mode='widthFix'></image> | ||||
| </view> | </view> | ||||
| <view class='box'> | |||||
| </view> | |||||
| <view class='box'> | |||||
| <view class='act'> | <view class='act'> | ||||
| <text class='txt001'>{{data.title}}</text> | <text class='txt001'>{{data.title}}</text> | ||||
| <text class='txt002'>{{data.subTitle}}</text> | <text class='txt002'>{{data.subTitle}}</text> | ||||
| @@ -25,8 +26,6 @@ | |||||
| <view class='time'>活动结束时间:{{activityEndTime}}</view> | <view class='time'>活动结束时间:{{activityEndTime}}</view> | ||||
| </view> | </view> | ||||
| </view> | </view> | ||||
| </view> | |||||
| </view> | </view> | ||||
| <!-- 自由图文格式 --> | <!-- 自由图文格式 --> | ||||
| <view wx:if="{{data.type == 2}}"> | <view wx:if="{{data.type == 2}}"> | ||||
| @@ -589,6 +589,7 @@ button::after{ border: none; } | |||||
| .banner image { | .banner image { | ||||
| width: 750rpx; | width: 750rpx; | ||||
| /* height: 280rpx; */ | /* height: 280rpx; */ | ||||
| border-radius: 16rpx; | |||||
| } | } | ||||
| .box{ | .box{ | ||||
| width: 100%; | width: 100%; | ||||
| @@ -6,8 +6,8 @@ | |||||
| <image src='{{data.advert}}' mode='widthFix'></image> | <image src='{{data.advert}}' mode='widthFix'></image> | ||||
| </view> | </view> | ||||
| <view class='act'> | <view class='act'> | ||||
| <text class='txt001'>{{data.name}}</text> | |||||
| <text class='txt002'>{{data.title}}</text> | |||||
| <view class='txt001'>{{data.name}}</view> | |||||
| <view class='txt002'>{{data.title}}</view> | |||||
| <view class="proct"> | <view class="proct"> | ||||
| <text>{{data.content}}</text> | <text>{{data.content}}</text> | ||||
| </view> | </view> | ||||
| @@ -12,12 +12,16 @@ | |||||
| .banner { | .banner { | ||||
| position: relative; | position: relative; | ||||
| width: 750rpx; | |||||
| width: 590rpx; | |||||
| /* box-shadow:0px 14px 26px 0px rgba(199,203,211,1); */ | |||||
| padding:50rpx 40rpx; | |||||
| height: 204rpx; | |||||
| } | } | ||||
| .banner image { | .banner image { | ||||
| display: block; | display: block; | ||||
| width: 750rpx; | |||||
| width: 670rpx; | |||||
| border-radius: 12rpx; | |||||
| } | } | ||||
| .act { | .act { | ||||
| @@ -25,20 +29,18 @@ | |||||
| z-index: 1000000000; | z-index: 1000000000; | ||||
| background: #fff; | background: #fff; | ||||
| border-radius: 12rpx; | border-radius: 12rpx; | ||||
| width: 705rpx; | |||||
| width: 100%; | |||||
| margin: 30rpx auto 0; | margin: 30rpx auto 0; | ||||
| padding-bottom: 20rpx; | padding-bottom: 20rpx; | ||||
| } | } | ||||
| .act text { | |||||
| display: block; | |||||
| text-align: center; | |||||
| .act view { | |||||
| padding-left: 4.8%; | padding-left: 4.8%; | ||||
| padding-right: 4.8%; | padding-right: 4.8%; | ||||
| } | } | ||||
| .txt001 { | .txt001 { | ||||
| display: block; | |||||
| /* display: block; */ | |||||
| font-size: 34rpx; | font-size: 34rpx; | ||||
| color: #363636; | color: #363636; | ||||
| letter-spacing: 0; | letter-spacing: 0; | ||||
| @@ -18,7 +18,8 @@ | |||||
| line-height: 1.8; | line-height: 1.8; | ||||
| } | } | ||||
| view{ | view{ | ||||
| word-break:break-all; overflow:auto; | |||||
| word-break:break-all; | |||||
| overflow:auto; | |||||
| background: #FFF; | background: #FFF; | ||||
| } | } | ||||
| .wxParse-inline{ | .wxParse-inline{ | ||||