<image class="newImages9-5" src="{{imgUrl+'/newImages9/5.png'}}"></image> | <image class="newImages9-5" src="{{imgUrl+'/newImages9/5.png'}}"></image> | ||||
</view> | </view> | ||||
<view class="phases-group" wx:for="{{dateList}}" wx:key="index" bindtap="dateChange" data-index="{{index}}"> | <view class="phases-group" wx:for="{{dateList}}" wx:key="index" bindtap="dateChange" data-index="{{index}}"> | ||||
<view class="date-text date-choose" wx:if="{{index == 0}}">{{item.activity_date_show}}</view> | |||||
<view class="date-text" wx:else>{{item.activity_date_show}}</view> | |||||
<image class="newImages9-11" wx:if="{{index == 0}}" src="{{imgUrl+'/newImages9/11.png'}}"></image> | |||||
<view class="phases-state" wx:elif="{{index == 1}}">即将开始</view> | |||||
<view class="phases-state" wx:else>敬请期待</view> | |||||
<view class="date-text {{dateList[index]['activity_date']==dateChoose?'date-choose':''}}">{{item.activity_date_show}}</view> | |||||
<!-- <image class="newImages9-11" wx:if="{{index == 0}}" src="{{imgUrl+'/newImages9/11.png'}}"></image> --> | |||||
<view class="phases-state {{dateList[index]['activity_date']==dateChoose?'phases-state-bg':''}}" wx:if="{{index == 0}}">抢购中</view> | |||||
<view class="phases-state {{dateList[index]['activity_date']==dateChoose?'phases-state-bg':''}}" wx:elif="{{index == 1}}">即将开始</view> | |||||
<view class="phases-state {{dateList[index]['activity_date']==dateChoose?'phases-state-bg':''}}" wx:else>敬请期待</view> | |||||
</view> | </view> | ||||
</view> | </view> | ||||
<view class="goods-frame"> | <view class="goods-frame"> |
font-weight:500; | font-weight:500; | ||||
color:rgba(89,87,87,1); | color:rgba(89,87,87,1); | ||||
} | } | ||||
.phases-state-bg{ | |||||
padding: 5rpx 11rpx; | |||||
background-image: linear-gradient(to right,#ff134e,#ff4006); | |||||
color: #FFFFFF; | |||||
border-radius: 20rpx; | |||||
} | |||||
.goods-frame{ | .goods-frame{ | ||||
padding: 59rpx 21rpx 38rpx; | padding: 59rpx 21rpx 38rpx; | ||||
} | } |
* 页面上拉触底事件的处理函数 | * 页面上拉触底事件的处理函数 | ||||
*/ | */ | ||||
onReachBottom: function () { | onReachBottom: function () { | ||||
if(this.data.ismore){ | |||||
this.data.page++; | |||||
this.getFriendBargainList(); | |||||
} | |||||
}, | }, | ||||
/** | /** | ||||
* 用户点击右上角分享 | * 用户点击右上角分享 | ||||
*/ | */ | ||||
onShareAppMessage: function () { | onShareAppMessage: function () { | ||||
let goodsMsg = { | |||||
sku_id:this.data.goodsMsg.sku_id, | |||||
activity_token:this.data.goodsMsg.activity_token, | |||||
sku_name:this.data.goodsMsg.activity_token | |||||
} | |||||
return { | return { | ||||
title: "我正在以超低价购买"+this.data.goodsMsg.sku_name+"!有你帮忙还能更便宜!快来帮我!", | title: "我正在以超低价购买"+this.data.goodsMsg.sku_name+"!有你帮忙还能更便宜!快来帮我!", | ||||
imageUrl: this.data.imgUrl+'/newImages9/13.png', | imageUrl: this.data.imgUrl+'/newImages9/13.png', | ||||
path: "/pages/mountingsDetail/mountingsDetail?bargainType=2&datas="+JSON.stringify(this.data.goodsMsg) | |||||
path: "/pages/mountingsDetail/mountingsDetail?bargainType=2&datas="+JSON.stringify(goodsMsg) | |||||
} | } | ||||
}, | }, | ||||
ruleShowControl(){//控制活动规则的显示与隐藏 | ruleShowControl(){//控制活动规则的显示与隐藏 | ||||
getActivityJoinDetail(){//获取砍价活动进度详情 | getActivityJoinDetail(){//获取砍价活动进度详情 | ||||
app.wxRequest(app.globalData.urlRoot + "bargain/getActivityJoinDetail", {activity_token:this.data.goodsMsg.activity_token}, res => { | app.wxRequest(app.globalData.urlRoot + "bargain/getActivityJoinDetail", {activity_token:this.data.goodsMsg.activity_token}, res => { | ||||
if (res.code == 200) { | if (res.code == 200) { | ||||
res.data.surplus = (res.data.gap_money-res.data.success_money)/100; | |||||
res.data.gap_money = res.data.gap_money/100; | res.data.gap_money = res.data.gap_money/100; | ||||
res.data.success_money = res.data.success_money/100; | res.data.success_money = res.data.success_money/100; | ||||
res.data.surplus = res.data.gap_money-res.data.success_money; | |||||
res.data.percent = Math.ceil((1-res.data.surplus/res.data.gap_money)*100); | res.data.percent = Math.ceil((1-res.data.surplus/res.data.gap_money)*100); | ||||
this.setData({ | this.setData({ | ||||
activityJoinDetail:res.data | activityJoinDetail:res.data | ||||
}) | }) | ||||
} | } | ||||
}, this); | }, this); | ||||
}, | |||||
lookMore(){ | |||||
if(this.data.ismore){ | |||||
this.data.page++; | |||||
this.getFriendBargainList(); | |||||
} | |||||
} | } | ||||
}) | }) |
<!--pages/mountingsDetail/mountingsDetail.wxml--> | <!--pages/mountingsDetail/mountingsDetail.wxml--> | ||||
<view class="all"> | <view class="all"> | ||||
<view> | |||||
<scroll-view class="main" scroll-y="{{true}}" bindscrolltolower="lookMore"> | |||||
<view class="main"> | |||||
<!-- <scroll-view class="main" scroll-y="{{true}}" bindscrolltolower="lookMore"> --> | |||||
<view class="banner-group"> | <view class="banner-group"> | ||||
<swiper indicator-dots="true" style="width:750rpx;height:556rpx;"> | <swiper indicator-dots="true" style="width:750rpx;height:556rpx;"> | ||||
<swiper-item wx:for="{{goodsDetail.sku_banner}}" wx:key="index"> | <swiper-item wx:for="{{goodsDetail.sku_banner}}" wx:key="index"> | ||||
<image class="closeXieyi" bindtap="ruleShowControl" src="{{imgUrl+'/images/closeXieyi.png'}}"></image> | <image class="closeXieyi" bindtap="ruleShowControl" src="{{imgUrl+'/images/closeXieyi.png'}}"></image> | ||||
<image class="newImages9-12" src="{{imgUrl+'/newImages9/12.png'}}"></image> | <image class="newImages9-12" src="{{imgUrl+'/newImages9/12.png'}}"></image> | ||||
</view> | </view> | ||||
</scroll-view> | |||||
<view class="bottom-cushion"></view> | |||||
<!-- </scroll-view> --> | |||||
</view> | </view> | ||||
<tabBar></tabBar> | <tabBar></tabBar> | ||||
</view> | </view> |
view{ | view{ | ||||
-webkit-overflow-scrolling: touch; | -webkit-overflow-scrolling: touch; | ||||
} | } | ||||
.main{ | |||||
/* .main{ | |||||
height: calc(100vh - 120rpx); | height: calc(100vh - 120rpx); | ||||
overflow: auto; | |||||
} | |||||
} */ | |||||
.banner-group{ | .banner-group{ | ||||
position: relative; | position: relative; | ||||
width: 750rpx; | width: 750rpx; | ||||
} | } | ||||
.bargain-group{ | .bargain-group{ | ||||
width:694rpx; | width:694rpx; | ||||
height:330rpx; | |||||
padding-bottom:30rpx; | |||||
border-radius: 20rpx; | border-radius: 20rpx; | ||||
margin: 0 auto; | margin: 0 auto; | ||||
background-color: white; | background-color: white; | ||||
position: absolute; | position: absolute; | ||||
left: 50%; | left: 50%; | ||||
transform: translateX(-50%); | transform: translateX(-50%); | ||||
bottom: 0; | |||||
bottom: -3rpx; | |||||
width: 0; | width: 0; | ||||
height: 0; | height: 0; | ||||
border: 20rpx solid transparent; | border: 20rpx solid transparent; | ||||
color:rgba(52,84,128,1); | color:rgba(52,84,128,1); | ||||
line-height:36rpx; | line-height:36rpx; | ||||
} | } | ||||
.bottom-cushion{ | |||||
width: 100%; | |||||
height: 120rpx; | |||||
} | |||||
.wx-swiper-dots{ | .wx-swiper-dots{ | ||||
margin-bottom: 110rpx; | margin-bottom: 110rpx; | ||||
} | } | ||||