This commit is contained in:
3321822538@qq.com 2024-12-30 18:02:38 +08:00
parent f12bb10d0c
commit 8addab5394
14 changed files with 1794 additions and 260 deletions

View File

@ -20,8 +20,8 @@ const install = (Vue, vm) => {
// },
// https://yxd.ccttiot.com/prod-api});
Vue.prototype.$u.http.setConfig({
// baseUrl: 'http://192.168.2.116:8089',
baseUrl: 'https://testcha.chuangtewl.com/prod-api',
baseUrl: 'http://192.168.2.116:8089',
// baseUrl: 'https://testcha.chuangtewl.com/prod-api',
loadingText: '努力加载中~',
loadingTime: 800,
// 设置自定义头部content-type

View File

@ -20,12 +20,12 @@
{{ksfs}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
</view>
</view>
<view class="ulbox">
<view class="ulbox" @click="dtflags = true">
<view class="one">
设备绑定
</view>
<view class="two">
{{sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
{{obj.device.sn == null ? '' : obj.device.sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
</view>
</view>
<view class="ulbox" style="border: none;" @click="btnshoufei">
@ -51,6 +51,52 @@
</view>
</view>
<view class="mask" style="z-index: 3;" v-if="dtflags"></view>
<view class="addmen" v-if="dtflags">
<view class="top">
<view class="cha" @click="dtflags = false">
×
</view>
<view class="name">
请选择投放设备方式
</view>
</view>
<view class="one" @click="btnsaoma">
<view class="lt">
<view class="saoma">
扫码投放
</view>
<view class="saomas">
扫描设备上的二维码
</view>
<view class="saomas">
投放设施
</view>
</view>
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
<view class="one" @click="btntouf">
<view class="lt">
<view class="saoma">
未投放设备列表投放
</view>
<view class="saomas">
选择未投放列表中的设备
</view>
<view class="saomas">
投放设施
</view>
</view>
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
</view>
</view>
</template>
@ -73,16 +119,18 @@
equipmentId:'',
name:'',
type:'',
sn:'',
obj:{},
namelist:[],
ruleIdlist:[],
dtflags: false,
}
},
onLoad(option) {
this.equipmentId = option.equipmentId
this.getxx()
},
onShow() {
this.getxx()
this.namelist = []
if(uni.getStorageSync('namelist') && uni.getStorageSync('ruleIdlist')){
this.namelist = uni.getStorageSync('namelist')
this.ruleIdlist = uni.getStorageSync('ruleIdlist')
@ -99,6 +147,53 @@
uni.removeStorageSync('ruleIdlist')
},
methods: {
//
btntouf(){
this.dtflags = false
uni.navigateTo({
url: '/page_shanghu/weishebei?equipmentId=' + this.obj.equipmentId
})
},
//
btnsaoma() {
uni.scanCode({
onlyFromCamera: true,
scanType: ['qrCode'],
success: res => {
function getQueryParam(url, paramName) {
let regex = new RegExp(`[?&]${paramName}=([^&]*)`)
let results = regex.exec(url);
return results ? decodeURIComponent(results[1].replace(/\+/g, ' ')) : null
}
console.log(res);
let sceneValue = res.result
let decodedValue = decodeURIComponent(sceneValue)
let id = getQueryParam(decodedValue, 'sn')
let that = this
let data = {
deviceId: id,
equipmentId: this.obj.equipmentId
}
that.$u.put(`/app/store/bandGate`, data).then(res => {
if (res.code == 200) {
uni.showToast({
title: '绑定成功',
icon: 'success',
duration: 2000
})
that.dtflags = false
this.getxx()
} else {
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
}
})
},
//
btndel(){
let that = this
@ -188,9 +283,7 @@
}else if(res.data.type == 3){
this.ksfs = '棋牌桌'
}
if(res.data.device.sn){
this.sn = res.data.device.sn
}
this.obj = res.data
}
})
},
@ -204,6 +297,89 @@
padding-bottom: 20rpx;
box-sizing: border-box;
}
.mask{
width: 100%;
height: 100vh;
background-color: #000;
opacity: .3;
position: fixed;
top: 0;
left: 0;
}
.addmen {
width: 694rpx;
height: 702rpx;
background: linear-gradient(180deg, #DEF1DA 0%, #FFFFFF 100%, #FFFFFF 100%);
border-radius: 36rpx 36rpx 36rpx 36rpx;
position: fixed;
top: 464rpx;
left: 50%;
transform: translateX(-50%);
z-index: 3;
box-shadow: 1px 2px 4px -3px;
.one {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
.rt {
image {
width: 60rpx;
height: 60rpx;
}
}
.saoma {
font-weight: 600;
font-size: 36rpx;
color: #48893B;
margin-top: 10rpx;
}
.saomas {
font-size: 28rpx;
color: #48893B;
margin-top: 10rpx;
}
width: 584rpx;
height: 224rpx;
border: 2rpx solid #48893B;
border-radius: 20rpx;
margin: auto;
margin-top: 48rpx;
padding: 38rpx 44rpx;
box-sizing: border-box;
}
.top {
display: flex;
flex-wrap: wrap;
padding: 0 26rpx;
box-sizing: border-box;
.name {
font-weight: 600;
font-size: 44rpx;
color: #48893B;
width: 100%;
text-align: center;
position: absolute;
top: 56rpx;
left: 50%;
transform: translateX(-50%);
}
.cha {
font-size: 68rpx;
font-weight: 600;
width: 100%;
text-align: right;
}
}
}
.wz{
font-size: 24rpx;
color: #3D3D3D;

View File

@ -47,24 +47,69 @@
<u-select v-model="showone" :list="listone" @confirm="btnone"></u-select>
<u-picker mode="time" v-model="showtwo" :params="params" @confirm="btntwo"></u-picker>
<u-select v-model="showthr" :list="listthr" @confirm="btnthr"></u-select>
<view class="ulbox" style="border: none;">
<view class="ulbox" style="border: none;" @click="dtflags = true" v-if="obj.equipmentId">
<view class="one">
设备绑定
</view>
<view class="two">
{{sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
{{obj.device.sn == null ? '' : obj.device.sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
</view>
</view>
</view>
<view class="anniu">
<view class="tougang" @click="btndel">
删除
{{txtdel}}
</view>
<view class="tougang" @click="btnshop">
修改
{{txt}}
</view>
</view>
<view class="mask" style="z-index: 3;" v-if="dtflags"></view>
<view class="addmen" v-if="dtflags">
<view class="top">
<view class="cha" @click="dtflags = false">
×
</view>
<view class="name">
请选择投放设备方式
</view>
</view>
<view class="one" @click="btnsaoma">
<view class="lt">
<view class="saoma">
扫码投放
</view>
<view class="saomas">
扫描设备上的二维码
</view>
<view class="saomas">
投放设施
</view>
</view>
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
<view class="one" @click="btntouf">
<view class="lt">
<view class="saoma">
未投放设备列表投放
</view>
<view class="saomas">
选择未投放列表中的设备
</view>
<view class="saomas">
投放设施
</view>
</view>
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
</view>
</view>
</template>
@ -75,18 +120,11 @@
bgc: {
backgroundColor: "#fff",
},
listone:[{
alue: '2',
label: '麻将桌'
},{
alue: '3',
label: '台球桌'
}],
listone:[{
value: '1',
label: '通电开锁'
},{
alue: '2',
value: '2',
label: '断电开锁'
}],
listthr:[
@ -121,42 +159,137 @@
kstj:'',
ksfsid:'',
kstjid:'',
tit:'',
txt:'',
txtdel:'',
roomId:'',
obj:{},
dtflags: false,
}
},
onLoad(option) {
this.equipmentId = option.equipmentId
if(option.equipmentId){
this.equipmentId = option.equipmentId
this.tit = '修改卫生间信息'
this.txt = '修改'
this.txtdel = '删除'
}else{
this.txt = '添加'
this.txtdel = '取消'
this.tit = '添加卫生间'
this.roomId = option.roomId
}
},
onShow() {
this.getxx()
},
methods: {
//
btnshop(){
let data = {
equipmentId:this.equipmentId,
name:this.name,
type:this.ksfsid,
unlockMode:this.ksfsid,
unlockCondition:this.kstjid,
unlockTime:this.kstime
}
this.$u.put(`/app/equipment`,data).then(res =>{
if(res.code == 200){
uni.showToast({
title: '修改成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
//
btntouf(){
this.dtflags = false
uni.navigateTo({
url: '/page_shanghu/weishebei?equipmentId=' + this.obj.equipmentId
})
},
//
btnsaoma() {
uni.scanCode({
onlyFromCamera: true,
scanType: ['qrCode'],
success: res => {
function getQueryParam(url, paramName) {
let regex = new RegExp(`[?&]${paramName}=([^&]*)`)
let results = regex.exec(url);
return results ? decodeURIComponent(results[1].replace(/\+/g, ' ')) : null
}
console.log(res);
let sceneValue = res.result
let decodedValue = decodeURIComponent(sceneValue)
let id = getQueryParam(decodedValue, 'sn')
let that = this
let data = {
deviceId: id,
equipmentId: this.obj.equipmentId
}
that.$u.put(`/app/store/bandGate`, data).then(res => {
if (res.code == 200) {
uni.showToast({
title: '绑定成功',
icon: 'success',
duration: 2000
})
that.dtflags = false
this.getxx()
} else {
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
}
})
},
//
btnshop(){
if(this.txt == '修改'){
let data = {
equipmentId:this.equipmentId,
name:this.name,
type:5,
unlockMode:this.ksfsid,
unlockCondition:this.kstjid,
unlockTime:this.kstime
}
this.$u.put(`/app/equipment`,data).then(res =>{
if(res.code == 200){
uni.showToast({
title: '修改成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
}
})
}else{
let data = {
name:this.name,
type:5,
roomId:this.roomId,
unlockMode:this.ksfsid,
unlockCondition:this.kstjid,
unlockTime:this.kstime
}
this.$u.post(`/app/equipment`,data).then(res =>{
if(res.code == 200){
uni.showToast({
title: '添加成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
}
})
}
},
//
btnone(e){
this.ksfs = e[0].label
@ -173,45 +306,50 @@
},
//
btndel(){
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要删除此卫生间吗?',
success: function (res) {
if (res.confirm) {
that.$u.delete(`/app/equipment/${that.equipmentId}`).then((res) => {
if (res.code == 200) {
uni.showToast({
title: '删除成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack({
delta:1
if(this.txtdel == '删除'){
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要删除此卫生间吗?',
success: function (res) {
if (res.confirm) {
that.$u.delete(`/app/equipment/${that.equipmentId}`).then((res) => {
if (res.code == 200) {
uni.showToast({
title: '删除成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack({
delta:1
})
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
}
})
} else if (res.cancel) {
}
}
})
}
})
} else if (res.cancel) {
}
}
})
}else{
uni.navigateBack()
}
},
//
getxx(){
this.$u.get(`/app/equipment/${this.equipmentId}`).then(res => {
if (res.code == 200) {
this.obj = res.data
this.name = res.data.name
this.type = res.data.type
this.sn = res.data.device.sn
// this.sn = res.data.device.sn
this.kstime = res.data.unlockTime
this.ksfsid = res.data.unlockMode
this.kstjid = res.data.unlockCondition
@ -240,6 +378,89 @@
padding-bottom: 20rpx;
box-sizing: border-box;
}
.mask{
width: 100%;
height: 100vh;
background-color: #000;
opacity: .3;
position: fixed;
top: 0;
left: 0;
}
.addmen {
width: 694rpx;
height: 702rpx;
background: linear-gradient(180deg, #DEF1DA 0%, #FFFFFF 100%, #FFFFFF 100%);
border-radius: 36rpx 36rpx 36rpx 36rpx;
position: fixed;
top: 464rpx;
left: 50%;
transform: translateX(-50%);
z-index: 3;
box-shadow: 1px 2px 4px -3px;
.one {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
.rt {
image {
width: 60rpx;
height: 60rpx;
}
}
.saoma {
font-weight: 600;
font-size: 36rpx;
color: #48893B;
margin-top: 10rpx;
}
.saomas {
font-size: 28rpx;
color: #48893B;
margin-top: 10rpx;
}
width: 584rpx;
height: 224rpx;
border: 2rpx solid #48893B;
border-radius: 20rpx;
margin: auto;
margin-top: 48rpx;
padding: 38rpx 44rpx;
box-sizing: border-box;
}
.top {
display: flex;
flex-wrap: wrap;
padding: 0 26rpx;
box-sizing: border-box;
.name {
font-weight: 600;
font-size: 44rpx;
color: #48893B;
width: 100%;
text-align: center;
position: absolute;
top: 56rpx;
left: 50%;
transform: translateX(-50%);
}
.cha {
font-size: 68rpx;
font-weight: 600;
width: 100%;
text-align: right;
}
}
}
.wz{
font-size: 24rpx;
color: #3D3D3D;

View File

@ -454,6 +454,7 @@
onShow() {
this.roomList = []
this.cesuolist = []
this.gateSnflag = false
this.getxq()
this.getmendian()
},
@ -712,8 +713,11 @@
this.roomId = this.datingobj.roomId
this.dtflag = true
} else if (num == 2) {
this.roomId = this.cesuolist[0].roomId
this.dtflags = true
// this.roomId = this.cesuolist[0].roomId
// this.dtflags = true
uni.navigateTo({
url: '/page_shanghu/cesuoxq?roomId=' + this.cesuolist[0].roomId
})
}
},
//
@ -775,7 +779,7 @@
//
btnmendianxq() {
uni.navigateTo({
url: '/page_shanghu/toufsb?deviceId=' + this.gateSnobj.deviceId + '&storeId=' + this.storeId
url: '/page_shanghu/toufsb?storeId=' + this.storeId
})
},
//
@ -832,53 +836,8 @@
url: '/page_moban/weicousuosb'
})
},
//
btntouf() {
uni.navigateTo({
url: '/page_shanghu/weishebei?storeId=' + this.storeId
})
},
//
btnsaoma() {
uni.scanCode({
onlyFromCamera: true,
scanType: ['qrCode'],
success: res => {
function getQueryParam(url, paramName) {
let regex = new RegExp(`[?&]${paramName}=([^&]*)`)
let results = regex.exec(url);
return results ? decodeURIComponent(results[1].replace(/\+/g, ' ')) : null
}
console.log(res);
let sceneValue = res.result
let decodedValue = decodeURIComponent(sceneValue)
let id = getQueryParam(decodedValue, 'sn')
let that = this
let data = {
sn: id,
storeId: this.storeId
}
that.$u.put(`/app/store/bandGate`, data).then(res => {
if (res.code == 200) {
uni.showToast({
title: '绑定成功',
icon: 'success',
duration: 2000
})
that.xuanzeflag = false
that.addmenflag = false
that.getxq()
} else {
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
}
})
},
//
btnroom() {
this.xuanzeflag = true
@ -888,7 +847,7 @@
this.$u.get(`/app/equipment/gateGate?storeId=${this.storeId}`).then(res => {
if (res.code == 200) {
this.gateSnobj = res.data
if (res.data.device.sn) {
if (this.gateSnobj.device.sn) {
this.gateSnflag = true
} else {
this.gateSnflag = false

View File

@ -1,6 +1,6 @@
<template>
<view class="page">
<u-navbar title="房间设施信息" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
<u-navbar :title="tit" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
title-size='36' height='48' id="navbar">
</u-navbar>
<view class="box">
@ -38,12 +38,12 @@
</view>
</view>
<view class="ulbox">
<view class="ulbox" @click="dtflags = true" v-if="obj.equipmentId">
<view class="one">
设备绑定
</view>
<view class="two">
{{sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
{{obj.device.sn == null ? '' : obj.device.sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
</view>
</view>
<u-select v-model="showlx" :list="listlx" @confirm="btnlx"></u-select>
@ -53,13 +53,59 @@
<view class="anniu">
<view class="tougang" @click="btndel">
删除
{{txtdel}}
</view>
<view class="tougang" @click="btnshop">
修改
{{txt}}
</view>
</view>
<view class="mask" style="z-index: 3;" v-if="dtflags"></view>
<view class="addmen" v-if="dtflags">
<view class="top">
<view class="cha" @click="dtflags = false">
×
</view>
<view class="name">
请选择投放设备方式
</view>
</view>
<view class="one" @click="btnsaoma">
<view class="lt">
<view class="saoma">
扫码投放
</view>
<view class="saomas">
扫描设备上的二维码
</view>
<view class="saomas">
投放设施
</view>
</view>
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
<view class="one" @click="btntouf">
<view class="lt">
<view class="saoma">
未投放设备列表投放
</view>
<view class="saomas">
选择未投放列表中的设备
</view>
<view class="saomas">
投放设施
</view>
</view>
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
</view>
</view>
</template>
@ -106,14 +152,30 @@
sn:'',
namelist:[],
ruleIdlist:[],
obj:{}
obj:{},
txt:'',
txtdel:'',
roomId:'',
tit:'',
dtflags: false,
}
},
onLoad(option) {
this.equipmentId = option.equipmentId
this.getxx()
if(option.equipmentId){
this.equipmentId = option.equipmentId
this.txt = '修改'
this.txtdel = '删除'
this.tit = '修改房间设施'
this.getxx()
}else{
this.roomId = option.roomId
this.txt = '添加'
this.txtdel = '取消'
this.tit = '添加房间设施'
}
},
onShow() {
this.getxx()
if(uni.getStorageSync('namelist') && uni.getStorageSync('ruleIdlist')){
this.namelist = uni.getStorageSync('namelist')
this.ruleIdlist = uni.getStorageSync('ruleIdlist')
@ -130,6 +192,53 @@
uni.removeStorageSync('ruleIdlist')
},
methods: {
//
btntouf(){
this.dtflags = false
uni.navigateTo({
url: '/page_shanghu/weishebei?equipmentId=' + this.obj.equipmentId
})
},
//
btnsaoma() {
uni.scanCode({
onlyFromCamera: true,
scanType: ['qrCode'],
success: res => {
function getQueryParam(url, paramName) {
let regex = new RegExp(`[?&]${paramName}=([^&]*)`)
let results = regex.exec(url);
return results ? decodeURIComponent(results[1].replace(/\+/g, ' ')) : null
}
console.log(res);
let sceneValue = res.result
let decodedValue = decodeURIComponent(sceneValue)
let id = getQueryParam(decodedValue, 'sn')
let that = this
let data = {
deviceId: id,
equipmentId: this.obj.equipmentId
}
that.$u.put(`/app/store/bandGate`, data).then(res => {
if (res.code == 200) {
uni.showToast({
title: '绑定成功',
icon: 'success',
duration: 2000
})
that.dtflags = false
this.getxx()
} else {
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
}
})
},
//
btnone(e){
this.ksfs = e[0].label
@ -141,67 +250,99 @@
},
//
btndel(){
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要删除此设施吗?',
success: function (res) {
if (res.confirm) {
that.$u.delete(`/app/equipment/${that.equipmentId}`).then((res) => {
if (res.code == 200) {
uni.showToast({
title: '删除成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack({
delta:1
if(this.txtdel == '删除'){
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要删除此设施吗?',
success: function (res) {
if (res.confirm) {
that.$u.delete(`/app/equipment/${that.equipmentId}`).then((res) => {
if (res.code == 200) {
uni.showToast({
title: '删除成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack({
delta:1
})
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
}
})
} else if (res.cancel) {
}
}
})
}
})
} else if (res.cancel) {
}
}
})
}else{
uni.navigateBack()
}
},
//
btnshop(){
console.log(this.ksfsid);
let data = {
equipmentId:this.equipmentId,
name:this.name,
type:this.kslxid,
ruleIds:this.ruleIdlist,
unlockMode:this.ksfsid,
unlockTime:this.kstime
}
this.$u.put(`/app/equipment`,data).then(res =>{
if(res.code == 200){
uni.showToast({
title: '修改成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
if(this.txt == '修改'){
let data = {
equipmentId:this.equipmentId,
name:this.name,
type:this.kslxid,
ruleIds:this.ruleIdlist,
unlockMode:this.ksfsid,
unlockTime:this.kstime
}
})
this.$u.put(`/app/equipment`,data).then(res =>{
if(res.code == 200){
uni.showToast({
title: '修改成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
}
})
}else{
let data = {
name:this.name,
type:this.kslxid,
roomId:this.roomId,
ruleIds:this.ruleIdlist,
unlockMode:this.ksfsid,
unlockTime:this.kstime
}
this.$u.post(`/app/equipment`,data).then(res =>{
if(res.code == 200){
uni.showToast({
title: '添加成功',
icon: 'success',
duration:2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration:2000
})
}
})
}
},
//
btnshoufei(){
@ -227,7 +368,6 @@
this.name = res.data.name
this.type = res.data.type
this.kslxid = res.data.type
this.sn = res.data.device.sn
this.kstime = res.data.unlockTime
this.ksfsid = res.data.unlockMode
if(res.data.unlockMode == 1){
@ -245,6 +385,7 @@
}else if(res.data.type == 4){
this.kslx = '房间灯'
}
// this.sn = res.data.device.sn
}
})
},
@ -258,6 +399,80 @@
padding-bottom: 20rpx;
box-sizing: border-box;
}
.addmen {
width: 694rpx;
height: 702rpx;
background: linear-gradient(180deg, #DEF1DA 0%, #FFFFFF 100%, #FFFFFF 100%);
border-radius: 36rpx 36rpx 36rpx 36rpx;
position: fixed;
top: 464rpx;
left: 50%;
transform: translateX(-50%);
z-index: 3;
box-shadow: 1px 2px 4px -3px;
.one {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
.rt {
image {
width: 60rpx;
height: 60rpx;
}
}
.saoma {
font-weight: 600;
font-size: 36rpx;
color: #48893B;
margin-top: 10rpx;
}
.saomas {
font-size: 28rpx;
color: #48893B;
margin-top: 10rpx;
}
width: 584rpx;
height: 224rpx;
border: 2rpx solid #48893B;
border-radius: 20rpx;
margin: auto;
margin-top: 48rpx;
padding: 38rpx 44rpx;
box-sizing: border-box;
}
.top {
display: flex;
flex-wrap: wrap;
padding: 0 26rpx;
box-sizing: border-box;
.name {
font-weight: 600;
font-size: 44rpx;
color: #48893B;
width: 100%;
text-align: center;
position: absolute;
top: 56rpx;
left: 50%;
transform: translateX(-50%);
}
.cha {
font-size: 68rpx;
font-weight: 600;
width: 100%;
text-align: right;
}
}
}
.wz{
font-size: 24rpx;
color: #3D3D3D;

View File

@ -50,9 +50,9 @@
</view>
</view>
<view class="bot">
<view class="" @click="btnjfgz">
<!-- <view class="" @click="btnjfgz">
<image src="https://api.ccttiot.com/smartmeter/img/static/udeYbjiOdwddMbUM90QB" mode=""></image> 计费规则
</view>
</view> -->
<view class="" @click="btnewm">
<image src="https://api.ccttiot.com/smartmeter/img/static/uT7NCRBVoRy8KFIF9Gtq" mode=""></image> 下载二维码
</view>
@ -65,7 +65,7 @@
<view class="lt">
房间设施列表
</view>
<view class="rt" @click="flag = !flag">
<view class="rt" @click="btnaddsb">
添加
</view>
<!-- <view class="tianjia" v-if="flag">
@ -219,6 +219,12 @@
this.getfjxq()
},
methods: {
//
btnaddsb(){
uni.navigateTo({
url:'/page_shanghu/roomsheshi?roomId=' + this.roomId
})
},
// 线
btnxia(){
let that = this

View File

@ -36,12 +36,12 @@
{{kstj}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
</view>
</view>
<view class="ulbox" style="border: none;">
<view class="ulbox" style="border: none;" v-if="xxobj.equipmentId" @click="addmenflag = true">
<view class="one">
设备绑定
</view>
<view class="two">
{{xxobj.device.sn == null ? '--' : xxobj.device.sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
{{xxobj.device.sn == null ? '' : xxobj.device.sn}} <image src="https://api.ccttiot.com/smartmeter/img/static/uS5JydUQDmvbMyg4nsdo" mode=""></image>
</view>
</view>
<u-select v-model="showone" :list="listone" @confirm="btnone"></u-select>
@ -58,53 +58,49 @@
</view>
</view>
<!-- <view class="box">
<view class="ulbox">
<view class="one">
设备型号
<view class="mask" style="z-index: 3;" v-if="addmenflag"></view>
<view class="addmen" v-if="addmenflag">
<view class="top">
<view class="cha" @click="addmenflag = false">
×
</view>
<view class="two">
{{xxobj.model == null ? '--' : xxobj.model}}
<view class="name">
请选择投放设备方式
</view>
</view>
<view class="ulbox">
<view class="one">
设备编号
</view>
<view class="two">
{{xxobj.sn == null ? '--' : xxobj.sn}}
</view>
</view>
<view class="ulbox">
<view class="one">
设备状态
</view>
<view class="two">
<view class="two" v-if="xxobj.placementStatus == 1">
已投放
<view class="one" @click="btnsaoma">
<view class="lt">
<view class="saoma">
扫码投放
</view>
<view class="two" v-if="xxobj.placementStatus == 2">
未投放
<view class="saomas">
扫描设备上的二维码
</view>
<view class="saomas">
设置大门
</view>
</view>
</view>
<view class="ulbox">
<view class="one">
版本号
</view>
<view class="two">
{{xxobj.version == null ? '--' : xxobj.version}}
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
<view class="ulbox" style="border-bottom: none;">
<view class="one">
联网状态
<view class="one" @click="btntouf">
<view class="lt">
<view class="saoma">
未投放设备列表投放
</view>
<view class="saomas">
选择未投放列表中的设备
</view>
<view class="saomas">
设置大门
</view>
</view>
<view class="two">
{{xxobj.onlineStatus == 1 ? '在线' : '离线'}}
<view class="rt">
<image src="https://api.ccttiot.com/smartmeter/img/static/ukzEfdUUjPKUUOxonIgm" mode=""></image>
</view>
</view>
</view> -->
</view>
</view>
@ -154,15 +150,48 @@
kstj:'',
ksfsid:'',
kstjid:'',
deviceId:''
addmenflag:false
}
},
onLoad(option) {
this.storeId = option.storeId
this.deviceId = option.deviceId
},
onShow() {
this.getmendian()
},
methods: {
//
btnjieb(){
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要解绑该设备吗?',
success: function (res) {
if (res.confirm) {
that.$u.post(`app/device/offline/${that.xxobj.deviceId}`).then(res => {
if (res.code == 200) {
uni.showToast({
title: '解绑成功',
icon: 'success',
duration: 2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
}else{
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
} else if (res.cancel) {
}
}
})
},
//
getmendian(){
this.$u.get(`/app/equipment/gateGate?storeId=${this.storeId}`).then(res =>{
@ -186,6 +215,54 @@
}
})
},
//
btntouf() {
this.addmenflag = false
uni.navigateTo({
url: '/page_shanghu/weishebei?equipmentId=' + this.xxobj.equipmentId
})
},
//
btnsaoma() {
uni.scanCode({
onlyFromCamera: true,
scanType: ['qrCode'],
success: res => {
function getQueryParam(url, paramName) {
let regex = new RegExp(`[?&]${paramName}=([^&]*)`)
let results = regex.exec(url);
return results ? decodeURIComponent(results[1].replace(/\+/g, ' ')) : null
}
console.log(res);
let sceneValue = res.result
let decodedValue = decodeURIComponent(sceneValue)
let id = getQueryParam(decodedValue, 'sn')
let that = this
let data = {
deviceId: id,
equipmentId: this.xxobj.equipmentId
}
that.$u.put(`/app/store/bandGate`, data).then(res => {
if (res.code == 200) {
uni.showToast({
title: '绑定成功',
icon: 'success',
duration: 2000
})
that.xuanzeflag = false
that.addmenflag = false
that.getxq()
} else {
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
}
})
},
//
btnshop(){
let data = {
@ -234,6 +311,90 @@
padding-bottom: 20rpx;
box-sizing: border-box;
}
.mask {
width: 100%;
height: 100vh;
background-color: #000;
opacity: .3;
position: fixed;
top: 0;
left: 0;
}
.addmen {
width: 694rpx;
height: 702rpx;
background: linear-gradient(180deg, #DEF1DA 0%, #FFFFFF 100%, #FFFFFF 100%);
border-radius: 36rpx 36rpx 36rpx 36rpx;
position: fixed;
top: 464rpx;
left: 50%;
transform: translateX(-50%);
z-index: 3;
box-shadow: 1px 2px 4px -3px;
.one {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
.rt {
image {
width: 60rpx;
height: 60rpx;
}
}
.saoma {
font-weight: 600;
font-size: 36rpx;
color: #48893B;
margin-top: 10rpx;
}
.saomas {
font-size: 28rpx;
color: #48893B;
margin-top: 10rpx;
}
width: 584rpx;
height: 224rpx;
border: 2rpx solid #48893B;
border-radius: 20rpx;
margin: auto;
margin-top: 48rpx;
padding: 38rpx 44rpx;
box-sizing: border-box;
}
.top {
display: flex;
flex-wrap: wrap;
padding: 0 26rpx;
box-sizing: border-box;
.name {
font-weight: 600;
font-size: 44rpx;
color: #48893B;
width: 100%;
text-align: center;
position: absolute;
top: 56rpx;
left: 50%;
transform: translateX(-50%);
}
.cha {
font-size: 68rpx;
font-weight: 600;
width: 100%;
text-align: right;
}
}
}
.jieb{
width: 750rpx;
height: 152rpx;

View File

@ -64,11 +64,12 @@
xiaflag:true,
total:'',
qingqiuflag:true,
storeId:''
storeId:'',
equipmentId:''
}
},
onLoad(option) {
this.storeId = option.storeId
this.equipmentId = option.equipmentId
},
onShow() {
this.status ='',
@ -80,8 +81,41 @@
methods: {
//
btnedit(sn,deviceId){
uni.navigateTo({
url:'/page_shanghu/toufsb?storeId=' + this.storeId + '&sn=' + sn + '&deviceId=' + deviceId
// uni.navigateTo({
// url:'/page_shanghu/toufsb?storeId=' + this.storeId + '&sn=' + sn + '&deviceId=' + deviceId
// })
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要将设备投放此设施吗?',
success: function (res) {
if (res.confirm) {
let data = {
deviceId: deviceId,
equipmentId: that.equipmentId
}
that.$u.put(`/app/equipment`, data).then(res => {
if (res.code == 200) {
uni.showToast({
title: '投放成功',
icon: 'success',
duration: 2000
})
setTimeout(()=>{
uni.navigateBack()
},1000)
} else {
uni.showToast({
title: res.msg,
icon: 'none',
duration: 2000
})
}
})
} else if (res.cancel) {
}
}
})
},
//

View File

@ -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/uL0RNlOsfckT3y6nZY6e" mode="" class="imgbj"></image>
<image src="https://api.ccttiot.com/smartmeter/img/static/ua5pSrMa5JltazPSEOdI" mode="aspectFill" class="imgbj"></image>
<view class="body">
<view class="name">
<text>* </text> 您的姓名 <input type="text" v-model="name" placeholder="请输入您的真实姓名"/>

View File

@ -68,6 +68,13 @@
"enablePullDownRefresh": false,
"navigationStyle": "custom"
}
},{
"path": "pages/myorder/taiqiuyuding",
"style": {
"navigationBarTitleText": "",
"enablePullDownRefresh": false,
"navigationStyle": "custom"
}
},{
"path": "pages/myorder/returned/index",
"style": {

View File

@ -3,7 +3,7 @@
<u-navbar title="门店详情" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
:custom-back="btns" title-size='36' height='36' id="navbar">
</u-navbar>
<image src="https://api.ccttiot.com/smartmeter/img/static/uqYdRLVlB5b61Qdnbirn" mode="" class="imgbj"></image>
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
<view class="lunbo">
<u-swiper :list="list" mode="number" border-radius="20" height="366" indicator-pos="bottomRight"></u-swiper>
<view class="shuom">
@ -27,7 +27,65 @@
距我{{shopobj.distance == undefined ? '--' : shopobj.distance}}km <text></text>
{{shopobj.address == undefined ? '--' : shopobj.address}}
</view>
<view class="shoplist" @touchstart="onTouchStart" @touchend="onTouchEnd" @touchcancel="onTouchCancel">
<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>
</view>
<view class="typewz" v-if="tabindex == 0">
<text class="one">茶室</text> <text class="two">干净舒适品好茶</text>
</view>
<view class="typewz" v-if="tabindex == 1">
<text class="one">棋牌</text> <text class="two">轻松消费无压力</text>
</view>
<view class="typewz" v-if="tabindex == 2">
<text class="one">台球</text> <text class="two">好台打好球赛事级桌台</text>
</view>
<!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 --><!-- 台球 -->
<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">
<image src="https://api.ccttiot.com/smartmeter/img/static/uqv5RPXXtMydaBdU7sqG" mode=""></image>
<view class="name">
一号桌
</view>
<view class="kaitai">
开台
</view>
</view>
</view>
</view>
<view class="tqname">
杆柜
</view>
<view class="gangui">
<image src="https://api.ccttiot.com/smartmeter/img/static/uQPXhfkhmvvvPXbW65WF" mode=""></image>
<!-- <view class="cun">
</view>
<view class="cun">
</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="top">
<view class="lt">
@ -106,6 +164,7 @@
没有更多房间啦敬请期待吧...
</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>
@ -173,7 +232,8 @@
arr:[],
jinxinglist:[],
jinxinflag:false,
jinxintxt:'开包厢'
jinxintxt:'开包厢',
tabindex:0
}
},
onLoad(option) {
@ -194,6 +254,19 @@
},
methods: {
//
btntq(){
uni.navigateTo({
url:'/pages/myorder/taiqiuyuding'
})
},
// tab
btngundong(section, index) {
this.tabindex = index
},
// 24
initializeData() {
//
@ -463,6 +536,142 @@
background-color: #226914 !important;
color: #fff !important;
}
.taiqiubox{
max-height: 710rpx;
overflow: scroll;
padding-bottom: 240rpx;
box-sizing: border-box;
.zhuozi{
width: 99%;
max-height: 5632rpx;
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{
display: flex;
flex-wrap: wrap;
justify-content: space-between;
.tqlist_item{
width: 308rpx;
height: 180rpx;
position: relative;
margin-top: 16rpx;
.name{
font-size: 36rpx;
color: #FFFFFF;
width: 100%;
text-align: center;
padding-top: 34rpx;
box-sizing: border-box;
}
.kaitai{
width: 90rpx;
height: 42rpx;
background: #C5DFC0;
border-radius: 4rpx 4rpx 4rpx 4rpx;
text-align: center;
line-height: 42rpx;
font-size: 28rpx;
color: #48893B;
margin: auto;
margin-top: 14rpx;
}
image{
position: absolute;
width: 308rpx;
height: 180rpx;
z-index: -1;
}
}
}
}
.gangui{
width: 674rpx;
height: 298rpx;
position: relative;
margin-top: 16rpx;
image{
position: absolute;
width: 674rpx;
height: 298rpx;
}
.cun{
width: 92rpx;
height: 92rpx;
background: #48893B;
border: 2rpx solid #191114;
border-radius: 50%;
text-align: center;
line-height: 92rpx;
font-size: 40rpx;
color: #FFFFFF;
}
}
.tqname{
font-weight: 600;
font-size: 32rpx;
color: #3D3D3D;
margin-top: 44rpx;
}
}
.typewz{
display: flex;
align-items: center;
margin-top: 16rpx;
margin-bottom: 10rpx;
.one{
font-weight: 600;
font-size: 32rpx;
color: #3D3D3D;
margin-right: 20rpx;
}
.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{
width: 188rpx;
text-align: center;
.kg{
font-weight: 600;
font-size: 24rpx;
color: #3D3D3D;
text{
color: #48893B;
margin-left: 4rpx;
}
}
.gn{
font-weight: 600;
font-size: 32rpx;
color: #3D3D3D;
margin-top: 10rpx;
}
image{
width: 58rpx;
height: 14rpx;
}
}
.xian{
width: 1px;
height: 62rpx;
background-color: #3D3D3D;
}
}
.karaokeroom{
position: fixed;
top: 332rpx;
@ -544,6 +753,8 @@
page {
background: #fff;
border-radius: 0rpx 0rpx 0rpx 0rpx;
height: 100vh;
overflow: hidden;
}
/deep/ .u-indicator-item-number {
@ -555,7 +766,7 @@
.xuanfu {
position: fixed;
top: 52%;
top: 62%;
right: 30rpx;
animation: fadeInDowns .5s ease-out forwards;
@ -593,7 +804,7 @@
.xuanfus {
position: fixed;
top: 52%;
top: 62%;
right: -80rpx;
animation: fadeInDown .5s ease-out forwards;

View File

@ -404,11 +404,9 @@
})
// console.log(room.reservationStatus,'02.0230.');
// room.forEach(period => {
let startHour = room.startTime.slice(room.startTime.length - 8, room.startTime.length -
6) //
let startHour = room.startTime.slice(room.startTime.length - 8, room.startTime.length - 6) //
let endHour = room.endTime.slice(room.endTime.length - 8, room.endTime.length - 6) //
let timefen = room.startTime.slice(room.endTime.length - 5, room.endTime.length -
3) //
let timefen = room.startTime.slice(room.endTime.length - 5, room.endTime.length - 3) //
//
const now = new Date();
const year = now.getFullYear();
@ -777,7 +775,7 @@
this.$u.get(`/app/room/${this.roomId}`).then(res => {
if (res.code == 200) {
this.shopobj = res.data
if(res.data.reservedTimePeriods == ''){
if(res.data.reservedTimePeriods == null){
this.roomList = []
for(let i = 0;i < 24;i++){
this.roomList.push(false)
@ -993,7 +991,8 @@
margin-top: 18rpx;
padding-bottom: 220rpx;
box-sizing: border-box;
height: 100vh;
overflow: hidden;
.yudingtrue {
width: 600rpx;
height: 806rpx;

View File

@ -0,0 +1,480 @@
<template>
<view class="page">
<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/u7MDpwrQJKm7kflVVnRb" mode="" class="imgbj"></image>
<view class="topxx">
<view class="lt">
<image src="https://api.ccttiot.com/smartmeter/img/static/uWPPuS75kFuDg83Rvyeq" mode=""></image>
</view>
<view class="rt">
<view class="">
预定门店福鼎-西湖店
</view>
<view class="">
预定桌台1号桌
</view>
<view class="">
收费价格10/小时押金100
</view>
</view>
</view>
<!-- <view class="moshis" @click="show = true">
<view class="top">
<view class="lt">
开台模式
</view>
<view class="rt">
{{ktmode}} <image src="https://api.ccttiot.com/smartmeter/img/static/unGhc5oBVgoqaNk3GqPO" mode=""></image>
</view>
</view>
<view class="zixuan" v-if="ktmode == '自选时长'">
<view class="list" v-for="(item,index) in 5" :key="index" :id="tabindex == index ? 'active' : ''" @click.stop="btnitem(index)">
1小时
</view>
</view>
</view>
<view class="moshi">
<view class="lt">
是否锁台 <image @click.stop="tishiflag = true" src="https://api.ccttiot.com/smartmeter/img/static/ukLX4u9alPoxvArisxV8" mode=""></image>
</view>
<view class="rt" style="color: #48893B;">
锁台金10元 <image style="width: 30rpx;height: 30rpx;" src="https://api.ccttiot.com/smartmeter/img/static/uqmSUM2Akgx7LQBXlNos" mode=""></image>
</view>
</view> -->
<view class="money">
<image src="https://api.ccttiot.com/smartmeter/img/static/uP8ymRHTDQ6YdwwnxQAb" mode="" class="moneyimg">
</image>
<view class="moneytop">
<view class="zongjia">
<view class="">订单总价</view>
<view class="pricered">162</view>
</view>
<view class="yuding">
<view class="">押金</view>
<view class="">100</view>
</view>
<view class="yudingtime">
<view class="">时长单价</view>
<view class="time">10/小时</view>
</view>
</view>
<view class="moneybot">
<view class="xudan">
<view class="">锁台金</view>
<view class="">10押金代扣</view>
</view>
<view class="koukuan" >
<view class="">扣款策略</view>
<view class="">微信支付
<image src="https://api.ccttiot.com/smartmeter/img/static/uYHtrgPzlait1i05RQYy" mode=""></image>
</view>
</view>
</view>
</view>
<!-- <view class="wxtishi">
<view class="name">
温馨提示
</view>
<view class="wz">
锁台将持续10分钟若10分钟后 到店将扣除锁台金并取消订单
</view>
<view class="anniu">
我知道了
</view>
</view> -->
<u-select v-model="show" :list="list" @confirm="confirm"></u-select>
<view class="kaitai">
<view class="lt">
总计<text>166.00</text>
</view>
<view class="rt">
立即开台
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
bgc: {
backgroundColor: "",
},
show: false,
list: [
{
value: '1',
label: '押金开台'
},
{
value: '2',
label: '自选时长'
}
],
ktmode:'押金开台',
tabindex:-1,
tishiflag:false
}
},
onLoad() {
},
onShow() {
},
mounted() {
},
methods: {
//
confirm(e){
this.ktmode = e[0].label
},
//
btnitem(index){
this.tabindex = index
}
}
}
</script>
<style lang="scss">
#active{
background: #DEF1DA !important;
color: #48893B !important;
border: 2rpx solid #48893B !important;
}
.wxtishi{
width: 542rpx;
height: 372rpx;
background: #FFFFFF;
border-radius: 20rpx 20rpx 20rpx 20rpx;
.name{
font-weight: 600;
font-size: 40rpx;
color: #3D3D3D;
width: 100%;
text-align: center;
}
.wz{
font-size: 28rpx;
color: #3D3D3D;
}
.anniu{
width: 316rpx;
height: 72rpx;
background: #48893B;
border-radius: 36rpx 36rpx 36rpx 36rpx;
text-align: center;
line-height: 72rpx;
font-size: 32rpx;
color: #FFFFFF;
}
}
.kaitai{
width: 668rpx;
height: 116rpx;
background: #FFFFFF;
box-shadow: 0rpx 8rpx 20rpx 0rpx rgba(0,0,0,0.3);
border-radius: 83rpx 83rpx 83rpx 83rpx;
position: fixed;
bottom: 50rpx;
left: 50%;
transform: translateX(-50%);
display: flex;
justify-content: space-between;
align-items: center;
padding: 20rpx;
box-sizing: border-box;
.rt{
width: 258rpx;
height: 76rpx;
background: #48893B;
border-radius: 49rpx 49rpx 49rpx 49rpx;
font-size: 40rpx;
color: #FFFFFF;
text-align: center;
line-height: 76rpx;
}
.lt{
font-weight: 600;
font-size: 32rpx;
color: #3D3D3D;
text{
color: #FF1818;
}
}
}
.money {
width: 710rpx;
margin: auto;
position: relative;
margin-top: 30rpx;
.moneybot {
padding: 30rpx 38rpx;
box-sizing: border-box;
.xudan {
display: flex;
justify-content: space-between;
view {
font-size: 28rpx;
color: #3D3D3D;
}
}
.yu_e {
display: flex;
justify-content: space-between;
margin-top: 20rpx;
view {
font-size: 28rpx;
color: #3D3D3D;
display: flex;
align-items: center;
}
.yu_eno {
color: #FF1818;
display: flex;
align-items: center;
image {
width: 14rpx;
height: 36rpx;
display: flex;
align-items: center;
margin-left: 12rpx;
}
}
}
.koukuan {
display: flex;
justify-content: space-between;
margin-top: 20rpx;
view {
font-size: 28rpx;
color: #3D3D3D;
display: flex;
align-items: center;
image {
width: 14rpx;
height: 36rpx;
display: flex;
align-items: center;
margin-left: 12rpx;
}
}
}
}
.moneytop {
padding: 46rpx 38rpx;
box-sizing: border-box;
.yudingtime {
font-size: 28rpx;
color: #3D3D3D;
display: flex;
justify-content: space-between;
margin-top: 20rpx;
.time {
color: #48893B;
}
}
.yuding {
margin-top: 34rpx;
display: flex;
justify-content: space-between;
font-size: 28rpx;
color: #3D3D3D;
}
.zongjia {
display: flex;
justify-content: space-between;
border-bottom: 1px solid #D8D8D8;
padding-bottom: 20rpx;
box-sizing: border-box;
view {
font-weight: 600;
font-size: 36rpx;
color: #3D3D3D;
}
.pricered {
font-size: 36rpx;
color: #FF1818;
font-weight: 600;
}
}
}
.moneyimg {
width: 710rpx;
height: 529rpx;
position: absolute;
top: 0;
left: 0;
z-index: -1;
}
}
.moshis{
width: 674rpx;
max-height: 996rpx;
background: #FFFFFF;
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.15);
border-radius: 18rpx 18rpx 18rpx 18rpx;
margin: auto;
padding: 0 30rpx;
box-sizing: border-box;
margin-top: 24rpx;
.zixuan{
padding-bottom: 32rpx;
box-sizing: border-box;
border-top: 1px solid #7C7C7C;
display: flex;
flex-wrap: wrap;
.list:nth-child(3n) {
margin-right: 0;
}
.list{
width: 198rpx;
height: 104rpx;
border-radius: 10rpx 10rpx 10rpx 10rpx;
border: 2rpx solid #7C7C7C;
margin-top: 34rpx;
text-align: center;
line-height: 104rpx;
font-size: 36rpx;
color: #3D3D3D;
margin-right: 10rpx;
}
}
.top{
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
height: 100rpx;
}
.rt{
font-size: 28rpx;
color: #3D3D3D;
display: flex;
align-items: center;
image{
width: 14rpx;
height: 36rpx;
margin-left: 10rpx;
}
}
.lt{
font-size: 28rpx;
color: #3D3D3D;
display: flex;
align-items: center;
image{
width: 30rpx;
height: 30rpx;
margin-left: 10rpx;
}
}
}
.moshi{
width: 674rpx;
height: 96rpx;
background: #FFFFFF;
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.15);
border-radius: 18rpx 18rpx 18rpx 18rpx;
margin: auto;
display: flex;
justify-content: space-between;
padding: 0 30rpx;
box-sizing: border-box;
margin-top: 24rpx;
.rt{
font-size: 28rpx;
color: #3D3D3D;
display: flex;
align-items: center;
image{
width: 14rpx;
height: 36rpx;
margin-left: 10rpx;
}
}
.lt{
font-size: 28rpx;
color: #3D3D3D;
display: flex;
align-items: center;
image{
width: 30rpx;
height: 30rpx;
margin-left: 10rpx;
}
}
}
.topxx{
width: 674rpx;
height: 228rpx;
background: #FFFFFF;
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.15);
border-radius: 18rpx 18rpx 18rpx 18rpx;
display: flex;
margin: auto;
margin-top: 38rpx;
padding: 34rpx 30rpx;
box-sizing: border-box;
.rt{
view{
font-size: 28rpx;
color: #3D3D3D;
margin-bottom: 22rpx;
}
}
.lt{
margin-right: 34rpx;
image{
width: 158rpx;
height: 158rpx;
border-radius: 10rpx;
}
}
}
page {
background: #fff;
margin-top: 18rpx;
padding-bottom: 220rpx;
box-sizing: border-box;
height: 100vh;
overflow: hidden;
}
.imgbj {
width: 750rpx;
height: 424rpx;
position: fixed;
top: 0;
left: 0;
z-index: -1;
}
</style>

View File

@ -2,7 +2,7 @@
<view class="page">
<u-navbar :is-back="false" :border-bottom="false" :background="bgc" title-color='#2E4975' title-size='36'
height='8'></u-navbar>
<image src="https://api.ccttiot.com/smartmeter/img/static/uS8TEdeETwvOdHDswc9c" mode="" class="imgbj"></image>
<image src="https://api.ccttiot.com/smartmeter/img/static/u3lZnmhqSqkMd7gHKtMD" mode="" class="imgbj"></image>
<view class="title" @click="btnshanghu">
商户中心
</view>
@ -17,13 +17,27 @@
<u-icon name="search"></u-icon>
</view>
</view>
<view class="tabqh">
<view @click="btntabindex(1)" :class="tabindex == 1 ? 'activetab' : ''">
茶室
<image v-if="tabindex == 1" src="https://api.ccttiot.com/smartmeter/img/static/uHFOqckZJiCEP9JOtMvj" mode=""></image>
</view>
<view @click="btntabindex(2)" :class="tabindex == 2 ? 'activetab' : ''">
棋牌
<image v-if="tabindex == 2" src="https://api.ccttiot.com/smartmeter/img/static/uQ6c41aBHWUOD02aK9WQ" mode=""></image>
</view>
<view @click="btntabindex(3)" style="width: 34%;" :class="tabindex == 3 ? 'activetab' : ''">
台球
<image v-if="tabindex == 3" style="transform: rotateY(180deg)" src="https://api.ccttiot.com/smartmeter/img/static/uHFOqckZJiCEP9JOtMvj" mode=""></image>
</view>
</view>
<view class="shoplist"
@touchstart="onTouchStart"
@touchend="onTouchEnd"
@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=""></image>
<image :src="item.picture" mode="aspectFill"></image>
<view class="hour">
{{item.minimumTime == undefined ? '--' : item.minimumTime}}小时起订
</view>
@ -35,6 +49,11 @@
<view class="dizhi">
{{item.address == undefined ? '--' : item.address}}
</view>
<view class="storebq">
<image v-if="item.type == 1" src="https://api.ccttiot.com/smartmeter/img/static/u7ilmXTNlXUbbvfSgOa1" mode=""></image>
<image v-if="item.type == 2" src="https://api.ccttiot.com/smartmeter/img/static/umA2EUZkovZEA0hCLmP3" mode=""></image>
<image v-if="item.type == 3" src="https://api.ccttiot.com/smartmeter/img/static/uPjeCCnwjiJlCNqURltX" mode=""></image>
</view>
<view class="juli">
<view class="kmjuli">
距我{{item.distance == undefined ? '--' : item.distance}}km
@ -56,7 +75,7 @@
</view>
</view>
<view class="jiameng" @click="btnjiameng">
<image src="https://api.ccttiot.com/smartmeter/img/static/usIK790XacHJ1pXUbbfW" mode=""></image>
<image src="https://api.ccttiot.com/smartmeter/img/static/uuoqWaq7HnXBteQayaz4" mode=""></image>
</view>
<view class="xuanfu" v-if="imgflag">
<image @click="btnopen(1)" src="https://api.ccttiot.com/smartmeter/img/static/uKeCHdot1z4QJldDe3UL" mode=""></image>
@ -125,7 +144,8 @@
jinxinglist:[],
mdindex:-1,
jinxinflag:false,
sousuovalue:''
sousuovalue:'',
tabindex:1
}
},
onLoad(option) {
@ -142,6 +162,10 @@
this.getorder()
},
methods: {
//
btntabindex(num){
this.tabindex = num
},
//
btnshanghu(){
uni.navigateTo({
@ -475,6 +499,38 @@
background-color: #226914 !important;
color: #fff !important;
}
.activetab{
font-weight: 600 !important;
font-size: 40rpx !important;
color: #3D3D3D !important;
}
.tabqh{
display: flex;
width: 100%;
height: 84rpx;
background-color: #DEF1DA;
position: fixed;
top: 306rpx;
border-radius: 30rpx 30rpx 0 0;
view{
font-weight: 600;
font-size: 32rpx;
color: #7C7C7C;
text-align: center;
width: 33%;
height: 84rpx;
line-height: 84rpx;
position: relative;
image{
// width: 291rpx;
height: 84rpx;
position: absolute;
top: 0;
left: 0;
z-index: -1;
}
}
}
.jinxinx{
width: 60rpx;
height: 60rpx;
@ -615,10 +671,10 @@
width: 750rpx;
height: 1250rpx;
background: #FFFFFF;
margin-top: 28rpx;
margin-top: 48rpx;
border-radius: 30rpx 30rpx 0 0;
padding: 48rpx;
padding-top: 0 !important;
padding-top: 84rpx;
box-sizing: border-box;
overflow: scroll;
padding-bottom: 240rpx !important;
@ -634,6 +690,15 @@
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.15);
border-radius: 18rpx 18rpx 18rpx 18rpx;
.rt{
.storebq{
margin-top: 16rpx;
display: flex;
image{
width: 108rpx;
height: 40rpx;
margin-right: 10rpx;
}
}
.yuding{
display: flex;
align-items: center;
@ -655,7 +720,7 @@
.juli{
display: flex;
justify-content: space-between;
margin-top: 56rpx;
margin-top: 16rpx;
align-items: center;
.kmjuli{
width: 210rpx;