<template>
|
<view class="weidian">
|
<view class="weidian_head">
|
<!-- #ifdef MP-WEIXIN || APP-PLUS -->
|
<view class="ww100" :style="'height:'+topBarTop()+'px;'"></view>
|
<view class="tc head_top" :style="topBarHeight() == 0 ? '': 'height:'+topBarHeight()+'px;'">
|
<view class="reg180" @click="goback"><text class="icon iconfont icon-jiantou"></text></view>
|
<view class="fb">配送点</view>
|
</view>
|
<!-- #endif -->
|
<view v-if="store_id>0">
|
<view class="p-0-30">
|
<view class="pt10 f30 black">
|
配送点:{{shop_data.store.store_name}}
|
</view>
|
<view class="pt10 f24 gray3">
|
地址:{{shop_data.store.address}}
|
</view>
|
<!-- <view class="pt10 f20 red">
|
提成比例:{{shop_data.store.commission_rate}}%;
|
(配送点提成=订单销售额*提成比例)
|
</view> -->
|
</view>
|
|
<view class="weidian_head_body_bottom">
|
<view class="weidian_head_body_bottom_item">
|
<view class="f24 gray3 mb20">累计提现(元)</view>
|
<text class="f36 gray3 fb">{{shop_data.store.cash_money}}</text>
|
</view>
|
<view class="weidian_head_body_bottom_item">
|
<view class="f24 gray3 mb20">累计成交(笔)</view>
|
<text class="f36 gray3 fb">{{shop_data.totalCount}}</text>
|
</view>
|
<view class="weidian_head_body_bottom_item">
|
<view class="f24 gray3 mb20">今日成交(笔)</view>
|
<text class="f36 gray3 fb">{{shop_data.todayCount}}</text>
|
</view>
|
<view class="weidian_head_body_bottom_item">
|
<view class="f24 gray3 mb20">可提现</view>
|
<text class="f36 gray3 fb">{{shop_data.store.money}}</text>
|
</view>
|
</view>
|
</view>
|
</view>
|
<view class="weidian_body">
|
<view class="seller_center_body_order">
|
<view class="seller_center_body_order_head">
|
<text class="f32 gray3 fb">配送点订单</text>
|
<text class="seller_center_body_order_head_more" @click="jumpPage('/pages2/delivery/order?fill=1')">全部订单<text
|
class="icon iconfont icon-jiantou f24"></text></text>
|
</view>
|
<view class="seller_center_body_order_body">
|
<view class="seller_center_body_order_body_item" v-for="(item,index) in order_menu_list" :key="index">
|
<view @click="jumpPage(item.url)">
|
<view class="icon-box pr">
|
<image :src="item.image" mode=""></image>
|
<text class="dot d-c-c" v-if="item.count">{{ item.count }}</text>
|
</view>
|
<view class="f26 gray3">{{item.title}}</view>
|
</view>
|
</view>
|
</view>
|
</view>
|
<!-- 订阅消息 by lyzflash -->
|
<!-- #ifdef MP-WEIXIN -->
|
<view class="set_message">
|
<view class="set_content">
|
<view class="set_txt">
|
<view class="set_txt_tit">点击开启,及时获取新订单通知</view>
|
</view>
|
<button class="set_btn" @click="setMessage" v-if="!is_seted">开启</button>
|
<button class="set_btn set_isseted" v-else>已开启</button>
|
</view>
|
</view>
|
<!-- #endif -->
|
<view class="weidian_body_menu_list m-0-20">
|
<view class="weidian_body_menu_list_item" v-for="(item,index) in menu_list" :key="index" @click="jumpPage(item.url)">
|
<view class="weidian_body_menu_list_left_icon">
|
<image class="left_iconimg" :src="item.left_icon" mode=""></image>
|
</view>
|
<view class="weidian_body_menu_list_title_left">{{item.title_left}}</view>
|
<view class="weidian_body_menu_list_right_icon icon iconfont icon-jiantou"></view>
|
<view class="weidian_body_menu_list_title_right"></view>
|
</view>
|
</view>
|
</view>
|
<view class="set_message_mark" v-if="is_open_setMark">
|
<view class="set_txt_note">请勾选底部的“总是保持以上选择,不再询问”</view>
|
</view>
|
</view>
|
</template>
|
|
<script>
|
export default {
|
data() {
|
return {
|
order_menu_list: [{
|
image: '/static/icon/pay.png',
|
title: '待支付',
|
url: '/pages2/delivery/order?dataType=payment',
|
count: 0
|
},
|
{
|
image: '/static/icon/daifahuo.png',
|
title: '待发货',
|
url: '/pages2/delivery/order?dataType=delivery',
|
count: 0
|
},
|
{
|
image: '/static/icon/daishouhuo.png',
|
title: '待收货',
|
url: '/pages2/delivery/order?dataType=received',
|
count: 0
|
},
|
{
|
image: '/static/icon/sell.png',
|
title: '退款/售后',
|
url: '/pages2/delivery/order?tianchong=1',
|
count: 0
|
},
|
],
|
menu_list: [{
|
title_left: '去提现',
|
title_right: '',
|
left_icon: '/static/icon/store_home.png',
|
right_icon: '',
|
url: '/pages2/delivery/cash/apply/apply'
|
},
|
{
|
title_left: '提现记录',
|
title_right: '',
|
left_icon: '/static/icon/store_data.png',
|
right_icon: '',
|
url: '/pages2/delivery/cash/list/list'
|
},
|
{
|
title_left: '结算明细',
|
title_right: '',
|
left_icon: '/static/icon/store_data.png',
|
right_icon: '',
|
url: '/pages2/delivery/settlement'
|
},
|
{
|
title_left: '配送员',
|
title_right: '',
|
left_icon: '/static/icon/store_data.png',
|
right_icon: '',
|
url: '/pages2/delivery/clerk'
|
}
|
],
|
shop_data: {
|
supplier: {}
|
},
|
user_id: '',
|
store_id: '',
|
is_open: 0,
|
is_full: 0,
|
statusBarHeight: 0,
|
titleBarHeight:0,
|
msg_count: 0,
|
/*小程序订阅消息*/
|
temlIds: [],
|
is_open_setMark: !1,
|
is_seted: !1
|
}
|
},
|
onShow() {
|
this.get_user_Data();
|
this.get_shop_Data();
|
},
|
onLoad() {
|
this.GetStatusBarHeight();
|
// #ifdef MP-WEIXIN
|
this.checkMessage();
|
// #endif
|
},
|
methods: {
|
GetStatusBarHeight() {
|
const SystemInfo = uni.getSystemInfoSync();
|
// #ifdef MP-WEIXIN
|
let statusBarHeight = SystemInfo.statusBarHeight;
|
this.statusBarHeight = uni.getMenuButtonBoundingClientRect().top;
|
this.titleBarHeight = uni.getMenuButtonBoundingClientRect().height;
|
// #endif
|
// #ifndef MP-WEIXIN
|
this.statusBarHeight = SystemInfo.statusBarHeight;
|
this.titleBarHeight = 30
|
// #endif
|
},
|
jumpPage(path) {
|
if(path.indexOf('?') != -1){
|
this.gotoPage(path + '&store_id=' + this.store_id);
|
}else{
|
this.gotoPage(path + '?store_id=' + this.store_id);
|
}
|
},
|
// 获取用户数据
|
get_user_Data() {
|
let self = this;
|
uni.showLoading({
|
title: '加载中'
|
})
|
self._get('user.index/detail', {
|
|
}, function(res) {
|
self.user_id = res.data.userInfo.user_id;
|
uni.hideLoading();
|
})
|
},
|
// 获取店铺成交数据
|
get_shop_Data() {
|
let self = this;
|
self._get('store.delivery/tradeData', {
|
platform: self.getPlatform()
|
}, function(res) {
|
self.shop_data = res.data;
|
self.is_full = res.data.supplier.is_full;
|
self.store_id = res.data.store.store_id;
|
self.temlIds = res.data.temlIds;
|
self.orderCount = res.data.orderCount;
|
self.order_menu_list[0].count = self.orderCount.payment;
|
self.order_menu_list[1].count = self.orderCount.delivery;
|
self.order_menu_list[2].count = self.orderCount.received;
|
// self.order_menu_list[3].count = self.orderCount.refund;
|
//self.menu_list[0].url = '/pages/shop/shop?store_id=' + self.store_id;
|
})
|
},
|
goback() {
|
uni.navigateBack();
|
},
|
//小程序订阅消息 by lyzflash
|
setMessage() {
|
let self = this;
|
let callback = function() {
|
self.is_open_setMark = !1;
|
self.checkMessage();
|
}
|
self.is_open_setMark = !0;
|
self.subMessage(self.temlIds, callback);
|
},
|
//检查是否已开启消息通知
|
checkMessage() {
|
let self = this;
|
wx.getSetting({
|
withSubscriptions: true,
|
success(res) {
|
if(self.temlIds[0] && self.temlIds[0] in res.subscriptionsSetting) {
|
self.is_seted = !0;
|
}
|
}
|
})
|
},
|
}
|
}
|
</script>
|
|
<style>
|
page {
|
background: #EBEBEB
|
}
|
|
.iconfont {
|
font-size: 14px;
|
}
|
|
.reg180 {
|
padding-right: 20rpx;
|
text-align: right;
|
transform: rotateY(180deg);
|
position: absolute;
|
bottom: 0;
|
}
|
|
.head_top .icon-jiantou {
|
color: #333333;
|
font-size: 30rpx;
|
}
|
|
.head_top {
|
width: 100%;
|
position: relative;
|
/* padding-top: var(--status-bar-height); */
|
height: 30px;
|
line-height: 30px;
|
color: #333333;
|
font-size: 36rpx;
|
}
|
|
.bg_topimg {
|
position: absolute;
|
top: 0;
|
width: 100%;
|
height: 400rpx;
|
z-index: -1;
|
}
|
|
.weidian {}
|
|
|
.weidian_head {
|
width: 100%;
|
padding-bottom: 195rpx;
|
/* height: 360rpx; */
|
background: linear-gradient(-90deg, #FFC89B 0%, #FFE3C4 100%);
|
}
|
|
.weidian_body {
|
margin-top: -170rpx;
|
position: relative;
|
}
|
|
.weidian_head_body_top {
|
width: 100%;
|
height: 200rpx;
|
}
|
|
.weidian_head_body_top_left {
|
width: 50%;
|
height: 200rpx;
|
display: inline-block;
|
font-size: 30rpx;
|
color: white;
|
padding-top: 40rpx;
|
padding-left: 45rpx;
|
box-sizing: border-box;
|
}
|
|
.weidian_head_body_top_left view {
|
margin-top: 20rpx;
|
}
|
|
.weidian_head_body_top_left image {
|
width: 36rpx;
|
height: 36rpx;
|
display: inline-block;
|
}
|
|
.weidian_head_body_top_right {
|
width: 30%;
|
display: inline-block;
|
position: relative;
|
top: -25rpx;
|
left: 120rpx;
|
}
|
|
.weidian_head_body_top_right button {
|
width: 82%;
|
height: 60rpx;
|
line-height: 60rpx;
|
border-radius: 30rpx;
|
color: #F36A23;
|
}
|
|
.weidian_head_body_bottom {
|
width: 100%;
|
padding-top: 50rpx;
|
box-sizing: border-box;
|
font-size: 26rpx;
|
display: flex;
|
justify-content: space-around;
|
align-items: center;
|
}
|
|
.weidian_head_body_bottom_item {
|
display: inline-block;
|
float: left;
|
color: white;
|
text-align: center;
|
}
|
|
/* 我的订单css */
|
.seller_center_body_order {
|
width: 710rpx;
|
background-color: white;
|
margin: 0 auto;
|
border-radius: 20rpx;
|
padding: 30rpx 24rpx 30rpx 30rpx;
|
box-sizing: border-box;
|
/* position: absolute; */
|
top: -170rpx;
|
left: 0;
|
right: 0;
|
}
|
|
.seller_center_body_order_head {
|
font-size: 30rpx;
|
border-bottom: 1rpx solid #D9D9D9;
|
padding-bottom: 20rpx;
|
display: flex;
|
justify-content: space-between;
|
align-items: flex-end;
|
}
|
|
.seller_center_body_order_head_more {
|
font-size: 26rpx;
|
color: #666666;
|
display: flex;
|
align-items: center;
|
}
|
|
.seller_center_body_order_head_more .icon-jiantou {
|
font-size: 24rpx;
|
color: #666666;
|
}
|
|
.seller_center_body_order_body {
|
width: 100%;
|
padding-top: 30rpx;
|
}
|
|
.seller_center_body_order_body_item {
|
display: inline-block;
|
width: 25%;
|
text-align: center;
|
}
|
|
.seller_center_body_order_body image {
|
width: 60rpx;
|
height: 60rpx;
|
margin: 0 auto;
|
margin-bottom: 14rpx;
|
}
|
|
/* 订单css END */
|
.weidian_body_menu_list {
|
/* width: 90%; */
|
padding-left: 24rpx;
|
font-size: 30rpx;
|
color: #484848;
|
background-color: #FFFFFF;
|
/* border-top: 120rpx solid #f2f2f2; */
|
border-radius: 16rpx;
|
margin-top: 30rpx;
|
}
|
|
.weidian_body_menu_list_item {
|
width: 97%;
|
height: 100rpx;
|
line-height: 100rpx;
|
border-bottom: 1rpx #D9D9D9 solid;
|
box-sizing: border-box;
|
}
|
|
.weidian_body_menu_list_item:last-child {
|
border-bottom: 0;
|
}
|
|
.weidian_body_menu_list_title_left {
|
display: inline-block;
|
float: left;
|
}
|
|
.weidian_body_menu_list_right_icon {
|
display: inline-block;
|
float: right;
|
font-size: 26rpx;
|
}
|
|
.weidian_body_menu_list_left_icon {
|
display: inline-block;
|
float: left;
|
margin-right: 10rpx;
|
}
|
|
.weidian_body_menu_list_title_right {
|
display: inline-block;
|
float: right;
|
color: #d5d5d5;
|
font-size: 24rpx;
|
position: relative;
|
/* top: 5rpx; */
|
margin-right: 5rpx;
|
}
|
|
.left_iconimg {
|
width: 36rpx;
|
height: 36rpx;
|
display: inline-block;
|
}
|
|
.set_message {
|
width: 100%;
|
height: 80rpx;
|
padding: 0 30rpx;
|
box-sizing: border-box;
|
margin-bottom: 30rpx;
|
margin-top: 30rpx;
|
}
|
|
.set_content {
|
display: flex;
|
justify-content: space-between;
|
align-items: center;
|
background: #ffffff;
|
/* box-shadow: 0 0 6rpx 0 rgba(0, 0, 0, 0.1); */
|
border-radius: 16rpx;
|
height: 100%;
|
padding: 0 20rpx;
|
}
|
|
.set_txt {}
|
|
.set_btn {
|
width: 134rpx;
|
height: 50rpx;
|
line-height: 50rpx;
|
font-size: 22rpx;
|
border-radius: 25rpx;
|
text-align: center;
|
color: #FFFFFF;
|
background-color: #e2231a;
|
}
|
|
.set_message_mark {
|
position: absolute;
|
width: 100%;
|
top: 0;
|
height: 100%;
|
z-index: 999;
|
background: rgba(0,0,0,0.8);
|
}
|
|
.set_txt_note {
|
position: absolute;
|
top: 400rpx;
|
color: #fff;
|
width: 100%;
|
text-align: center;
|
font-size: 28rpx;
|
}
|
|
.set_isseted {
|
background-color: #ccc;
|
}
|
|
.icon-box .dot {
|
position: absolute;
|
top: -10rpx;
|
right: 32rpx;
|
height: 25rpx;
|
min-width: 25rpx;
|
padding: 4rpx;
|
border-radius: 20rpx;
|
font-size: 20rpx;
|
background: #f00808;
|
color: #ffffff;
|
}
|
</style>
|