This commit is contained in:
3321822538@qq.com 2025-01-03 18:01:49 +08:00
parent 21f759eae3
commit bdb5acf275
5 changed files with 429 additions and 14 deletions

View File

@ -2,11 +2,11 @@
<view class="page">
<u-navbar title="保洁管理" :border-bottom="false" :background="bgc" title-color='#000' back-icon-color="#000" title-size='36' height='50'></u-navbar>
<view class="box">
<view class="serch">
<!-- <view class="serch">
<view class="lt">
<image src="https://api.ccttiot.com/smartmeter/img/static/uaG7R4JLfYOzBhWfDN0j" mode=""></image><input type="text" v-model="keyword" placeholder="搜索"/> <view class="sousuo" @click="btnsousuo">搜索</view>
</view>
</view>
</view> -->
<view class="list" v-for="(item,index) in 2" :key="index" @click="btnxq(index)">
<view class="top">
<view class="lt" style="display: flex;align-items: center;">

268
page_moban/baojieorder.vue Normal file
View File

@ -0,0 +1,268 @@
<template>
<view class="page">
<u-navbar title="保洁订单" :border-bottom="false" :background="bgc" back-icon-color="#262B37" title-color='#262B37'
title-size='36' height='50' id="navbar">
</u-navbar>
<view class="serch">
<view class="lt">
<image src="https://api.ccttiot.com/smartmeter/img/static/uaG7R4JLfYOzBhWfDN0j" mode=""></image><input type="text" v-model="keyword" placeholder="搜索"/> <view class="sousuo" @click="btnsousuo">搜索</view>
</view>
<view class="tab">
<view @click="btntab(1)" :class="tabindex == 1 ? 'active' : ''">
待保洁
</view>
<view @click="btntab(2)" :class="tabindex == 2 ? 'active' : ''">
已保洁
</view>
</view>
</view>
<scroll-view class="list"
scroll-y="true"
:scroll-with-animation="true"
@scrolltolower="handleScrollToLower">
<view class="item_list" v-for="(item,index) in orderlist" :key="index">
<view class="top">
<view class="lt">
<image src="https://api.ccttiot.com/smartmeter/img/static/upHnI7g3Y6IAzV0LdRyP" mode=""></image> 2025-01-01 16:00
</view>
<view class="rt">
已保洁
</view>
</view>
<view class="name">
<view class="lt">
门店名称
</view>
<view class="lt">
茶馆
</view>
</view>
<view class="bd">
<view class="">
包厢名称竹韵
</view>
<view class="">
开始时间2025-01-01 16:00
</view>
<view class="">
预计结束时间2025-01-01 16:30
</view>
<view class="">
完成时间--
</view>
</view>
<view class="bot">
<view class=""></view>
<view class="wc">完成保洁</view>
</view>
</view>
<view style="width: 100%;text-align: center;font-size: 32rpx;color: #ccc;font-weight: 600;margin-top: 30rpx;">
没有更多保洁订单啦...
</view>
</scroll-view>
</view>
</template>
<script>
export default {
data() {
return {
bgc: {
backgroundColor: "#fff",
},
tabindex:1,
orderlist:[],
pagenum:1,
pagesize:10,
total:0,
}
},
onLoad() {
this.getlist()
},
methods: {
//
btntab(num){
this.tabindex = num
},
//
getlist(){
this.$u.get(`/app/clean/list?pageNum=${this.pagenum}&pageSize=${this.pagesize}`).then(res =>{
if(res.code == 200){
this.total = res.total
if(this.pagenum > 1){
this.pagenum++
this.orderlist = this.orderlist.concat(res.rows)
}else{
this.pagenum++
this.orderlist = res.rows
}
}
})
},
//
handleScrollToLower() {
if(this.total == this.orderlist.length){
uni.showToast({
title: '没有更多订单了',
icon: 'none',
duration:2000
})
}else{
this.getlist()
}
},
}
}
</script>
<style lang="scss">
/deep/ .u-iconfont,
/deep/ .u-title{
padding-bottom: 20rpx;
}
.list{
width: 100%;
height: 74vh;
overflow: scroll;
.item_list{
margin: auto;
margin-top: 20rpx;
padding: 20rpx 18rpx;
box-sizing: border-box;
width: 674rpx;
max-height: 650rpx;
background: #FFFFFF;
box-shadow: 0rpx 2rpx 12rpx 0rpx rgba(0,0,0,0.15);
border-radius: 18rpx 18rpx 18rpx 18rpx;
.bot{
border-top: 1px solid #D8D8D8;
margin-top: 30rpx;
padding-top: 20rpx;
box-sizing: border-box;
display: flex;
justify-content: space-between;
.wc{
width: 194rpx;
height: 64rpx;
background: #48893B;
border-radius: 14rpx 14rpx 14rpx 14rpx;
font-weight: 600;
font-size: 32rpx;
color: #FFFFFF;
text-align: center;
line-height: 64rpx;
}
}
.bd{
margin-top: 30rpx;
view{
font-size: 28rpx;
color: #3D3D3D;
margin-top: 16rpx;
}
}
.name{
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 22rpx;
padding-bottom: 24rpx;
box-sizing: border-box;
border-bottom: 1px solid #D8D8D8;
.lt{
font-weight: 600;
font-size: 28rpx;
color: #3D3D3D;
}
.rt{
font-size: 24rpx;
color: #7C7C7C;
}
}
.top{
width: 634rpx;
height: 90rpx;
background: #DEF1DA;
display: flex;
justify-content: space-between;
padding: 22rpx;
box-sizing: border-box;
border-radius: 20rpx;
.lt{
display: flex;
align-items: center;
image{
width: 46rpx;
height: 46rpx;
margin-right: 14rpx;
}
}
}
}
}
page {
background: #F6F6F6;
padding-bottom: 30rpx;
box-sizing: border-box;
}
.active{
color: #48893B !important;
border-bottom: 6rpx solid #48893B !important;
}
.serch{
padding: 0 36rpx;
box-sizing: border-box;
padding-top: 20rpx;
padding-bottom: 22rpx;
background-color: #fff;
.tab{
display: flex;
width: 100%;
justify-content: space-between;
padding: 0 138rpx;
box-sizing: border-box;
margin-top: 32rpx;
view{
font-size: 32rpx;
color: #3D3D3D;
padding-bottom: 6rpx;
box-sizing: border-box;
border-bottom: 6rpx solid #fff;
}
}
.lt{
display: flex;
align-items: center;
width: 100%;
height: 68rpx;
border: 2rpx solid #48893B;
border-radius: 24rpx;
padding-left: 30rpx;
box-sizing: border-box;
.sousuo{
width: 140rpx;
height: 66rpx;
text-align: center;
line-height: 66rpx;
font-size: 32rpx;
color: #FFFFFF;
background: #48893B;
border: 2rpx solid #48893B;
border-radius: 0 20rpx 20rpx 0;
}
image{
width: 46rpx;
height: 46rpx;
}
input{
width: 460rpx;
margin-left: 30rpx;
height: 68rpx;
line-height: 68rpx;
}
}
}
</style>

