医生详情

This commit is contained in:
zoujiandong 2024-04-18 11:44:51 +08:00
parent 56fda3ec81
commit 8931fed976
3 changed files with 51 additions and 12 deletions

View File

@ -365,3 +365,10 @@ page{
display: flex;
flex-direction: column;
}
.nonedata{
display:flex;
width:100%;
min-height:500rpx;
align-items: center;
justify-content: center;
}

View File

@ -132,9 +132,35 @@ bindchange(e){
currentData: e.detail.current
})
},
goVisit:throttle(function(){
let doctorid=this.data.doctor_id;
if(this.data.canVisit){
app.method.navigateTo({
url:'/healthyService/pages/visitDetail/visitDetail?doctor_id='+doctorid
})
}else{
app.method.navigateTo({
url:'/healthyService/pages/visitList/visitList'
})
}
}),
goHealthy:throttle(function(){
let doctorid=this.data.doctor_id;
let price=this.data.healthyPrice;
if(this.data.canHealthy){
app.method.navigateTo({
url:'/healthyService/pages/healthyDetail/healthyDetail?doctor_id='+doctorid+"&price="+price
})
}else{
app.method.navigateTo({
url:'/healthyService/pages/healthyIntro/healthyIntro'
})
}
}),
switchTab(e){
let {id}=e. currentTarget.dataset;
console.log(id);
this.setData({
currentData:Number(id)
})
@ -151,12 +177,14 @@ bindchange(e){
inquiry_mode:9,
tab3Height:0
})
this.goVisit();
}else if(id==2){
this.setData({
inquiry_type:1,
inquiry_mode:8,
tab3Height:0
})
this.goHealthy();
}else if(id==3){
this.getHeight(4);
let {hasVideoList,canVideo}=this.data;
@ -164,9 +192,10 @@ bindchange(e){
inquiry_type:1,
inquiry_mode:2,
})
if(hasVideoList && !canVideo){
this.goVideo();
}
this.getVideoDoctorList();
// if(hasVideoList && !canVideo){
// this.goVideo();
// }
}else {
this.getHeight(5)
this.setData({
@ -479,6 +508,7 @@ bindchange(e){
})
},
getVideoDoctorList(){
let {canVideo}=this.data;
doctorList({
page:1,
inquiry_type:1,
@ -495,6 +525,10 @@ bindchange(e){
this.setData({
hasVideoList:true
})
if(!canVideo){
this.goVideo();
}
}
})
},
@ -546,18 +580,16 @@ bindchange(e){
if(this.data.canVideo){
let {hasVideoList,canVideo}=this.data;
this.setData({
currentData:1,
currentData:3,
inquiry_type:1,
inquiry_mode:2
})
if(hasVideoList && !canVideo){
this.goVideo();
}
this.getVideoDoctorList();
this.getHeight(2)
}else{
if(this.data.canDiffcult){
this.setData({
currentData:2,
currentData:4,
inquiry_type:1,
inquiry_mode:6
})
@ -588,7 +620,7 @@ bindchange(e){
this.getDeatil(doctor_id);
this.getService(doctor_id);
this.getEvaluationList();
this.getVideoDoctorList();
//this.getVideoDoctorList();
},

View File

@ -160,7 +160,7 @@
</view>
</view>
<swiper current="{{currentData}}" class="swiperbox" bindchange="bindchange" style="height:{{tab3Height+'px'}}">
<swiper current="{{currentData}}" class="swiperbox" bindchange="bindchange" style="height:{{tab3Height+'px'}};margin-top:{{tab3Height==0?'0rpx':'35rpx'}}">
<swiper-item >
<view class="swiper-item" id="swiperitem1">