417 lines
9.7 KiB
Vue
417 lines
9.7 KiB
Vue
<template>
|
|
<view class="">
|
|
<view v-if="orderList.length">
|
|
<view class="flex align-center margin-bottom-sm bg padding-sm radius margin-sm"
|
|
v-for="(item,index) in orderList" :key='index' @click="goOrder(item)"
|
|
style="box-shadow: 6rpx 10rpx 4px #F5F5F5;position: relative;">
|
|
<view style="position: absolute;z-index: 99;top: 0rpx;left: 0;" v-if="item.isGoods == 1">
|
|
<image
|
|
src="https://admin.sjajk.com/file/uploadPath/2023/02/16/c551f3f0721aec54208011e6948a57cd.png"
|
|
style="width: 42rpx;height: 36rpx;"></image>
|
|
</view>
|
|
<view style="width:200upx;height:200upx;border-radius: 10rpx;">
|
|
<image :src="item.artificerImg?item.artificerImg: '../../static/logo.png'"
|
|
@click.stop="saveImgs(item.artificerImg)"
|
|
style="width: 200upx;height: 200upx;border-radius: 50%;" mode="aspectFill"></image>
|
|
<image v-if="item.isHot == 1"
|
|
src="https://admin.sjajk.com/file/uploadPath/2023/02/16/9ae1b7e9fa931b5fc24cd8edecc10d9f.png"
|
|
style="width: 30rpx;height: 36rpx;position: absolute;z-index: 99;top: 40rpx;left: 110rpx;">
|
|
</image>
|
|
<!-- <view class="kyy_view" v-if="item.status == 1">可预约</view>
|
|
<view class="byy_view" v-else>休息中</view> -->
|
|
</view>
|
|
<view class="margin-left flex flex-direction" style="width: 85%;">
|
|
<view class="flex align-center justify-between">
|
|
<view class="flex align-center">
|
|
<view class="text-bold text-30 margin-right-xs">{{item.artificerName}}</view>
|
|
<image
|
|
src="https://admin.sjajk.com/file/uploadPath/2023/02/16/d45855dcf1e01210a4224a408225e8e0.png"
|
|
style="width: 40rpx;height:40rpx;">
|
|
</image>
|
|
</view>
|
|
</view>
|
|
<view class="flex justify-between " style="margin:15rpx 0rpx 20rpx">
|
|
<view class="flex align-center">
|
|
<view v-if="item.ordersScore" class="margin-right-sm">
|
|
<image src="../../static/images/start.png" style="width: 24upx;height: 22upx;">
|
|
</image>
|
|
<text class="margin-left-xs" style="color: #FF1200;">{{item.ordersScore}}.0</text>
|
|
</view>
|
|
<view style="color: #999999;">已服务:{{item.ordersCount}}单</view>
|
|
</view>
|
|
</view>
|
|
<view style="width: 100%;display: flex;justify-content: space-between;align-items: center;"
|
|
v-if="XCXIsSelect !='否'">
|
|
<view class="flex flex-wrap align-center" style="margin-top: 10rpx;">
|
|
<image src="../../static/images/shangjia.png" style="width: 26rpx;height: 26rpx;"></image>
|
|
<view style="margin-left: 10rpx;color: #999;font-size: 26rpx;margin-right: 50rpx;">商家</view>
|
|
<image src="../../static/images/pinglun.png" style="width: 29rpx;height: 29rpx;"></image>
|
|
<view style="margin-left: 10rpx;color: #999;font-size: 26rpx;margin-right: 20rpx;">
|
|
{{item.commentCount ? item.commentCount : 0}}
|
|
</view>
|
|
<image src="../../static/images/aixin2.png" style="width: 26rpx;height: 26rpx;margin-left: 40rpx;"></image>
|
|
<view style="margin-left: 10rpx;color: #999;font-size: 26rpx;">
|
|
{{item.collectCount ? item.collectCount : 0}}
|
|
</view>
|
|
</view>
|
|
<view class="text-center text-sm"
|
|
style="color: #096f4b;font-size: 28rpx;"
|
|
@click.stop="goOrder(item)">
|
|
¥{{item.money}}
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<empty v-if="orderList.length == 0"></empty>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import empty from '@/components/empty.vue'
|
|
export default {
|
|
components: {
|
|
empty
|
|
},
|
|
data() {
|
|
return {
|
|
consortiaId: '',
|
|
loading: true, // 是否显示骨架屏组件
|
|
orderList: [],
|
|
page: 1,
|
|
limit: 10,
|
|
token: '',
|
|
XCXIsSelect: '否',
|
|
isVip: false,
|
|
myId: uni.getStorageSync('userId') ? uni.getStorageSync('userId') : '',
|
|
}
|
|
},
|
|
onLoad(e) {
|
|
this.consortiaId = e.consortiaId;
|
|
let that = this
|
|
that.page = 1
|
|
that.getlist()
|
|
},
|
|
onShow() {
|
|
let that = this
|
|
that.XCXIsSelect = this.$queue.getData("XCXIsSelect");
|
|
that.token = uni.getStorageSync('token')
|
|
that.myId = uni.getStorageSync('userId')
|
|
},
|
|
methods: {
|
|
saveImgss(imgs, index) {
|
|
console.log(imgs, index)
|
|
let imgArr = imgs
|
|
// //预览图片
|
|
uni.previewImage({
|
|
urls: imgArr,
|
|
current: imgArr[index]
|
|
});
|
|
},
|
|
saveImgs(imgs) {
|
|
let imgArr = [];
|
|
imgArr.push(imgs);
|
|
// //预览图片
|
|
uni.previewImage({
|
|
urls: imgArr,
|
|
current: 0
|
|
});
|
|
},
|
|
getIsVip() {
|
|
this.$Request.get("/app/UserVip/isUserVip").then(res => {
|
|
if (res.code == 0) {
|
|
this.isVip = res.data
|
|
uni.setStorageSync('isVIP', res.data)
|
|
}
|
|
});
|
|
},
|
|
getlist() {
|
|
let userId = this.$queue.getData('userId');
|
|
let index = 2
|
|
let data = {
|
|
page: this.page,
|
|
limit: this.limit,
|
|
consortiaId: this.consortiaId,
|
|
shopId: userId
|
|
}
|
|
this.$Request.get("/app/consortia/selectUserListByConsortiaId", data).then(res => {
|
|
this.loading = false;
|
|
if (res.code == 0) {
|
|
if (this.page == 1) {
|
|
this.orderList = res.data.list
|
|
} else {
|
|
this.orderList = [...this.orderList, ...res.data.list]
|
|
}
|
|
}
|
|
uni.stopPullDownRefresh();
|
|
})
|
|
},
|
|
// 跳转游戏列表
|
|
goNav(url) {
|
|
if (uni.getStorageSync('sendMsg')) {
|
|
console.log('授权+1')
|
|
wx.requestSubscribeMessage({
|
|
tmplIds: this.arr,
|
|
success(re) {
|
|
console.log(JSON.stringify(re), 111111111111)
|
|
var datas = JSON.stringify(re);
|
|
if (datas.indexOf("accept") != -1) {
|
|
console.log(re)
|
|
}
|
|
},
|
|
fail: (res) => {
|
|
console.log(res)
|
|
}
|
|
})
|
|
}
|
|
if (url.indexOf('/pages/') !== -1) {
|
|
uni.navigateTo({
|
|
url
|
|
});
|
|
} else {
|
|
//#ifndef H5
|
|
uni.navigateTo({
|
|
url: '/pages/index/webView?url=' + url
|
|
});
|
|
//#endif
|
|
//#ifdef H5
|
|
window.location.href = url;
|
|
//#endif
|
|
}
|
|
},
|
|
// 跳转订单
|
|
goOrder(e) {
|
|
console.log('授权', uni.getStorageSync('sendMsg'))
|
|
if (uni.getStorageSync('sendMsg')) {
|
|
console.log('授权+1')
|
|
wx.requestSubscribeMessage({
|
|
tmplIds: this.arr,
|
|
success(re) {
|
|
console.log(JSON.stringify(re), 111111111111)
|
|
var datas = JSON.stringify(re);
|
|
if (datas.indexOf("accept") != -1) {
|
|
console.log(re)
|
|
}
|
|
},
|
|
fail: (res) => {
|
|
console.log(res)
|
|
}
|
|
})
|
|
}
|
|
if (this.token) {
|
|
uni.navigateTo({
|
|
url: '/pages/therapist/orderDetail?artificerId=' + e.artificerId
|
|
});
|
|
} else {
|
|
uni.navigateTo({
|
|
url: '/pages/public/login'
|
|
});
|
|
}
|
|
|
|
},
|
|
},
|
|
onReachBottom: function() {
|
|
this.page = this.page + 1;
|
|
this.getlist()
|
|
},
|
|
onPullDownRefresh: function() {
|
|
this.page = 1;
|
|
this.getlist()
|
|
},
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
page {
|
|
background-color: #F7F7F7;
|
|
}
|
|
|
|
.zz_view {
|
|
// width: 220upx;
|
|
background: #e8fdf6;
|
|
color: #73c2a2;
|
|
font-size: 24rpx;
|
|
padding: 6rpx 10rpx;
|
|
border-radius: 10rpx;
|
|
}
|
|
|
|
.zpmore_view {
|
|
background: #096f4b;
|
|
width: 120upx;
|
|
text-align: center;
|
|
border-radius: 10rpx;
|
|
height: 42rpx;
|
|
line-height: 42rpx;
|
|
font-size: 24rpx;
|
|
color: #FFFFFF;
|
|
margin-left: 10rpx;
|
|
}
|
|
|
|
.byy_view {
|
|
// background: #096f4b;
|
|
width: 120upx;
|
|
text-align: center;
|
|
border-radius: 50rpx;
|
|
height: 46rpx;
|
|
line-height: 46rpx;
|
|
font-size: 24rpx;
|
|
color: #999999;
|
|
border: 3upx solid #999999;
|
|
margin-top: 6rpx;
|
|
}
|
|
|
|
.kyy_view {
|
|
background: #096f4b;
|
|
width: 120upx;
|
|
text-align: center;
|
|
border-radius: 50rpx;
|
|
height: 46rpx;
|
|
line-height: 46rpx;
|
|
font-size: 24rpx;
|
|
color: #FFFFFF;
|
|
margin-top: 6rpx;
|
|
}
|
|
|
|
.bg {
|
|
background: #FFFFFF;
|
|
}
|
|
|
|
.ytp_view {
|
|
background: #e3e3e3;
|
|
width: 400rpx;
|
|
border-radius: 10rpx;
|
|
font-size: 28rpx;
|
|
text-align: center;
|
|
height: 80rpx;
|
|
line-height: 80rpx;
|
|
color: #848484;
|
|
margin-top: 40rpx;
|
|
}
|
|
|
|
.tp_view {
|
|
background: #ee6c54;
|
|
width: 400rpx;
|
|
border-radius: 10rpx;
|
|
font-size: 28rpx;
|
|
text-align: center;
|
|
height: 80rpx;
|
|
line-height: 80rpx;
|
|
color: #FFFFFF;
|
|
margin-top: 40rpx;
|
|
}
|
|
|
|
.sticky-tabs {
|
|
z-index: 990;
|
|
position: sticky;
|
|
top: var(--window-top);
|
|
// background-color: #fff;
|
|
}
|
|
|
|
/* // 使用mescroll-uni,则top为0 */
|
|
.mescroll-uni,
|
|
/deep/.mescroll-uni {
|
|
.sticky-tabs {
|
|
top: 0;
|
|
}
|
|
}
|
|
|
|
.demo-tip {
|
|
padding: 18upx;
|
|
font-size: 24upx;
|
|
text-align: center;
|
|
}
|
|
|
|
.line_s {
|
|
display: inline-flex;
|
|
width: 10rpx;
|
|
height: 10rpx;
|
|
background: #1AD566;
|
|
border-radius: 50%;
|
|
margin-right: 10rpx;
|
|
}
|
|
|
|
.line_x {
|
|
display: inline-flex;
|
|
width: 10rpx;
|
|
height: 10rpx;
|
|
background: #000000;
|
|
border-radius: 50%;
|
|
margin-right: 10rpx;
|
|
}
|
|
|
|
.box {
|
|
// border: 3rpx solid #005dff;
|
|
background: #E8FAE1;
|
|
color: #096f4b;
|
|
padding: 5rpx 15rpx;
|
|
font-size: 26rpx;
|
|
letter-spacing: 2rpx;
|
|
border-radius: 8rpx;
|
|
// margin-top: 10rpx;
|
|
margin-right: 8upx;
|
|
}
|
|
|
|
.actve {
|
|
font-size: 30rpx;
|
|
font-family: PingFang SC;
|
|
font-weight: 800;
|
|
color: #20C675;
|
|
}
|
|
|
|
.tabview1 {
|
|
padding: 20rpx 20rpx;
|
|
// width: 686upx;
|
|
// height: 100upx;
|
|
background: #FFFFFF;
|
|
margin-top: 60upx;
|
|
// z-index: 99;
|
|
// display: flex;
|
|
// line-height: 100upx;
|
|
|
|
.tabview {
|
|
// width: 686upx;
|
|
// // height: 100upx;
|
|
background: #F2FFF9;
|
|
border-radius: 24rpx 24rpx 0 0;
|
|
// margin-top: -50upx;
|
|
// z-index: 99;
|
|
display: flex;
|
|
line-height: 100upx;
|
|
|
|
.tabItem_sel {
|
|
font-size: 30upx;
|
|
font-family: PingFang SC;
|
|
font-weight: 800;
|
|
color: #20C675;
|
|
flex: 1;
|
|
text-align: center;
|
|
}
|
|
|
|
.tabItem {
|
|
font-size: 26upx;
|
|
font-family: PingFang SC;
|
|
font-weight: 500;
|
|
color: #333333;
|
|
flex: 1;
|
|
text-align: center;
|
|
}
|
|
}
|
|
|
|
.tabsx {
|
|
width: 686upx;
|
|
border-radius: 24rpx;
|
|
padding-bottom: 10rpx;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 20rpx 30rpx;
|
|
font-size: 26rpx;
|
|
|
|
.active {
|
|
color: #20C675;
|
|
font-size: 30rpx;
|
|
font-weight: bold;
|
|
}
|
|
}
|
|
}
|
|
</style> |