View File

@ -100,14 +100,14 @@
实际消费时长
</view>
<view class="two">
1小时
{{timesc}}
</view>
</view><view class="bd">
<view class="one">
退款备注
押金退款备注
</view>
<view class="two">
--
{{orderobj.depositRefundDesc == null ? '--' : orderobj.depositRefundDesc}}
</view>
</view><view class="bd">
<view class="one">
@ -137,9 +137,49 @@
</view>
</view>
</view>
<!-- 退款列表 -->
<view class="orderxx" v-for="(item,index) in orderobj.refunds" :key="index">
<view class="name">
退款{{index + 1}}
</view>
<view class="bd">
<view class="one">
退款订单编号
</view>
<view class="two">
{{item.orderNo == null ? '--' : item.orderNo}}
</view>
</view>
<view class="bd">
<view class="one">
退款金额
</view>
<view class="two">
{{item.amount == null ? '--' : item.amount}}
</view>
</view>
<view class="bd">
<view class="one">
退款备注
</view>
<view class="two">
{{item.reason == null ? '--' : item.reason}}
</view>
</view>
<view class="bd">
<view class="one">
退款时间
</view>
<view class="two">
{{item.operTime == null ? '--' : item.operTime}}
</view>
</view>
</view>
<view class="anniu">
<view class=""></view>
<view class="but" @click="btntk">退款</view>
<view class="but" v-if="orderobj.status == 4" @click="btntk">退款</view>
<view class="but" v-if="orderobj.status == 3" @click="btnjies">结束订单</view>
<view class="but" v-if="orderobj.status == 2 || orderobj.status == 0 || orderobj.status == 1" @click="btnqx">取消订单</view>
</view>
<view class="mask" v-if="maskflag"></view>
@ -177,7 +217,8 @@
},
maskflag:false,
orderNo:'',
orderobj:{}
orderobj:{},
timesc:''
}
},
onLoad(option) {
@ -190,13 +231,101 @@
this.$u.get(`/appVerify/orderInfo?orderNo=${this.orderNo}`).then(res =>{
if(res.code == 200){
this.orderobj = res.data
let dateOne = new Date(res.data.reserveEndTime)
let dateTwo = new Date(res.data.reserveStartTime)
let timeDifference = dateOne - dateTwo
let millisecondsInSecond = 1000
let millisecondsInMinute = millisecondsInSecond * 60
let millisecondsInHour = millisecondsInMinute * 60
let millisecondsInDay = millisecondsInHour * 24
let days = Math.floor(timeDifference / millisecondsInDay)
timeDifference %= millisecondsInDay
let hours = Math.floor(timeDifference / millisecondsInHour)
timeDifference %= millisecondsInHour
let minutes = Math.floor(timeDifference / millisecondsInMinute)
timeDifference %= millisecondsInMinute
this.timesc = `${days == 0 ? '' : days + }${hours}${minutes}`
}
})
},
// 退
btntk(){
this.maskflag = true
}
},
//
btnqx(){
let orderNos = this.orderobj.orderNo
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要取消该订单吗?',
success: function (res) {
if (res.confirm) {
let data = {
orderNo:orderNos,
type:1
}
that.$u.post(`/app/order/orderCancel?orderNo=${orderNos}`,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: 'success',
duration:2000
})
}
})
} else if (res.cancel) {
}
}
})
},
//
btnjies(){
let orderNos = this.orderobj.orderNo
let that = this
uni.showModal({
title: '温馨提示',
content: '您确定要结束该订单吗?',
success: function (res) {
if (res.confirm) {
let data = {
orderNo:orderNos,
type:2
}
that.$u.post(`/app/order/orderEnd?orderNo=${orderNos}`,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: 'success',
duration:2000
})
}
})
} else if (res.cancel) {
}
}
})
},
}
}
</script>
@ -291,13 +420,18 @@
}
.orderxx{
width: 680rpx;
height: 682rpx;
max-height: 682rpx;
background: #FFFFFF;
border-radius: 20rpx 20rpx 20rpx 20rpx;
margin: auto;
margin-top: 22rpx;
padding: 30rpx 48rpx;
box-sizing: border-box;
.name{
margin-bottom: 20rpx;
font-size: 32rpx;
font-weight: 600;
}
.bd{
display: flex;
justify-content: space-between;
@ -378,6 +512,8 @@
}
page {
background: #F6F6F6;
padding-bottom: 150rpx;
box-sizing: border-box;
}

View File

@ -88,18 +88,18 @@
<image src="https://api.ccttiot.com/smartmeter/img/static/uYxzaUTodBMnHowtv7bl" mode=""></image>
<view class="wz">杆柜订单</view>
</view>
<view class="listul_item">
<view class="listul_item" @click="btnpage(7)">
<image src="https://api.ccttiot.com/smartmeter/img/static/uPEgwjhXLbUeBWASW6Ws" mode=""></image>
<view class="wz">保洁订单</view>
</view>
<view class="listul_item" @click="btnpage(1)">
<image src="https://api.ccttiot.com/smartmeter/img/static/u9ssRAyWpKMNA89117NB" mode=""></image>
<view class="wz">合伙人管理</view>
</view>
<view class="listul_item" @click="btnpage(2)">
<image src="https://api.ccttiot.com/smartmeter/img/static/ubfpq3LLHb1eXehq8IuD" mode=""></image>
<view class="wz">保洁管理</view>
</view>
<view class="listul_item" @click="btnpage(1)">
<image src="https://api.ccttiot.com/smartmeter/img/static/u9ssRAyWpKMNA89117NB" mode=""></image>
<view class="wz">合伙人管理</view>
</view>
<view class="listul_item" @click="btnpage(5)">
<image src="https://api.ccttiot.com/smartmeter/img/static/uHQtbhwpFAMPjWkn0kw5" mode=""></image>
<view class="wz">基础设置</view>
@ -170,6 +170,10 @@
uni.navigateTo({
url:'/page_moban/jichu'
})
}else if(num == 7){ //
uni.navigateTo({
url:'/page_moban/baojieorder'
})
}
},
//

View File

@ -403,6 +403,13 @@
"enablePullDownRefresh": false,
"navigationStyle": "custom"
}
},{
"path": "baojieorder",
"style": {
"navigationBarTitleText": "上传",
"enablePullDownRefresh": false,
"navigationStyle": "custom"
}
},{
"path": "datingxq",
"style": {