This commit is contained in:
shidongli 2023-11-14 15:53:48 +08:00
parent 4ad55d3b6d
commit 326919e98a
2 changed files with 100 additions and 89 deletions

View File

@ -1,7 +1,7 @@
<template>
<view class="app">
<view class="content" v-if='tabslist.length>0'>
<view class="" v-if="timecurrent==0">
<view class="toptime" v-if="timecurrent==0">
<span>{{tabslist[0].name}}&nbsp;&nbsp;{{tabslist[0].dates}}</span>
</view>
@ -36,8 +36,7 @@
<view class="bodyitem">
<view class="" v-for="(item ,index) in List[timecurrent].morningList">
<view @tap='taptimemorning(item,index)'
:class="item.status==true?'morningbodytwo':'morningbody'">
<view @tap='taptimemorning(item,index)' :class="item.status==true?'morningbodytwo':'morningbody'">
<span class="spanitem">{{item.scheduleTimeSlot}}</span>
<view class="spanitem" v-if="item.status==false">不可预约</view>
<view class="spanitem" v-else>可预约</view>
@ -52,8 +51,7 @@
</view>
<view class="bodyitem">
<view class="" v-for="(item ,index) in List[timecurrent].afternoonList">
<view @tap='taptimeafter(item,index)'
:class="item.status==true?'bodytwo':'body'">
<view @tap='taptimeafter(item,index)' :class="item.status==true?'bodytwo':'body'">
<span class="spanitem">{{item.scheduleTimeSlot}}</span>
<view class="spanitem" v-if="item.status==false">不可预约</view>
<view class="spanitem" v-else>可预约</view>
@ -125,7 +123,7 @@
this.timeindexafter = null
this.timeindex = null
this.afterdata()
} else if (this.Soonerorlater == 'all') {
this.timeindexafter = null
this.timeindex = null
@ -133,19 +131,19 @@
}
},
//
morningdata(){
this.qurey={
schedulePlanDetailIds:[],
status:'1',
morningdata() {
this.qurey = {
schedulePlanDetailIds: [],
status: '1',
}
getListByDoctor(this.doctorId).then(res => {
if (res.data) {
res.data[this.timecurrent].morningList.forEach(e=>{
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
res.data[this.timecurrent].morningList.forEach(e => {
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
})
updateStatus(this.qurey).then(res => {
if (res.code == 500) {
@ -153,7 +151,7 @@
title: res.msg,
type: 'error',
})
} else {
this.$refs.uToast.show({
title: '修改成功',
@ -161,71 +159,71 @@
duration: '1000'
})
this.updata()
}
})
}
})
},
//
afterdata(){
this.qurey={
schedulePlanDetailIds:[],
status:'1',
},
getListByDoctor(this.doctorId).then(res => {
if (res.data) {
console.log(res.data[this.timecurrent].afternoonList)
// var schedulePlanDetailId
res.data[this.timecurrent].afternoonList.forEach(e=>{
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
})
updateStatus(this.qurey).then(res => {
if (res.code == 500) {
this.$refs.uToast.show({
title: res.msg,
type: 'error',
})
} else {
this.$refs.uToast.show({
title: '修改成功',
type: 'success',
duration: '1000'
})
this.updata()
}
})
}
})
afterdata() {
this.qurey = {
schedulePlanDetailIds: [],
status: '1',
},
getListByDoctor(this.doctorId).then(res => {
if (res.data) {
console.log(res.data[this.timecurrent].afternoonList)
// var schedulePlanDetailId
res.data[this.timecurrent].afternoonList.forEach(e => {
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
})
updateStatus(this.qurey).then(res => {
if (res.code == 500) {
this.$refs.uToast.show({
title: res.msg,
type: 'error',
})
} else {
this.$refs.uToast.show({
title: '修改成功',
type: 'success',
duration: '1000'
})
this.updata()
}
})
}
})
},
//
alldata(){
alldata() {
getListByDoctor(this.doctorId).then(res => {
this.qurey={
schedulePlanDetailIds:[],
status:'1',
this.qurey = {
schedulePlanDetailIds: [],
status: '1',
}
if (res.data) {
console.log(res.data[this.timecurrent].afternoonList)
// var schedulePlanDetailId
res.data[this.timecurrent].afternoonList.forEach(e=>{
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
res.data[this.timecurrent].afternoonList.forEach(e => {
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
})
res.data[this.timecurrent].morningList.forEach(e=>{
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
res.data[this.timecurrent].morningList.forEach(e => {
this.qurey.schedulePlanDetailIds.push(e.schedulePlanDetailId)
})
updateStatus(this.qurey).then(res => {
if (res.code == 500) {
@ -233,7 +231,7 @@
title: res.msg,
type: 'error',
})
} else {
this.$refs.uToast.show({
title: '修改成功',
@ -241,20 +239,20 @@
duration: '1000'
})
this.updata()
}
})
}
})
},
//
taptimemorning(item, index) {
this.qurey={
schedulePlanDetailIds:[],
status:'1',
this.qurey = {
schedulePlanDetailIds: [],
status: '1',
}
this.status = item.status
this.timeindex = index
@ -265,7 +263,7 @@
this.qurey.status = "0"
}
this.qurey.schedulePlanDetailIds.push(item.schedulePlanDetailId)
console.log(this.qurey)
@ -291,10 +289,10 @@
//
taptimeafter(item, index) {
this.timeindexafter = index
this.qurey={
schedulePlanDetailIds:[],
status:''
this.qurey = {
schedulePlanDetailIds: [],
status: ''
}
if (item.status == true) {
this.qurey.status = "1"
@ -303,7 +301,7 @@
this.qurey.status = "0"
}
this.qurey.schedulePlanDetailIds.push(item.schedulePlanDetailId)
console.log(this.qurey)
updateStatus(this.qurey).then(res => {
@ -358,12 +356,12 @@
this.timeindex = null
this.Soonerorlater = null
},
timedata(){
timedata() {
this.timecurrent++
this.timeindexafter = null
this.timeindex = null
this.Soonerorlater = null
},
}
}
@ -567,7 +565,7 @@
border-radius: 5rpx 5rpx 5rpx 0rpx;
::v-deep .u-tabs[data-v-59a86fad] {
padding: 74rpx 0 0 0;
padding: 10rpx 0 0 0;
}
::v-deep .uni-scroll-view,
@ -576,11 +574,17 @@
height: 100%;
}
span {
position: absolute;
position: relative !important;
left: 50%;
transform: translateX(-50%);
top: 1%;
// top: 1%;
margin-top: 14rpx;
display: inline-block;
// background: red;
/* width: 100%; */
height: 30px;
}
::v-deep.tabs {

View File

@ -64,6 +64,8 @@
{{list.personName}}
</view>
<view class="fist">
<!-- <image></image> -->
<image class="imagelist" src="../../static/time.png" mode=""></image>
<image src="../../static/see.png" mode="" class="two" @tap="gotime"></image>
</view>
<view class="myorder titles" @tap="personlinfo()">
@ -383,9 +385,14 @@
left: 50%;
top: 13%;
transform: translateX(-50%);
background: url(../../static/time.png) no-repeat center center fixed;
background-size: contain;
// background: url(../../static/time.png) no-repeat center center fixed;
// background-size: contain;
margin-bottom: 50rpx;
.imagelist{
width: 100%;
height: 130rpx;
}
.two {
width: 168rpx;
height: 54rpx;