|
|
|
@ -6,36 +6,35 @@ |
|
|
|
<uni-icons type="left" size="28"></uni-icons> |
|
|
|
</view> |
|
|
|
<view class="title-name" :style="{'padding-top': menuButtonInfo.top +'px'}"> |
|
|
|
兼职中心 |
|
|
|
配送排位赛 |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<uni-notice-bar show-icon scrollable text="送单奖励活动开启:截止到当日24时,送单量前五名有额外奖励,奖励金额从高到低为20元/10元/8.8元/6.6元/5元,抓紧送单的奖励吧!" /> |
|
|
|
<uni-datetime-picker style="margin-bottom:10px;" v-model="range" @change="searchList" type="daterange" /> |
|
|
|
<uni-notice-bar v-if="reward != ''" show-icon scrollable :text="reward" /> |
|
|
|
|
|
|
|
<view class="paiming"> |
|
|
|
<view style="width: 200rpx;height: 100rpx;position: absolute;bottom: 30%;left: 6%;text-align: center;color: #fff;font-size: 34rpx;font-weight: bold;"> |
|
|
|
<view> |
|
|
|
{{fireList[2].productName == undefined?'':fireList[2].productName}} |
|
|
|
{{fireList[1].workerName == undefined?'':fireList[1].workerName}} |
|
|
|
</view> |
|
|
|
<view style="line-height: 60rpx;"> |
|
|
|
{{fireList[2].totalSold == undefined?'':fireList[2].totalSold}} |
|
|
|
{{fireList[1].orderCount == undefined?'':fireList[1].orderCount}} |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view style="width: 200rpx;height: 100rpx;position: absolute;top: 50%;left: 37%;text-align: center;color: #fff;font-size: 34rpx;font-weight: bold;"> |
|
|
|
<view> |
|
|
|
{{fireList[0].productName == undefined?'':fireList[0].productName}} |
|
|
|
{{fireList[0].workerName == undefined?'':fireList[0].workerName}} |
|
|
|
</view> |
|
|
|
<view style="line-height: 60rpx;"> |
|
|
|
{{fireList[0].totalSold == undefined?'':fireList[0].totalSold}} |
|
|
|
{{fireList[0].orderCount == undefined?'':fireList[0].orderCount}} |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view style="width: 200rpx;height: 100rpx;position: absolute;bottom: 27%;right: 6%;text-align: center;color: #fff;font-size: 34rpx;font-weight: bold;"> |
|
|
|
<view> |
|
|
|
{{fireList[1].productName == undefined?'':fireList[1].productName}} |
|
|
|
{{fireList[2].workerName == undefined?'':fireList[2].workerName}} |
|
|
|
</view> |
|
|
|
<view style="line-height: 60rpx;"> |
|
|
|
{{fireList[1].totalSold == undefined?'':fireList[1].totalSold}} |
|
|
|
{{fireList[2].orderCount == undefined?'':fireList[2].orderCount}} |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
@ -51,29 +50,15 @@ |
|
|
|
<uni-icons type="medal-filled" size='22' color="#f6bf6f"></uni-icons> |
|
|
|
</view> |
|
|
|
<view v-if="index != 0 && index != 1 && index != 2" style="width: 44rpx;justify-content: center;align-items: center;display: flex;">{{index + 1}}</view> |
|
|
|
<view class="box-left" @tap.stop="largeImg(item)"> |
|
|
|
<img :src="item.productPicture" alt="" v-if="item.productPicture"> |
|
|
|
<view class="noPic" v-else>暂无图片</view> |
|
|
|
<view class="box-left"> |
|
|
|
<img :src="item.icon || 'https://jewel-shop.oss-cn-beijing.aliyuncs.com/801c569079da4540990c1cc634186fdd.png'"/> |
|
|
|
</view> |
|
|
|
<view class="box-right"> |
|
|
|
<view class="box-right-num">{{item.productName == null?'暂无':item.productName}}</view> |
|
|
|
<view class="box-right-name">{{item.totalSold}}单</view> |
|
|
|
<view class="box-right-num">{{item.workerName == null?'暂无':item.workerName}}</view> |
|
|
|
<view class="box-right-name">{{item.orderCount}}单</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<u-loadmore :status="status" /> |
|
|
|
</view> |
|
|
|
<!-- 弹出多图轮播 --> |
|
|
|
<uni-popup ref="imgPopup" background-color="#fff"> |
|
|
|
<view class="showImg-box"> |
|
|
|
<swiper indicator-dots class="swiper-box" @change="lunbochange" circular autoplay :current="swiperDotIndex"> |
|
|
|
<swiper-item v-for="(item, index) in bigImg" :key="index"> |
|
|
|
<view class="swiper-item"> |
|
|
|
<image mode='aspectFit' show-menu-by-longpress :src="item.productPicture" alt="" style="width: 100%;height: 100%;border-radius: 10px;" /></image> |
|
|
|
</view> |
|
|
|
</swiper-item> |
|
|
|
</swiper> |
|
|
|
</view> |
|
|
|
</uni-popup> |
|
|
|
</view> |
|
|
|
</template> |
|
|
|
|
|
|
|
@ -83,11 +68,9 @@ |
|
|
|
return { |
|
|
|
menuButtonInfo: {}, |
|
|
|
range:[], |
|
|
|
status: 'loadmore', |
|
|
|
fireList:[], |
|
|
|
pageNum:1, |
|
|
|
pages:1, |
|
|
|
indexList: [], |
|
|
|
reward:'', |
|
|
|
bigImg:[], |
|
|
|
swiperDotIndex:0, |
|
|
|
|
|
|
|
@ -99,9 +82,6 @@ |
|
|
|
this.menuButtonInfo = uni.getMenuButtonBoundingClientRect() |
|
|
|
}, |
|
|
|
onReachBottom() { |
|
|
|
if (this.pageNum >= this.pages) return; |
|
|
|
this.status = 'loading'; |
|
|
|
this.pageNum ++; |
|
|
|
this.getFireList(); |
|
|
|
|
|
|
|
}, |
|
|
|
@ -110,23 +90,19 @@ |
|
|
|
this.current = e.detail.current |
|
|
|
}, |
|
|
|
getFireList(){ |
|
|
|
this.tui.request("/app/product/getShareList", "POST", { |
|
|
|
categoryId: "", |
|
|
|
searchStr: "", |
|
|
|
pageNum: this.pageNum, |
|
|
|
pageSize: '10', |
|
|
|
sortField:"totalSold", |
|
|
|
startDate:this.range[0], |
|
|
|
endDate:this.range[1] |
|
|
|
}, false, false).then((res) => { |
|
|
|
this.tui.request("/mall/delivery/countOrdersLimit", "GET", {regionId: JSON.parse(uni.getStorageSync('area')).id}, false, true).then((res) => { |
|
|
|
if (res.code == 200) { |
|
|
|
this.status = 'nomore'; |
|
|
|
if (this.pages == 1) { |
|
|
|
this.fireList = res.result.records |
|
|
|
} else { |
|
|
|
this.fireList = [...this.fireList, ...res.result.records] |
|
|
|
if(res.result.data != null){ |
|
|
|
this.fireList = res.result.data |
|
|
|
} |
|
|
|
|
|
|
|
if(res.result.reward != undefined && res.result.reward != null){ |
|
|
|
this.reward = '排位规则:' |
|
|
|
for(let i = 0; i < res.result.reward.length; i++){ |
|
|
|
this.reward += '第' + res.result.reward[i].orderNum + '名 - 奖励' + res.result.reward[i].reward + '元;' |
|
|
|
} |
|
|
|
this.pages = res.result.pages |
|
|
|
this.reward += '晚上10点截止' |
|
|
|
} |
|
|
|
} else { |
|
|
|
this.tui.toast(res.message) |
|
|
|
} |
|
|
|
|