茶室
This commit is contained in:
parent
8addab5394
commit
a2c4c8eb27
|
|
@ -156,6 +156,7 @@
|
|||
this.mintime = res.data.minHours
|
||||
this.explain = res.data.explain
|
||||
this.tuitimes = res.data.refundDuration
|
||||
this.yajin = res.data.deposit
|
||||
this.tuitime = res.data.refundDuration + '分钟'
|
||||
}
|
||||
})
|
||||
|
|
|
|||
|
|
@ -104,8 +104,12 @@
|
|||
<image src="https://api.ccttiot.com/smartmeter/img/static/uHQtbhwpFAMPjWkn0kw5" mode=""></image>
|
||||
<view class="wz">基础设置</view>
|
||||
</view>
|
||||
<view class="listul_item" @click="btnluru">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uHQtbhwpFAMPjWkn0kw5" mode=""></image>
|
||||
<view class="wz">设备录入</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<tab-bars :indexs='0' style=""></tab-bars>
|
||||
|
|
@ -134,6 +138,12 @@
|
|||
})
|
||||
},
|
||||
methods: {
|
||||
// 点击进行设备录入
|
||||
btnluru(){
|
||||
uni.navigateTo({
|
||||
url:'/page_user/luru'
|
||||
})
|
||||
},
|
||||
// 统一跳转
|
||||
btnpage(num){
|
||||
if(num == 3){ //跳转到订单详情
|
||||
|
|
|
|||
|
|
@ -1,9 +1,100 @@
|
|||
<template>
|
||||
<view class="page">
|
||||
<view class="pages">
|
||||
<u-navbar :is-back="false" title="个人中心" :border-bottom="false" back-icon-color="000" :background="bgc" title-color='#000' title-size='36'
|
||||
height='40' id="navbar">
|
||||
</u-navbar>
|
||||
<tab-bars :indexs='2' style=""></tab-bars>
|
||||
</u-navbar>
|
||||
<image class="imgbj" src="https://api.ccttiot.com/smartmeter/img/static/u9z9SY30L7fzcgP7t1eO" mode=""></image>
|
||||
<view class="my">
|
||||
<view class="mylt">
|
||||
<view class="">
|
||||
<view class="" style="display: flex;align-items: center;">
|
||||
<view class="myname">
|
||||
姓名
|
||||
</view>
|
||||
</view>
|
||||
<view class="mytel">
|
||||
15566665555
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 余额 -->
|
||||
<view class="yue">
|
||||
<!-- 背景图 -->
|
||||
<image class="bj" src="https://api.ccttiot.com/smartmeter/img/static/uBI9zEccGouxpFhrjj5L" mode=""></image>
|
||||
<view class="zhye">
|
||||
账户余额(元)
|
||||
</view>
|
||||
<view class="yuan">
|
||||
1523
|
||||
</view>
|
||||
<view class="leiji">
|
||||
<view class="one">
|
||||
累计提现:1232
|
||||
</view>
|
||||
<view class="two" @click="btntx">
|
||||
立即提现
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 更多功能 -->
|
||||
<view class="gongneng">
|
||||
<view class="gongneng_tit">
|
||||
管理与服务
|
||||
</view>
|
||||
<view class="gn_list">
|
||||
<!-- <view class="list_val">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uNB0gtTaIXAOR2NUEtVD" mode=""></image> <text>收款账户</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-icon name="arrow-right" color="#3D3D3D" size="28"></u-icon>
|
||||
</view>
|
||||
</view> -->
|
||||
<view class="list_val" @click="btnhhr">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/urBjYFve4o3hKteeFkRj" mode=""></image> <text>合伙人管理</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-icon name="arrow-right" color="#3D3D3D" size="28"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="list_val" @click="btnaqzx">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uoywyTJbYhd7Iim7KW1Q" mode=""></image> <text>安全中心</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-icon name="arrow-right" color="#3D3D3D" size="28"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="list_val" @click="btnbangzhu">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uz8XwU0dSIyPaeeN83ZA" mode=""></image> <text>帮助与客服</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-icon name="arrow-right" color="#3D3D3D" size="28"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="list_val" @click="btnyjfk">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uvko9KaVisN3lBfWYtOg" mode=""></image> <text>意见反馈</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-icon name="arrow-right" color="#3D3D3D" size="28"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="list_val" style="border: none;" @click="btngywm">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/ui42tAL4XVuOiVs46Rwt" mode=""></image> <text>关于我们</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-icon name="arrow-right" color="#3D3D3D" size="28"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<tab-bars :indexs='2' style=""></tab-bars>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
|
@ -11,23 +102,205 @@
|
|||
export default {
|
||||
data() {
|
||||
return {
|
||||
bgc: {
|
||||
backgroundColor: "",
|
||||
},
|
||||
bgc: {
|
||||
backgroundColor: "",
|
||||
},
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
|
||||
|
||||
},
|
||||
onShow() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
// 点击跳转提现
|
||||
btntx(){
|
||||
uni.navigateTo({
|
||||
url:'/page_fenbaotwo/tixian'
|
||||
})
|
||||
},
|
||||
// 点击跳转合伙人
|
||||
btnhhr(){
|
||||
uni.navigateTo({
|
||||
url:'/page_moban/hehuoren'
|
||||
})
|
||||
},
|
||||
//点击跳转到意见反馈
|
||||
btnyjfk(){
|
||||
uni.navigateTo({
|
||||
url:'/page_user/yijian'
|
||||
})
|
||||
},
|
||||
// 点击跳转到帮助
|
||||
btnbangzhu(){
|
||||
uni.navigateTo({
|
||||
url:'/page_fenbaotwo/bangzhu'
|
||||
})
|
||||
},
|
||||
// 点击跳转到关于我们
|
||||
btngywm(){
|
||||
uni.navigateTo({
|
||||
url:'/page_fenbaotwo/about'
|
||||
})
|
||||
},
|
||||
// 点击跳转到安全中心
|
||||
btnaqzx(){
|
||||
uni.navigateTo({
|
||||
url:'/page_fenbaotwo/anquanindex'
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
page {
|
||||
background: #fff;
|
||||
<style lang="scss" scoped>
|
||||
.dateactive {
|
||||
background: #E3E3FF !important;
|
||||
color: #3D3D3D !important;
|
||||
}
|
||||
/deep/ .u-title {
|
||||
padding-bottom: 15rpx;
|
||||
}
|
||||
|
||||
/deep/ .u-icon__icon {
|
||||
padding-bottom: 15rpx;
|
||||
}
|
||||
.imgbj {
|
||||
width: 750rpx;
|
||||
height: 100vh;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: -1;
|
||||
}
|
||||
.onewz{
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.pages {
|
||||
width: 750rpx;
|
||||
padding: 0 46rpx;
|
||||
box-sizing: border-box;
|
||||
.gongneng{
|
||||
margin-top: 50rpx;
|
||||
.gongneng_tit{
|
||||
font-size: 36rpx;
|
||||
color: #3D3D3D;
|
||||
font-weight: 600;
|
||||
}
|
||||
.gn_list{
|
||||
width: 658rpx;
|
||||
max-height: 1430rpx;
|
||||
overflow: scroll;
|
||||
background: #FFFFFF;
|
||||
border-radius: 24rpx 24rpx 24rpx 24rpx;
|
||||
margin-top: 20rpx;
|
||||
border-radius: 20rpx;
|
||||
padding-top: 10rpx;
|
||||
box-sizing: border-box;
|
||||
padding: 0 36rpx;
|
||||
.list_val{
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding:36rpx 0;
|
||||
box-sizing: border-box;
|
||||
font-size: 28rpx;
|
||||
border-bottom: 1px solid #D8D8D8;
|
||||
}
|
||||
.lt{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
image{
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-right: 30rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.yue{
|
||||
position: relative;
|
||||
width: 658rpx;
|
||||
height: 334rpx;
|
||||
margin: auto;
|
||||
margin-top: 20rpx;
|
||||
padding-top: 34rpx;
|
||||
padding-left: 38rpx;
|
||||
padding-right: 38rpx;
|
||||
box-sizing: border-box;
|
||||
.zhye{
|
||||
font-size: 32rpx;
|
||||
color: #48893B;
|
||||
}
|
||||
.yuan{
|
||||
font-size: 66rpx;
|
||||
color: #48893B;
|
||||
font-weight: 600;
|
||||
margin-top: 14rpx;
|
||||
}
|
||||
.leiji{
|
||||
font-size: 32rpx;
|
||||
color: #48893B;
|
||||
margin-top: 56rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
.one{
|
||||
font-size: 32rpx;
|
||||
color: #48893B;
|
||||
}
|
||||
.two{
|
||||
width: 182rpx;
|
||||
height: 64rpx;
|
||||
background: #48893B;
|
||||
border-radius: 35rpx 35rpx 35rpx 35rpx;
|
||||
font-size: 32rpx;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
line-height: 64rpx;
|
||||
border-radius: 30rpx;
|
||||
}
|
||||
}
|
||||
.bj{
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
z-index: -1;
|
||||
}
|
||||
}
|
||||
.my{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-top: 20rpx;
|
||||
.mylt{
|
||||
margin-right: 34rpx;
|
||||
.myname{
|
||||
font-size: 36rpx;
|
||||
color: #3D3D3D;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
.mytel{
|
||||
font-size: 28rpx;
|
||||
color: #3D3D3D;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
}
|
||||
.myrt{
|
||||
width: 110rpx;
|
||||
height: 50rpx;
|
||||
background: #7E90E7;
|
||||
border-radius: 30rpx 30rpx 30rpx 30rpx;
|
||||
text-align: center;
|
||||
// line-height: 40rpx;
|
||||
font-size: 24rpx;
|
||||
color: #FFFFFF;
|
||||
padding: 10rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -3,7 +3,7 @@
|
|||
<u-navbar title="订单详情" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
|
||||
title-size='36' height='40' id="navbar" :custom-back="btns">
|
||||
</u-navbar>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/ubRfYF4S0AUbakKQuohg" mode="" class="imgbj"></image>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
|
||||
<view class="boxda">
|
||||
<view class="timeduan">
|
||||
<view class="one">
|
||||
|
|
@ -94,6 +94,19 @@
|
|||
<image v-if="orderobj.userId == user.userId" @click="btnxudan" src="https://api.ccttiot.com/smartmeter/img/static/utXKDITJDghq6PRyLWTA" mode=""></image>
|
||||
<button v-if="orderobj.userId == user.userId" open-type="share"><image src="https://api.ccttiot.com/smartmeter/img/static/uJrkufnmzJju3xpmxqFE" mode=""></image></button>
|
||||
</view>
|
||||
<!-- <view class="top">
|
||||
<view class="lt">
|
||||
设备控制
|
||||
</view>
|
||||
<view class="kz">
|
||||
<view class="lt">
|
||||
房间灯 <text>已开启</text>
|
||||
</view>
|
||||
<view class="rt">
|
||||
<u-switch v-model="checked"></u-switch>
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
<view class="tishi" v-if="orderobj.status == 2 || orderobj.status == 3">
|
||||
<view class="top">
|
||||
|
|
@ -151,12 +164,15 @@
|
|||
orderNo:'',
|
||||
orderobj:{},
|
||||
flag:true,
|
||||
user:{}
|
||||
user:{},
|
||||
checked:false,
|
||||
viewType:''
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
if(option.orderNo){
|
||||
this.orderNo = option.orderNo
|
||||
this.viewType = option.viewType
|
||||
this.getxq()
|
||||
}else{
|
||||
this.orderNo = option.orderNowx
|
||||
|
|
@ -212,7 +228,7 @@
|
|||
},
|
||||
// 点击开包厢门
|
||||
btnkbxm(){
|
||||
this.$u.get(`app/room/openRoomGate/${this.roomId}`).then(res => {
|
||||
this.$u.get(`app/room/openRoomGate/${this.orderobj.roomId}`).then(res => {
|
||||
if (res.code == 200) {
|
||||
uni.showToast({
|
||||
title: '开启包厢门成功',
|
||||
|
|
@ -318,7 +334,7 @@
|
|||
// 续单
|
||||
btnxudan(){
|
||||
uni.navigateTo({
|
||||
url:'/page_user/xudan?roomId=' + this.orderobj.roomId + '&orderNo=' + this.orderNo
|
||||
url:'/page_user/xudan?roomId=' + this.orderobj.roomId + '&orderNo=' + this.orderNo + '&viewType=' + this.viewType
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
@ -454,7 +470,7 @@
|
|||
width: 288rpx;
|
||||
height: 78rpx;
|
||||
margin-top: 20rpx;
|
||||
margin-left: 40rpx;
|
||||
margin-left: 34rpx;
|
||||
position: relative;
|
||||
border-radius: 50rpx;
|
||||
image{
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<u-navbar title="商品" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
|
||||
title-size='36' height='40' id="navbar">
|
||||
</u-navbar>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/umk1caLMk7f1elQ2T78c" mode="" class="imgbj"></image>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
|
||||
<view class="list">
|
||||
<view class="list_item" v-for="(item,index) in 9" :key="index" @click="btndetai">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uTULMJ4sf8bCUCI5CaF8" class="shopimg" mode=""></image>
|
||||
|
|
|
|||
|
|
@ -149,7 +149,7 @@
|
|||
},
|
||||
btnmy(){
|
||||
uni.reLaunch({
|
||||
url:'/pages/my'
|
||||
url:'/page_shanghu/index'
|
||||
})
|
||||
},
|
||||
// 扫码sn
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<u-navbar title="商品下单" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
|
||||
title-size='36' height='40' id="navbar">
|
||||
</u-navbar>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/umk1caLMk7f1elQ2T78c" mode="" class="imgbj"></image>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
|
||||
<view class="shopxx">
|
||||
<view class="top">
|
||||
【福鼎-西湖店】
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<u-navbar title="订单续单" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
|
||||
title-size='36' height='36' id="navbar">
|
||||
</u-navbar>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/umk1caLMk7f1elQ2T78c" mode="" class="imgbj"></image>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
|
||||
<view class="boxda">
|
||||
<view class="fangjian">
|
||||
<view class="top">
|
||||
|
|
@ -19,7 +19,7 @@
|
|||
</view>
|
||||
<view class="leixing">
|
||||
<view class="" v-for="(item,index) in shopobj.tags">
|
||||
{{item}}
|
||||
{{getMatchingLabel(item)}}
|
||||
</view>
|
||||
</view>
|
||||
<view class="price">
|
||||
|
|
@ -320,15 +320,19 @@
|
|||
zfss: '微信支付',
|
||||
zfssid: 'wx',
|
||||
timeshijian:'',
|
||||
orderNo:''
|
||||
orderNo:'',
|
||||
biaoqianlist:[],
|
||||
viewType:''
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
this.roomId = option.roomId
|
||||
this.orderNo = option.orderNo
|
||||
this.viewType = option.viewType
|
||||
this.getstoredetail()
|
||||
this.getstoredetails()
|
||||
this.gettaocan()
|
||||
this.getbiaoqian()
|
||||
this.hourPointsArray = this.getCurrentHourPoints() //计算从当前时间往后推24小时
|
||||
},
|
||||
onShow() {
|
||||
|
|
@ -340,6 +344,20 @@
|
|||
console.log(this.weekdayAndDateSequence);
|
||||
},
|
||||
methods: {
|
||||
// 拿到房间标签进行对比
|
||||
getMatchingLabel(val) {
|
||||
const matchingItem = this.biaoqianlist.find(item => item.dictValue === val)
|
||||
return matchingItem ? matchingItem.dictLabel : val
|
||||
},
|
||||
// 获取房间标签
|
||||
getbiaoqian(){
|
||||
this.$u.get(`/appVerify/getDictData?dictType=ss_room_tags`).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.biaoqianlist = res.data
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
convertDates(array) {
|
||||
return array.map(item => {
|
||||
// 将日期字符串转换为 Date 对象
|
||||
|
|
@ -545,8 +563,9 @@
|
|||
let data = {
|
||||
payType: this.zfssid,
|
||||
ruleId: this.tcobj.ruleId,
|
||||
viewType:this.viewType,
|
||||
type: 2,
|
||||
mode: 2,
|
||||
mode: 2,
|
||||
hours: this.hourstime,
|
||||
price: this.price,
|
||||
originalOrderNo:this.orderNo
|
||||
|
|
@ -728,7 +747,7 @@
|
|||
if (res.code == 200) {
|
||||
this.shopobj = res.data
|
||||
// this.kstime
|
||||
if(res.data.reservedTimePeriods == ''){
|
||||
if(res.data.reservedTimePeriods == null){
|
||||
this.roomList = []
|
||||
for(let i = 0;i < 24;i++){
|
||||
this.roomList.push(false)
|
||||
|
|
@ -970,7 +989,7 @@
|
|||
|
||||
.yudingtrue {
|
||||
width: 600rpx;
|
||||
height: 806rpx;
|
||||
max-height: 999rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 32rpx 32rpx 32rpx 32rpx;
|
||||
padding: 0 20rpx;
|
||||
|
|
@ -979,7 +998,7 @@
|
|||
top: 388rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
|
||||
padding-bottom: 30rpx;
|
||||
.shuom {
|
||||
.xuzhi {
|
||||
font-weight: 600;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
<view class="pages">
|
||||
<u-navbar title="意见反馈" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
|
||||
title-size='36' height='40' id="navbar"></u-navbar>
|
||||
<image class="bjimg" src="https://api.ccttiot.com/smartmeter/img/static/uvnKFCPlFY5ZO3wUosTw" mode=""></image>
|
||||
<!-- <image class="bjimg" src="https://api.ccttiot.com/smartmeter/img/static/uvnKFCPlFY5ZO3wUosTw" mode=""></image> -->
|
||||
<view class="leix">
|
||||
<view class="title">
|
||||
反馈类型 <text style="font-size: 36rpx; color: red; vertical-align: top;margin-left: 32rpx;">✲</text>
|
||||
|
|
|
|||
96
pages.json
96
pages.json
|
|
@ -104,6 +104,13 @@
|
|||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "lijikaishi",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "xiadanhuogui",
|
||||
"style": {
|
||||
|
|
@ -389,6 +396,13 @@
|
|||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "qiugan",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "datingxq",
|
||||
"style": {
|
||||
|
|
@ -510,6 +524,88 @@
|
|||
}
|
||||
}
|
||||
]
|
||||
}, {
|
||||
"root": "page_fenbaotwo",
|
||||
"pages": [
|
||||
{
|
||||
"path": "tixian",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "bangzhu",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "bangzhuxq",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "about",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "anquanindex",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "anquan",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "bangwx",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "edittel",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "dangqiantel",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "yzmhq",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},{
|
||||
"path": "newpass",
|
||||
"style": {
|
||||
"navigationBarTitleText": "上传",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
}
|
||||
]
|
||||
}, {
|
||||
"root": "",
|
||||
"pages": []
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
<u-swiper :list="list" mode="number" border-radius="20" height="366" indicator-pos="bottomRight"></u-swiper>
|
||||
<view class="shuom">
|
||||
<view class="" v-for="(item,index) in shopobj.tags">
|
||||
{{item}}
|
||||
{{getMatchingLabels(item)}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
|
@ -18,7 +18,8 @@
|
|||
{{shopobj.name == undefined ? '--' : shopobj.name}}
|
||||
</view>
|
||||
<view class="shoprt">
|
||||
<image @click="btndaohang" src="https://api.ccttiot.com/smartmeter/img/static/uGTXeGxaynhN6SgufCdo" mode=""></image>
|
||||
<image @click="btndaohang" src="https://api.ccttiot.com/smartmeter/img/static/uGTXeGxaynhN6SgufCdo"
|
||||
mode=""></image>
|
||||
<image @click="btntel" src="https://api.ccttiot.com/smartmeter/img/static/u8T5n2761RF0UY8ete1h" mode="">
|
||||
</image>
|
||||
</view>
|
||||
|
|
@ -27,27 +28,16 @@
|
|||
距我{{shopobj.distance == undefined ? '--' : shopobj.distance}}km <text></text>
|
||||
{{shopobj.address == undefined ? '--' : shopobj.address}}
|
||||
</view>
|
||||
|
||||
<view class="tongji">
|
||||
<view class="one" @click="btngundong('section1',0)">
|
||||
<view class="kg">空闲 <text>2</text></view>
|
||||
<view class="gn">茶室</view>
|
||||
<image v-if="tabindex == 0" src="https://api.ccttiot.com/smartmeter/img/static/uZNimi3DEsGWsjfJm2Bg" mode=""></image>
|
||||
</view>
|
||||
<view class="xian"></view>
|
||||
<view class="one" @click="btngundong('section2',1)">
|
||||
<view class="kg">空闲 <text>2</text></view>
|
||||
<view class="gn">棋牌</view>
|
||||
<image v-if="tabindex == 1" src="https://api.ccttiot.com/smartmeter/img/static/uZNimi3DEsGWsjfJm2Bg" mode=""></image>
|
||||
</view>
|
||||
<view class="xian"></view>
|
||||
<view class="one" @click="btngundong('section3',2)">
|
||||
<view class="kg">空闲 <text>2</text></view>
|
||||
<view class="gn">台球</view>
|
||||
<image v-if="tabindex == 2" src="https://api.ccttiot.com/smartmeter/img/static/uZNimi3DEsGWsjfJm2Bg" mode=""></image>
|
||||
|
||||
<view class="tongji" v-if="tabarr.length > 1">
|
||||
<view class="one" @click="btngundong('section1',index)" v-for="(item,index) in tabarr" :key="index">
|
||||
<view class="kg">空闲 <text>{{item.idleNum}}</text></view>
|
||||
<view class="gn">{{item.tag}}</view>
|
||||
<image v-if="tabindex == index" src="https://api.ccttiot.com/smartmeter/img/static/uZNimi3DEsGWsjfJm2Bg"
|
||||
mode=""></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="typewz" v-if="tabindex == 0">
|
||||
<!-- <view class="typewz" v-if="tabindex == 0">
|
||||
<text class="one">茶室</text> <text class="two">干净舒适品好茶</text>
|
||||
</view>
|
||||
<view class="typewz" v-if="tabindex == 1">
|
||||
|
|
@ -55,9 +45,10 @@
|
|||
</view>
|
||||
<view class="typewz" v-if="tabindex == 2">
|
||||
<text class="one">台球</text> <text class="two">好台打好球,赛事级桌台</text>
|
||||
</view>
|
||||
</view> -->
|
||||
<!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 -->
|
||||
<view class="taiqiubox" v-if="tabindex == 2" @touchstart="onTouchStart" @touchend="onTouchEnd" @touchcancel="onTouchCancel">
|
||||
<view class="taiqiubox" v-if="tabindex == 2" @touchstart="onTouchStart" @touchend="onTouchEnd"
|
||||
@touchcancel="onTouchCancel">
|
||||
<view class="zhuozi">
|
||||
<view class="tqlist">
|
||||
<view class="tqlist_item" v-for="(item,index) in 5" :key="index" @click="btntq">
|
||||
|
|
@ -84,9 +75,10 @@
|
|||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="shoplist" v-else @touchstart="onTouchStart" @touchend="onTouchEnd" @touchcancel="onTouchCancel">
|
||||
<view class="shop_item" v-for="(item,index) in shopobj.roomList" :key="index" @click.stop="btndetail(item.roomId)">
|
||||
<view class="shop_item" v-for="(item,index) in shopobj.roomList" :key="index"
|
||||
@click.stop="btndetail(item)">
|
||||
<view class="top">
|
||||
<view class="lt">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uEjTJcyIlPETr6vUCs8M" mode=""></image>
|
||||
|
|
@ -111,20 +103,22 @@
|
|||
</view>
|
||||
<view class="cen">
|
||||
<view class="name">
|
||||
{{item.roomName == undefined ? '--' : item.roomName}}
|
||||
{{item.roomName == undefined ? '--' : item.roomName}}
|
||||
<text v-if="item.viewType == 1">房间</text>
|
||||
<text v-if="item.viewType == 2">大厅</text>
|
||||
</view>
|
||||
<view class="leixing">
|
||||
<view class="" v-for="(val,index) in item.tags">
|
||||
{{val}}
|
||||
{{getMatchingLabel(val)}}
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="price">
|
||||
¥{{item.hour == undefined ? '--' : item.hour}}/小时
|
||||
</view>
|
||||
<view class="taocan">
|
||||
{{item.bottomPriceFeeRule.hours == undefined ? '--' : item.bottomPriceFeeRule.hours}}小时套餐/
|
||||
<text>¥{{item.bottomPriceFeeRule.price == undefined ? '--' : item.bottomPriceFeeRule.price}}</text> /场
|
||||
<text>¥{{item.bottomPriceFeeRule.price == undefined ? '--' : item.bottomPriceFeeRule.price}}</text>
|
||||
/场
|
||||
</view>
|
||||
</view>
|
||||
<view class="rt">
|
||||
|
|
@ -142,7 +136,8 @@
|
|||
</view>
|
||||
<view class="bot">
|
||||
<view class="duan">
|
||||
<view v-for="(isReserved, hourStr) in item.reservationStatus" :key="hourStr" :class="['hour-item', { 'is-reserved': isReserved }]">
|
||||
<view v-for="(isReserved, hourStr) in item.reservationStatus" :key="hourStr"
|
||||
:class="['hour-item', { 'is-reserved': isReserved }]">
|
||||
</view>
|
||||
</view>
|
||||
<view class="shijian">
|
||||
|
|
@ -164,47 +159,56 @@
|
|||
没有更多房间啦,敬请期待吧...
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view class="xuanfu" v-if="imgflag">
|
||||
<image @click="btnopen(1)" src="https://api.ccttiot.com/smartmeter/img/static/uKeCHdot1z4QJldDe3UL" mode=""></image>
|
||||
<image @click="btnopen(2)" src="https://api.ccttiot.com/smartmeter/img/static/u4lmGbm77OWC2Uik2737" mode=""></image>
|
||||
<image @click="btnopen(3)" src="https://api.ccttiot.com/smartmeter/img/static/uUjamKC7Kvd9KMLLOeBD" mode=""></image>
|
||||
<image @click="btnopen(1)" src="https://api.ccttiot.com/smartmeter/img/static/uKeCHdot1z4QJldDe3UL" mode="">
|
||||
</image>
|
||||
<image @click="btnopen(2)" src="https://api.ccttiot.com/smartmeter/img/static/u4lmGbm77OWC2Uik2737" mode="">
|
||||
</image>
|
||||
<image @click="btnopen(3)" src="https://api.ccttiot.com/smartmeter/img/static/uUjamKC7Kvd9KMLLOeBD" mode="">
|
||||
</image>
|
||||
</view>
|
||||
<view class="xuanfus" v-else>
|
||||
<image @click="btnopen(1)" src="https://api.ccttiot.com/smartmeter/img/static/uKeCHdot1z4QJldDe3UL" mode=""></image>
|
||||
<image @click="btnopen(2)" src="https://api.ccttiot.com/smartmeter/img/static/u4lmGbm77OWC2Uik2737" mode=""></image>
|
||||
<image @click="btnopen(3)" src="https://api.ccttiot.com/smartmeter/img/static/uUjamKC7Kvd9KMLLOeBD" mode=""></image>
|
||||
<image @click="btnopen(1)" src="https://api.ccttiot.com/smartmeter/img/static/uKeCHdot1z4QJldDe3UL" mode="">
|
||||
</image>
|
||||
<image @click="btnopen(2)" src="https://api.ccttiot.com/smartmeter/img/static/u4lmGbm77OWC2Uik2737" mode="">
|
||||
</image>
|
||||
<image @click="btnopen(3)" src="https://api.ccttiot.com/smartmeter/img/static/uUjamKC7Kvd9KMLLOeBD" mode="">
|
||||
</image>
|
||||
</view>
|
||||
<view class="karaokeroom" v-if="jinxinflag">
|
||||
<view class="top">
|
||||
正在进行中的订单
|
||||
</view>
|
||||
<view class="roomlist">
|
||||
<view class="room_item" v-for="(item,index) in jinxinglist" :key="index" :id="mdindex == index ? 'active' : ''" @click="btnmd(index)">
|
||||
<view class="lt">
|
||||
<image :src="item.picture" mode=""></image>
|
||||
</view>
|
||||
<view class="rt" style="font-size: 22rpx;">
|
||||
<view class="">
|
||||
<text>预约门店:</text> <text>{{item.storeName == null ? '--' : item.storeName}}</text>
|
||||
</view>
|
||||
<view class="room_item" v-for="(item,index) in jinxinglist" :key="index"
|
||||
:id="mdindex == index ? 'active' : ''" @click="btnmd(index,item)">
|
||||
<view class="lt">
|
||||
<image :src="item.picture" mode=""></image>
|
||||
</view>
|
||||
<view class="rt" style="font-size: 22rpx;">
|
||||
<view class="">
|
||||
<text>预约门店:</text> <text>{{item.storeName == null ? '--' : item.storeName}}</text>
|
||||
</view>
|
||||
<view class="">
|
||||
<text>预约包厢:</text> <text>{{item.roomName == null ? '--' : item.roomName}}</text>
|
||||
</view>
|
||||
<view class="">
|
||||
<text>开始时间:</text> <text>{{item.reserveStartTime == null ? '--' : item.reserveStartTime}}</text>
|
||||
<text>开始时间:</text>
|
||||
<text>{{item.reserveStartTime == null ? '--' : item.reserveStartTime}}</text>
|
||||
</view>
|
||||
<view class="">
|
||||
<text>结束时间:</text> <text>{{item.reserveEndTime == null ? '--' : item.reserveEndTime}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="anniu">
|
||||
<view class="anniu" @click="btnanniu">
|
||||
{{jinxintxt}}
|
||||
</view>
|
||||
</view>
|
||||
<image v-if="jinxinflag" @click="jinxinflag = false" class="jinxinx" src="https://api.ccttiot.com/smartmeter/img/static/uH5fAInJQYhf3wlXkuYI" mode=""></image>
|
||||
<image v-if="jinxinflag" @click="jinxinflag = false" class="jinxinx"
|
||||
src="https://api.ccttiot.com/smartmeter/img/static/uH5fAInJQYhf3wlXkuYI" mode=""></image>
|
||||
<view class="mask" v-if="jinxinflag"></view>
|
||||
|
||||
</view>
|
||||
|
|
@ -217,11 +221,9 @@
|
|||
bgc: {
|
||||
backgroundColor: "",
|
||||
},
|
||||
list: [
|
||||
{
|
||||
image: 'https://api.ccttiot.com/smartmeter/img/static/uqYdRLVlB5b61Qdnbirn'
|
||||
}
|
||||
],
|
||||
list: [{
|
||||
image: 'https://api.ccttiot.com/smartmeter/img/static/uqYdRLVlB5b61Qdnbirn'
|
||||
}],
|
||||
imgflag: true,
|
||||
storeId: '',
|
||||
shopobj: {},
|
||||
|
|
@ -229,24 +231,30 @@
|
|||
roomList: [],
|
||||
hours: [],
|
||||
reservationStatus: {},
|
||||
arr:[],
|
||||
jinxinglist:[],
|
||||
jinxinflag:false,
|
||||
jinxintxt:'开包厢',
|
||||
tabindex:0
|
||||
arr: [],
|
||||
jinxinglist: [],
|
||||
jinxinflag: false,
|
||||
jinxintxt: '开包厢',
|
||||
tabindex: 0,
|
||||
biaoqianlist: [],
|
||||
biaostoreqianlist: [],
|
||||
mdindex:-1,
|
||||
viewType:''
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
if(option.storeId){
|
||||
this.getroombq()
|
||||
if (option.storeId) {
|
||||
this.storeId = option.storeId
|
||||
uni.setStorageSync('storeId',this.storeId)
|
||||
}else{
|
||||
uni.setStorageSync('storeId', this.storeId)
|
||||
} else {
|
||||
this.storeId = uni.getStorageSync('storeId')
|
||||
}
|
||||
},
|
||||
onShow() {
|
||||
this.jinxinflag = false //如果进行了tab切换 则隐藏
|
||||
this.getstoredetail()
|
||||
this.getbiaoqian()
|
||||
this.getstorebiaoqian()
|
||||
this.getorder()
|
||||
this.hourPointsArray = this.getCurrentHourPoints() //计算从当前时间往后推24小时
|
||||
},
|
||||
|
|
@ -254,140 +262,245 @@
|
|||
|
||||
},
|
||||
methods: {
|
||||
// 点击台球桌预定
|
||||
btntq(){
|
||||
uni.navigateTo({
|
||||
url:'/pages/myorder/taiqiuyuding'
|
||||
})
|
||||
// 点击包厢切换高亮
|
||||
btnmd(index,item){
|
||||
this.viewType = item.viewType
|
||||
this.mdindex = index
|
||||
},
|
||||
|
||||
// 拿到房间标签进行对比
|
||||
getMatchingLabel(val) {
|
||||
const matchingItem = this.biaoqianlist.find(item => item.dictValue === val)
|
||||
return matchingItem ? matchingItem.dictLabel : val
|
||||
},
|
||||
// 拿到店铺标签进行对比
|
||||
getMatchingLabels(val) {
|
||||
const matchingItem = this.biaostoreqianlist.find(item => item.dictValue === val)
|
||||
return matchingItem ? matchingItem.dictLabel : val
|
||||
},
|
||||
// 获取店铺标签
|
||||
getstorebiaoqian() {
|
||||
this.$u.get(`/appVerify/getDictData?dictType=ss_store_tags`).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.biaostoreqianlist = res.data
|
||||
}
|
||||
})
|
||||
},
|
||||
// 获取房间标签
|
||||
getbiaoqian() {
|
||||
this.$u.get(`/appVerify/getDictData?dictType=ss_room_tags`).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.biaoqianlist = res.data
|
||||
this.getstoredetail()
|
||||
}
|
||||
})
|
||||
},
|
||||
// 根据店铺id查房间tab
|
||||
getroombq() {
|
||||
this.$u.get(`/app/room/getTagListByStoreId?storeId=${this.storeId}`).then(res => {
|
||||
if (res.code == 200) {
|
||||
this.tabarr = res.data
|
||||
}
|
||||
})
|
||||
},
|
||||
// 点击台球桌预定
|
||||
btntq() {
|
||||
uni.navigateTo({
|
||||
url: '/pages/myorder/taiqiuyuding'
|
||||
})
|
||||
},
|
||||
|
||||
// 点击切换tab类型
|
||||
btngundong(section, index) {
|
||||
this.tabindex = index
|
||||
},
|
||||
|
||||
|
||||
|
||||
|
||||
// 拿到当前时间后24小时格式成两位数
|
||||
initializeData() {
|
||||
// 获取当前时间
|
||||
let now = new Date()
|
||||
// 获取当前时间的小时部分(0-23)
|
||||
let currentHour = now.getHours()
|
||||
// 初始化小时数组
|
||||
this.hours = []
|
||||
this.arr = []
|
||||
// 遍历从当前小时开始的24个小时
|
||||
for (let i = 0; i < 24; i++) {
|
||||
// 计算小时数,注意要处理超过23点的情况
|
||||
let hour = (currentHour + i) % 24
|
||||
let arrsum = currentHour + i
|
||||
if(hour == '00'){ //如果是00:00 则改成24:00
|
||||
hour = 24
|
||||
}else{
|
||||
hour = hour
|
||||
// 获取当前时间
|
||||
let now = new Date()
|
||||
// 获取当前时间的小时部分(0-23)
|
||||
let currentHour = now.getHours()
|
||||
// 初始化小时数组
|
||||
this.hours = []
|
||||
this.arr = []
|
||||
// 遍历从当前小时开始的24个小时
|
||||
for (let i = 0; i < 24; i++) {
|
||||
// 计算小时数,注意要处理超过23点的情况
|
||||
let hour = (currentHour + i) % 24
|
||||
let arrsum = currentHour + i
|
||||
if (hour == '00') { //如果是00:00 则改成24:00
|
||||
hour = 24
|
||||
} else {
|
||||
hour = hour
|
||||
}
|
||||
// 推入数组
|
||||
this.arr.push(arrsum)
|
||||
this.hours.push(hour)
|
||||
}
|
||||
// 推入数组
|
||||
this.arr.push(arrsum)
|
||||
this.hours.push(hour)
|
||||
}
|
||||
console.log(this.hours,'arr',this.arr)
|
||||
console.log(this.hours, 'arr', this.arr)
|
||||
},
|
||||
// 更新房间的预订状态且与initializeData进行匹对
|
||||
updateRoomReservationStatus() {
|
||||
this.roomList.forEach(room => {
|
||||
room.reservationStatus = {} // 为每个房间创建一个新的预订状态对象
|
||||
this.hours.forEach(hour => {
|
||||
room.reservationStatus[hour] = false // 初始化为未预订状态
|
||||
})
|
||||
room.reservedTimePeriods.forEach(period => {
|
||||
let startHour = period.startTime.slice(period.startTime.length - 8, period.startTime.length - 6) //取预定开始时间小时
|
||||
let endHour = period.endTime.slice(period.endTime.length - 8, period.endTime.length - 6) //取预定结束时间小时
|
||||
let timefen = period.startTime.slice(period.endTime.length - 5, period.endTime.length - 3) //取预定结束时间分钟
|
||||
console.log(timefen,'02020202')
|
||||
// 获取当前日期
|
||||
let now = new Date()
|
||||
let year = now.getFullYear()
|
||||
let month = String(now.getMonth() + 1).padStart(2, '0') // 月份从0开始,所以要加1,并用padStart确保是两位数
|
||||
let day = String(now.getDate()).padStart(2, '0') // 用padStart确保是两位数
|
||||
let riqione = `${year}-${month}-${day}` //当前日期
|
||||
let riqitwo = period.endTime.slice(0,10) //预定结束日期
|
||||
let dateOne = new Date(riqione)
|
||||
let dateTwo = new Date(riqitwo)
|
||||
if (dateOne < dateTwo) { //将开始和结束日期进行对比 判断是否是第二天
|
||||
if(endHour < startHour){
|
||||
endHour = 24 + Number(endHour)
|
||||
}else{
|
||||
endHour = 24 + Number(endHour)
|
||||
startHour = 24 + Number(startHour)
|
||||
}
|
||||
} else {
|
||||
console.log("第一个日期不小于第二个日期")
|
||||
}
|
||||
console.log(startHour,endHour,period.startTime,period.endTime)
|
||||
for (let i = 0; i < 24; i++) {
|
||||
if(timefen == '00'){ //判断预定结束是否包含分钟 不包含正常走判断 包含则将时间往后延长1
|
||||
if(this.arr[i] > startHour && this.arr[i] <= endHour){
|
||||
room.reservationStatus[i] = true
|
||||
if (room.reservationStatus == null) {
|
||||
room.reservationStatus = {} // 为每个房间创建一个新的预订状态对象
|
||||
this.hours.forEach(hour => {
|
||||
room.reservationStatus[hour] = false // 初始化为未预订状态
|
||||
})
|
||||
} else {
|
||||
room.reservationStatus = {} // 为每个房间创建一个新的预订状态对象
|
||||
this.hours.forEach(hour => {
|
||||
room.reservationStatus[hour] = false // 初始化为未预订状态
|
||||
})
|
||||
room.reservedTimePeriods.forEach(period => {
|
||||
let startHour = period.startTime.slice(period.startTime.length - 8, period.startTime.length - 6) //取预定开始时间小时
|
||||
let endHour = period.endTime.slice(period.endTime.length - 8, period.endTime.length - 6) //取预定结束时间小时
|
||||
let timefen = period.startTime.slice(period.endTime.length - 5, period.endTime.length - 3) //取预定结束时间分钟
|
||||
console.log(timefen, '02020202')
|
||||
// 获取当前日期
|
||||
let now = new Date()
|
||||
let year = now.getFullYear()
|
||||
let month = String(now.getMonth() + 1).padStart(2,'0') // 月份从0开始,所以要加1,并用padStart确保是两位数
|
||||
let day = String(now.getDate()).padStart(2, '0') // 用padStart确保是两位数
|
||||
let riqione = `${year}-${month}-${day}` //当前日期
|
||||
let riqitwo = period.endTime.slice(0, 10) //预定结束日期
|
||||
let dateOne = new Date(riqione)
|
||||
let dateTwo = new Date(riqitwo)
|
||||
if (dateOne < dateTwo) { //将开始和结束日期进行对比 判断是否是第二天
|
||||
if (endHour < startHour) {
|
||||
endHour = 24 + Number(endHour)
|
||||
} else {
|
||||
endHour = 24 + Number(endHour)
|
||||
startHour = 24 + Number(startHour)
|
||||
}
|
||||
}else{
|
||||
if(this.arr[i] > startHour && Number(this.arr[i] - 1) <= endHour){
|
||||
room.reservationStatus[i] = true
|
||||
} else {
|
||||
console.log("第一个日期不小于第二个日期")
|
||||
}
|
||||
console.log(startHour, endHour, period.startTime, period.endTime)
|
||||
for (let i = 0; i < 24; i++) {
|
||||
if (timefen == '00') { //判断预定结束是否包含分钟 不包含正常走判断 包含则将时间往后延长1
|
||||
if (this.arr[i] > startHour && this.arr[i] <= endHour) {
|
||||
room.reservationStatus[i] = true
|
||||
}
|
||||
} else {
|
||||
if (this.arr[i] > startHour && Number(this.arr[i] - 1) <= endHour) {
|
||||
room.reservationStatus[i] = true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
})
|
||||
console.log(this.roomList,'00')
|
||||
},
|
||||
|
||||
|
||||
//计算从当前时间往后推24小时
|
||||
getCurrentHourPoints() {
|
||||
let now = new Date()
|
||||
let startHour = now.getHours()
|
||||
let startDate = new Date(now)
|
||||
startDate.setMinutes(0, 0, 0) // 确保分钟、秒和毫秒都是0
|
||||
let options = {
|
||||
year: 'numeric',
|
||||
month: '2-digit',
|
||||
day: '2-digit',
|
||||
hour: '2-digit',
|
||||
minute: '2-digit',
|
||||
second: '2-digit'
|
||||
}
|
||||
let hourPoints = []
|
||||
for (let i = 0; i < 24; i++) {
|
||||
let newDate = new Date(startDate)
|
||||
newDate.setHours((startHour + i) % 24, 0, 0, 0)
|
||||
if (newDate.getHours() === 0 && i !== 0) {
|
||||
newDate.setDate(newDate.getDate() + 1)
|
||||
console.log(this.roomList, '00')
|
||||
},
|
||||
|
||||
|
||||
//计算从当前时间往后推24小时
|
||||
getCurrentHourPoints() {
|
||||
let now = new Date()
|
||||
let startHour = now.getHours()
|
||||
let startDate = new Date(now)
|
||||
startDate.setMinutes(0, 0, 0) // 确保分钟、秒和毫秒都是0
|
||||
let options = {
|
||||
year: 'numeric',
|
||||
month: '2-digit',
|
||||
day: '2-digit',
|
||||
hour: '2-digit',
|
||||
minute: '2-digit',
|
||||
second: '2-digit'
|
||||
}
|
||||
let hours = String(newDate.getHours()).padStart(2, '0')
|
||||
let minutes = String(newDate.getMinutes()).padStart(2, '0')
|
||||
let seconds = String(newDate.getSeconds()).padStart(2, '0')
|
||||
let formattedDateString = `${hours}:${minutes}:${seconds}`
|
||||
hourPoints.push(formattedDateString)
|
||||
}
|
||||
return hourPoints;
|
||||
},
|
||||
// 请求正在进行中的订单
|
||||
getorder(){
|
||||
this.$u.get(`/app/order/getInProgressOrderList`).then(res =>{
|
||||
if(res.code == 200){
|
||||
this.jinxinglist = res.data
|
||||
let hourPoints = []
|
||||
for (let i = 0; i < 24; i++) {
|
||||
let newDate = new Date(startDate)
|
||||
newDate.setHours((startHour + i) % 24, 0, 0, 0)
|
||||
if (newDate.getHours() === 0 && i !== 0) {
|
||||
newDate.setDate(newDate.getDate() + 1)
|
||||
}
|
||||
let hours = String(newDate.getHours()).padStart(2, '0')
|
||||
let minutes = String(newDate.getMinutes()).padStart(2, '0')
|
||||
let seconds = String(newDate.getSeconds()).padStart(2, '0')
|
||||
let formattedDateString = `${hours}:${minutes}:${seconds}`
|
||||
hourPoints.push(formattedDateString)
|
||||
}
|
||||
})
|
||||
},
|
||||
// 点击进行开店门开包厢等操作
|
||||
btnopen(num){
|
||||
if(num == 1){
|
||||
this.$u.get(`app/store/openGate/1`).then(res => {
|
||||
return hourPoints;
|
||||
},
|
||||
// 请求正在进行中的订单
|
||||
getorder() {
|
||||
this.$u.get(`/app/order/getInProgressOrderList`).then(res => {
|
||||
if (res.code == 200) {
|
||||
this.jinxinglist = res.data
|
||||
}
|
||||
})
|
||||
},
|
||||
// 选择订单后进行操作
|
||||
btnanniu(){
|
||||
if(this.jinxintxt == '开店门'){
|
||||
let storeId = this.jinxinglist[this.mdindex].storeId
|
||||
console.log(this.jinxinglist[this.mdindex],this.mdindex);
|
||||
this.$u.get(`app/store/openGate/${storeId}`).then(res => {
|
||||
if(res.code == 200){
|
||||
this.jinxinflag = false
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: '开启店门成功',
|
||||
icon: 'success',
|
||||
title: '开启店门成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
})
|
||||
}else{
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none',
|
||||
duration: 2000
|
||||
})
|
||||
}
|
||||
})
|
||||
}else if(this.jinxintxt == '开包厢'){
|
||||
let roomId = this.jinxinglist[this.mdindex].roomId
|
||||
this.$u.get(`app/room/openRoomGate/${roomId}`).then(res => {
|
||||
if(res.code == 200){
|
||||
this.jinxinflag = false
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: '开启包厢门成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
})
|
||||
}else{
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none',
|
||||
duration: 2000
|
||||
})
|
||||
}
|
||||
})
|
||||
}else if(this.jinxintxt == '去续单'){
|
||||
this.jinxinflag = false
|
||||
let roomId = this.jinxinglist[this.mdindex].roomId
|
||||
let orderNo = this.jinxinglist[this.mdindex].orderNo
|
||||
uni.navigateTo({
|
||||
url:'/page_user/xudan?roomId=' + roomId + '&orderNo=' + orderNo + '&viewType=' + this.viewType
|
||||
})
|
||||
}
|
||||
},
|
||||
// 点击进行开店门开包厢等操作
|
||||
btnopen(num){
|
||||
if(num == 1){
|
||||
if(this.jinxinglist.length > 1){
|
||||
this.jinxinflag = true
|
||||
this.jinxintxt = '开店门'
|
||||
}else if(this.jinxinglist.length == 1){
|
||||
let storeId = this.jinxinglist[0].storeId
|
||||
this.$u.get(`app/store/openGate/${storeId}`).then(res => {
|
||||
if(res.code == 200){
|
||||
uni.showToast({
|
||||
title: '开启店门成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
})
|
||||
}else{
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
|
|
@ -396,6 +509,13 @@
|
|||
})
|
||||
}
|
||||
})
|
||||
}else{
|
||||
uni.showToast({
|
||||
title: '您当前没有订单',
|
||||
icon: 'none',
|
||||
duration: 2000
|
||||
})
|
||||
}
|
||||
}else if(num == 2){
|
||||
if(this.jinxinglist.length > 1){
|
||||
this.jinxinflag = true
|
||||
|
|
@ -441,18 +561,38 @@
|
|||
duration: 2000
|
||||
})
|
||||
}
|
||||
}else if(num == 4){
|
||||
uni.scanCode({
|
||||
onlyFromCamera: true,
|
||||
scanType: ['qrCode'],
|
||||
success: res => {
|
||||
console.log(res);
|
||||
},
|
||||
fail: err => {
|
||||
console.error('扫描失败:', err)
|
||||
uni.showToast({
|
||||
title: '扫描失败',
|
||||
icon: 'none'
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
// 请求门店详细信息
|
||||
getstoredetail() {
|
||||
this.reservationStatus = {}
|
||||
this.$u.get(`app/store/${this.storeId}`).then(res => {
|
||||
let data = {
|
||||
type: this.biaoqianlist[0].type == null ? '' : this.biaoqianlist[0].type
|
||||
}
|
||||
this.$u.get(`/app/store/${this.storeId}`, data).then(res => {
|
||||
if (res.code == 200) {
|
||||
this.shopobj = res.data
|
||||
if(res.data.carouselList != '' || res.data.carouselList.length > 0){
|
||||
this.list = []
|
||||
this.list = res.data.carouselList.map(item => item.picture)
|
||||
if (res.data.picture != null) {
|
||||
let pictureArray = res.data.picture.split(',')
|
||||
this.list = pictureArray.map(pictureUrl => ({
|
||||
image: pictureUrl
|
||||
}))
|
||||
}
|
||||
this.roomList = res.data.roomList //赋值所有房间
|
||||
this.initializeData() //在this.roomlist赋值后调用
|
||||
|
|
@ -460,15 +600,15 @@
|
|||
}
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
// 点击进行导航
|
||||
btndaohang(){
|
||||
|
||||
|
||||
// 点击进行导航
|
||||
btndaohang() {
|
||||
uni.openLocation({
|
||||
latitude:this.shopobj.lat,//纬度-目的地/坐标点
|
||||
longitude:this.shopobj.lng,//经度-目的地/坐标点
|
||||
name:this.shopobj.name,//地点名称
|
||||
address:this.shopobj.addres//详细地点名称
|
||||
latitude: this.shopobj.lat, //纬度-目的地/坐标点
|
||||
longitude: this.shopobj.lng, //经度-目的地/坐标点
|
||||
name: this.shopobj.name, //地点名称
|
||||
address: this.shopobj.addres //详细地点名称
|
||||
})
|
||||
},
|
||||
// 按下滑动
|
||||
|
|
@ -484,9 +624,9 @@
|
|||
this.imgflag = true
|
||||
},
|
||||
// 点击跳转包厢详情页
|
||||
btndetail(roomId) {
|
||||
btndetail(item) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/myorder/index?roomId=' + roomId
|
||||
url: '/pages/myorder/index?roomId=' + item.roomId + '&viewType=' + item.viewType
|
||||
})
|
||||
},
|
||||
// 点击自定义导航栏返回首页
|
||||
|
|
@ -513,7 +653,7 @@
|
|||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
|
|
@ -529,38 +669,43 @@
|
|||
|
||||
.hour-item.is-reserved {
|
||||
background-color: #48893B !important;
|
||||
/* 如果被预订,则显示红色 */
|
||||
}
|
||||
#active{
|
||||
|
||||
#active {
|
||||
border: 1px solid #226914 !important;
|
||||
background-color: #226914 !important;
|
||||
background-color: #226914 !important;
|
||||
color: #fff !important;
|
||||
}
|
||||
.taiqiubox{
|
||||
|
||||
.taiqiubox {
|
||||
max-height: 710rpx;
|
||||
overflow: scroll;
|
||||
padding-bottom: 240rpx;
|
||||
box-sizing: border-box;
|
||||
.zhuozi{
|
||||
|
||||
.zhuozi {
|
||||
width: 99%;
|
||||
max-height: 5632rpx;
|
||||
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.15);
|
||||
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0, 0, 0, 0.15);
|
||||
margin: auto;
|
||||
margin-top: 10rpx;
|
||||
padding: 10rpx;
|
||||
padding-top: 0;
|
||||
box-sizing: border-box;
|
||||
border-radius: 10rpx;
|
||||
.tqlist{
|
||||
|
||||
.tqlist {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
.tqlist_item{
|
||||
|
||||
.tqlist_item {
|
||||
width: 308rpx;
|
||||
height: 180rpx;
|
||||
position: relative;
|
||||
margin-top: 16rpx;
|
||||
.name{
|
||||
|
||||
.name {
|
||||
font-size: 36rpx;
|
||||
color: #FFFFFF;
|
||||
width: 100%;
|
||||
|
|
@ -568,7 +713,8 @@
|
|||
padding-top: 34rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.kaitai{
|
||||
|
||||
.kaitai {
|
||||
width: 90rpx;
|
||||
height: 42rpx;
|
||||
background: #C5DFC0;
|
||||
|
|
@ -580,7 +726,8 @@
|
|||
margin: auto;
|
||||
margin-top: 14rpx;
|
||||
}
|
||||
image{
|
||||
|
||||
image {
|
||||
position: absolute;
|
||||
width: 308rpx;
|
||||
height: 180rpx;
|
||||
|
|
@ -589,17 +736,20 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
.gangui{
|
||||
|
||||
.gangui {
|
||||
width: 674rpx;
|
||||
height: 298rpx;
|
||||
position: relative;
|
||||
margin-top: 16rpx;
|
||||
image{
|
||||
|
||||
image {
|
||||
position: absolute;
|
||||
width: 674rpx;
|
||||
height: 298rpx;
|
||||
}
|
||||
.cun{
|
||||
|
||||
.cun {
|
||||
width: 92rpx;
|
||||
height: 92rpx;
|
||||
background: #48893B;
|
||||
|
|
@ -611,68 +761,80 @@
|
|||
color: #FFFFFF;
|
||||
}
|
||||
}
|
||||
.tqname{
|
||||
|
||||
.tqname {
|
||||
font-weight: 600;
|
||||
font-size: 32rpx;
|
||||
color: #3D3D3D;
|
||||
margin-top: 44rpx;
|
||||
}
|
||||
}
|
||||
.typewz{
|
||||
|
||||
.typewz {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-top: 16rpx;
|
||||
margin-bottom: 10rpx;
|
||||
.one{
|
||||
|
||||
.one {
|
||||
font-weight: 600;
|
||||
font-size: 32rpx;
|
||||
color: #3D3D3D;
|
||||
margin-right: 20rpx;
|
||||
}
|
||||
.two{
|
||||
|
||||
.two {
|
||||
font-size: 24rpx;
|
||||
color: #3D3D3D;
|
||||
}
|
||||
}
|
||||
.tongji{
|
||||
width: 100%;
|
||||
height: 120rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 0rpx 0rpx 0rpx 0rpx;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
.one{
|
||||
|
||||
.tongji {
|
||||
width: 100%;
|
||||
height: 120rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 0rpx 0rpx 0rpx 0rpx;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
|
||||
.one {
|
||||
width: 188rpx;
|
||||
text-align: center;
|
||||
.kg{
|
||||
|
||||
.kg {
|
||||
font-weight: 600;
|
||||
font-size: 24rpx;
|
||||
color: #3D3D3D;
|
||||
text{
|
||||
|
||||
text {
|
||||
color: #48893B;
|
||||
margin-left: 4rpx;
|
||||
}
|
||||
}
|
||||
.gn{
|
||||
|
||||
.gn {
|
||||
font-weight: 600;
|
||||
font-size: 32rpx;
|
||||
color: #3D3D3D;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
image{
|
||||
|
||||
image {
|
||||
width: 58rpx;
|
||||
height: 14rpx;
|
||||
}
|
||||
}
|
||||
.xian{
|
||||
|
||||
.xian {
|
||||
width: 1px;
|
||||
height: 62rpx;
|
||||
background-color: #3D3D3D;
|
||||
}
|
||||
}
|
||||
.karaokeroom{
|
||||
|
||||
.karaokeroom {
|
||||
position: fixed;
|
||||
top: 332rpx;
|
||||
left: 50%;
|
||||
|
|
@ -680,9 +842,10 @@
|
|||
z-index: 2;
|
||||
width: 674rpx;
|
||||
height: 828rpx;
|
||||
background: linear-gradient( 180deg, #DEF1DA 0%, #FFFFFF 100%, #FFFFFF 100%);
|
||||
background: linear-gradient(180deg, #DEF1DA 0%, #FFFFFF 100%, #FFFFFF 100%);
|
||||
border-radius: 36rpx 36rpx 36rpx 36rpx;
|
||||
.top{
|
||||
|
||||
.top {
|
||||
font-weight: 600;
|
||||
font-size: 44rpx;
|
||||
color: #48893B;
|
||||
|
|
@ -691,7 +854,8 @@
|
|||
margin-top: 52rpx;
|
||||
margin-bottom: 44rpx;
|
||||
}
|
||||
.anniu{
|
||||
|
||||
.anniu {
|
||||
width: 584rpx;
|
||||
height: 86rpx;
|
||||
background: #48893B;
|
||||
|
|
@ -706,10 +870,12 @@
|
|||
transform: translateX(-50%);
|
||||
bottom: 72rpx;
|
||||
}
|
||||
.roomlist{
|
||||
|
||||
.roomlist {
|
||||
height: 480rpx;
|
||||
overflow: scroll;
|
||||
.room_item{
|
||||
|
||||
.room_item {
|
||||
width: 584rpx;
|
||||
height: 224rpx;
|
||||
border: 2rpx solid #969696;
|
||||
|
|
@ -721,17 +887,20 @@
|
|||
padding: 34rpx;
|
||||
box-sizing: border-box;
|
||||
margin-top: 26rpx;
|
||||
.lt{
|
||||
image{
|
||||
|
||||
.lt {
|
||||
image {
|
||||
width: 154rpx;
|
||||
height: 154rpx;
|
||||
margin-right: 22rpx;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.jinxinx{
|
||||
|
||||
.jinxinx {
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
position: fixed;
|
||||
|
|
@ -740,7 +909,8 @@
|
|||
transform: translateX(-50%);
|
||||
z-index: 2;
|
||||
}
|
||||
.mask{
|
||||
|
||||
.mask {
|
||||
width: 100%;
|
||||
height: 100vh;
|
||||
position: fixed;
|
||||
|
|
@ -949,6 +1119,19 @@
|
|||
font-size: 34rpx;
|
||||
color: #48893B;
|
||||
font-weight: 600;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
text{
|
||||
display: inline-block;
|
||||
padding:4rpx 8rpx;
|
||||
margin-left: 10rpx;
|
||||
border-radius: 10rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: #226914;
|
||||
color: #fff;
|
||||
font-weight: 400;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.price {
|
||||
|
|
@ -1072,7 +1255,8 @@
|
|||
position: absolute;
|
||||
left: 20rpx;
|
||||
bottom: 14rpx;
|
||||
width: 100%;
|
||||
width: 100%;
|
||||
|
||||
view {
|
||||
height: 52rpx;
|
||||
text-align: center;
|
||||
|
|
|
|||
16
pages/my.vue
16
pages/my.vue
|
|
@ -85,9 +85,9 @@
|
|||
<image src="https://api.ccttiot.com/smartmeter/img/static/usIK790XacHJ1pXUbbfW" mode=""></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="luru" @click="btnluru">
|
||||
<!-- <view class="luru" @click="btnluru">
|
||||
录入
|
||||
</view>
|
||||
</view> -->
|
||||
<view class="kfimg" v-if="flag">
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/uc8dAVNneEshmNJjPW3w" mode=""></image>
|
||||
<view class="boda">
|
||||
|
|
@ -138,11 +138,11 @@
|
|||
},
|
||||
methods: {
|
||||
// 点击进行设备录入
|
||||
btnluru(){
|
||||
uni.navigateTo({
|
||||
url:'/page_user/luru'
|
||||
})
|
||||
},
|
||||
// btnluru(){
|
||||
// uni.navigateTo({
|
||||
// url:'/page_user/luru'
|
||||
// })
|
||||
// },
|
||||
// 点击拨打电话
|
||||
call(num){
|
||||
if(num == 1){
|
||||
|
|
@ -231,7 +231,7 @@
|
|||
// onlyFromCamera: true,
|
||||
// scanType: ['qrCode'],
|
||||
// success: res => {
|
||||
// console.log(res);
|
||||
// console.log(res);
|
||||
// },
|
||||
// fail: err => {
|
||||
// console.error('扫描失败:', err)
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<u-navbar title="包厢预定" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
|
||||
title-size='36' height='36' id="navbar">
|
||||
</u-navbar>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/umk1caLMk7f1elQ2T78c" mode="" class="imgbj"></image>
|
||||
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
|
||||
<view class="boxda">
|
||||
<view class="fangjian">
|
||||
<view class="top">
|
||||
|
|
@ -19,7 +19,7 @@
|
|||
</view>
|
||||
<view class="leixing">
|
||||
<view class="" v-for="(item,index) in shopobj.tags">
|
||||
{{item}}
|
||||
{{getMatchingLabel(item)}}
|
||||
</view>
|
||||
</view>
|
||||
<view class="price">
|
||||
|
|
@ -30,6 +30,9 @@
|
|||
</view>
|
||||
<view class="appointment">
|
||||
<view class="riqi">
|
||||
<view class="tcxzname">
|
||||
日期选择:
|
||||
</view>
|
||||
<view class="yyshijian">
|
||||
<view class="shijian_item" v-for="(item,index) in weekdayAndDateSequence"
|
||||
:id="indexone == index ? 'active' : ''" :key="index" @click="btnyd(index,item)">
|
||||
|
|
@ -319,11 +322,14 @@
|
|||
user: {},
|
||||
zfss: '微信支付',
|
||||
zfssid: 'wx',
|
||||
timeshijian:''
|
||||
timeshijian:'',
|
||||
viewType:''
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
this.roomId = option.roomId
|
||||
this.viewType = option.viewType
|
||||
this.getbiaoqian()
|
||||
this.getstoredetail()
|
||||
this.gettaocan()
|
||||
this.hourPointsArray = this.getCurrentHourPoints() //计算从当前时间往后推24小时
|
||||
|
|
@ -337,6 +343,20 @@
|
|||
console.log(this.weekdayAndDateSequence);
|
||||
},
|
||||
methods: {
|
||||
// 拿到标签进行对比
|
||||
getMatchingLabel(item) {
|
||||
const matchingItem = this.biaoqianlist.find(items => items.dictValue === item)
|
||||
return matchingItem ? matchingItem.dictLabel : item
|
||||
},
|
||||
// 获取标签
|
||||
getbiaoqian(){
|
||||
this.$u.get(`/appVerify/getDictData?dictType=ss_room_tags`).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.biaoqianlist = res.data
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
convertDates(array) {
|
||||
return array.map(item => {
|
||||
// 将日期字符串转换为 Date 对象
|
||||
|
|
@ -553,6 +573,7 @@
|
|||
// let formattedDateString = time.replace(/\//g, "-")
|
||||
let data = {
|
||||
roomId: this.roomId,
|
||||
viewType:this.viewType,
|
||||
payType: this.zfssid,
|
||||
ruleId: this.tcobj.ruleId,
|
||||
type: 1,
|
||||
|
|
@ -574,7 +595,7 @@
|
|||
success: (res) => {
|
||||
console.log(res, '支付成功')
|
||||
uni.navigateTo({
|
||||
url:'/page_user/dingdanxq?orderNo=' + orderNo
|
||||
url:'/page_user/dingdanxq?orderNo=' + orderNo + '&viewType=' + this.viewType
|
||||
})
|
||||
},
|
||||
fail(err) {
|
||||
|
|
@ -995,7 +1016,7 @@
|
|||
overflow: hidden;
|
||||
.yudingtrue {
|
||||
width: 600rpx;
|
||||
height: 806rpx;
|
||||
max-height: 999rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 32rpx 32rpx 32rpx 32rpx;
|
||||
padding: 0 20rpx;
|
||||
|
|
@ -1004,7 +1025,7 @@
|
|||
top: 388rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
|
||||
padding-bottom: 30rpx;
|
||||
.shuom {
|
||||
.xuzhi {
|
||||
font-weight: 600;
|
||||
|
|
@ -1453,9 +1474,9 @@
|
|||
}
|
||||
|
||||
.tcxz {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-top: 50rpx;
|
||||
// display: flex;
|
||||
// align-items: center;
|
||||
margin-top: 30rpx;
|
||||
width: 3000rpx;
|
||||
}
|
||||
|
||||
|
|
@ -1468,9 +1489,10 @@
|
|||
|
||||
.tcxz .taocan {
|
||||
display: flex;
|
||||
width: 420rpx;
|
||||
width: 610rpx;
|
||||
overflow-x: auto;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
margin-top: 22rpx;
|
||||
}
|
||||
|
||||
.tcxz .taocan .tclist {
|
||||
|
|
@ -1496,7 +1518,12 @@
|
|||
|
||||
.riqi {
|
||||
margin-top: 42rpx;
|
||||
|
||||
.tcxzname {
|
||||
font-size: 32rpx;
|
||||
color: #3D3D3D;
|
||||
font-weight: 600;
|
||||
width: 160rpx;
|
||||
}
|
||||
image {
|
||||
width: 54rpx;
|
||||
height: 54rpx;
|
||||
|
|
@ -1505,7 +1532,7 @@
|
|||
.yyshijian {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
||||
margin-top: 22rpx;
|
||||
.shijian_item {
|
||||
width: 112rpx;
|
||||
height: 88rpx;
|
||||
|
|
@ -1531,7 +1558,7 @@
|
|||
margin: auto;
|
||||
overflow: hidden;
|
||||
margin-top: 24rpx;
|
||||
|
||||
padding-top: 0;
|
||||
.top {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@
|
|||
@touchcancel="onTouchCancel">
|
||||
<view class="shop_item" v-for="(item,index) in listshop" :key="index" @click="btndetail(item.storeId)">
|
||||
<view class="lt">
|
||||
<image :src="item.picture" mode="aspectFill"></image>
|
||||
<image :src="item.picture.split(',')[0]" mode="aspectFill"></image>
|
||||
<view class="hour">
|
||||
{{item.minimumTime == undefined ? '--' : item.minimumTime}}小时起订
|
||||
</view>
|
||||
|
|
@ -94,7 +94,7 @@
|
|||
正在进行中的订单
|
||||
</view>
|
||||
<view class="roomlist">
|
||||
<view class="room_item" v-for="(item,index) in jinxinglist" :key="index" :id="mdindex == index ? 'active' : ''" @click="btnmd(index)">
|
||||
<view class="room_item" v-for="(item,index) in jinxinglist" :key="index" :id="mdindex == index ? 'active' : ''" @click="btnmd(index,item)">
|
||||
<view class="lt">
|
||||
<image :src="item.picture" mode=""></image>
|
||||
</view>
|
||||
|
|
@ -143,9 +143,11 @@
|
|||
qingqiuflag:true,
|
||||
jinxinglist:[],
|
||||
mdindex:-1,
|
||||
viewType:'',
|
||||
jinxinflag:false,
|
||||
sousuovalue:'',
|
||||
tabindex:1
|
||||
tabindex:1,
|
||||
type:1
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
|
|
@ -165,6 +167,10 @@
|
|||
// 点击切换门店类型
|
||||
btntabindex(num){
|
||||
this.tabindex = num
|
||||
this.type = num
|
||||
this.pagesum = 1
|
||||
this.listshop = []
|
||||
this.getshop()
|
||||
},
|
||||
// 点击跳转到商户中心
|
||||
btnshanghu(){
|
||||
|
|
@ -173,7 +179,8 @@
|
|||
})
|
||||
},
|
||||
// 点击选择开包厢
|
||||
btnmd(index){
|
||||
btnmd(index,item){
|
||||
this.viewType = item.viewType
|
||||
this.mdindex = index
|
||||
},
|
||||
// 请求正在进行中的订单
|
||||
|
|
@ -217,12 +224,14 @@
|
|||
this.$u.get(`app/store/openGate/${storeId}`).then(res => {
|
||||
if(res.code == 200){
|
||||
this.jinxinflag = false
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: '开启店门成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
})
|
||||
}else{
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none',
|
||||
|
|
@ -235,12 +244,14 @@
|
|||
this.$u.get(`app/room/openRoomGate/${roomId}`).then(res => {
|
||||
if(res.code == 200){
|
||||
this.jinxinflag = false
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: '开启包厢门成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
})
|
||||
}else{
|
||||
this.mdindex = -1
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none',
|
||||
|
|
@ -249,11 +260,11 @@
|
|||
}
|
||||
})
|
||||
}else if(this.jinxintxt == '去续单'){
|
||||
this.jinxinflag = false
|
||||
this.jinxinflag = false
|
||||
let roomId = this.jinxinglist[this.mdindex].roomId
|
||||
let orderNo = this.jinxinglist[this.mdindex].orderNo
|
||||
uni.navigateTo({
|
||||
url:'/page_user/xudan?roomId=' + roomId + '&orderNo=' + orderNo
|
||||
url:'/page_user/xudan?roomId=' + roomId + '&orderNo=' + orderNo + '&viewType=' + this.viewType
|
||||
})
|
||||
}
|
||||
},
|
||||
|
|
@ -359,7 +370,8 @@
|
|||
phoneLon:this.longitude,
|
||||
phoneLat:this.latitude,
|
||||
cityId:this.cityid,
|
||||
keyword:this.sousuovalue
|
||||
keyword:this.sousuovalue,
|
||||
type:this.type
|
||||
}
|
||||
this.$u.post(`/app/getStoreListByLocation?pageNum=${this.pagesum}&pageSize=${this.pagesize}`,data).then(res => {
|
||||
if(res.code == 200){
|
||||
|
|
@ -594,6 +606,7 @@
|
|||
width: 154rpx;
|
||||
height: 154rpx;
|
||||
margin-right: 22rpx;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
13
pages/tj.vue
13
pages/tj.vue
|
|
@ -3,7 +3,7 @@
|
|||
<u-navbar :is-back="false" title="订单管理" :border-bottom="false" back-icon-color="000" :background="bgc" title-color='#000' title-size='36'
|
||||
height='40' id="navbar">
|
||||
</u-navbar>
|
||||
<image class="imgbj" src="https://api.ccttiot.com/smartmeter/img/static/uPH2JsGAqk9GoRjh1xzc" mode=""></image>
|
||||
<image class="imgbj" src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode=""></image>
|
||||
<view class="tab">
|
||||
<view :class="tabindex == index ? 'active' : ''" @click="btntab(index,item)" v-for="(item,index) in tablist" :key="index">
|
||||
{{item.name}}
|
||||
|
|
@ -110,8 +110,9 @@
|
|||
dingdanindex:0,
|
||||
dingdanlist:[
|
||||
{name:'茶室订单',value:'1'},
|
||||
{name:'加时订单',value:'2'},
|
||||
{name:'货柜订单',value:'3'},
|
||||
{name:'棋牌订单',value:'2'},
|
||||
{name:'台球订单',value:'3'},
|
||||
{name:'货柜订单',value:'4'},
|
||||
],
|
||||
orderlist:[],
|
||||
type:'1',
|
||||
|
|
@ -234,7 +235,7 @@
|
|||
orderNo:orderNos,
|
||||
type:2
|
||||
}
|
||||
that.$u.post(`/app/order/orderCancel?orderNo=${orderNos}&type=2`,data).then(res => {
|
||||
that.$u.post(`/app/order/orderEnd?orderNo=${orderNos}`,data).then(res => {
|
||||
if (res.code == 200) {
|
||||
uni.showToast({
|
||||
title: '结束成功',
|
||||
|
|
@ -269,7 +270,7 @@
|
|||
orderNo:orderNos,
|
||||
type:1
|
||||
}
|
||||
that.$u.post(`/app/order/orderCancel?orderNo=${orderNos}&type=1`,data).then(res => {
|
||||
that.$u.post(`/app/order/orderCancel?orderNo=${orderNos}`,data).then(res => {
|
||||
if (res.code == 200) {
|
||||
uni.showToast({
|
||||
title: '取消成功',
|
||||
|
|
@ -328,7 +329,7 @@
|
|||
padding: 0 38rpx;
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
max-height: 1040rpx;
|
||||
max-height: 1020rpx;
|
||||
overflow: scroll;
|
||||
padding-bottom: 50rpx;
|
||||
.list_item{
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user