From 8931fed97652cdfcd960ea26954d6611fd570c64 Mon Sep 17 00:00:00 2001 From: zoujiandong <10130823232@qq.com> Date: Thu, 18 Apr 2024 11:44:51 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8C=BB=E7=94=9F=E8=AF=A6=E6=83=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- healthyService/pages/visitList/visitList.wxss | 7 +++ patient/pages/expertDetail/expertDetail.js | 54 +++++++++++++++---- patient/pages/expertDetail/expertDetail.wxml | 2 +- 3 files changed, 51 insertions(+), 12 deletions(-) diff --git a/healthyService/pages/visitList/visitList.wxss b/healthyService/pages/visitList/visitList.wxss index 22c20fb..1dc2e85 100644 --- a/healthyService/pages/visitList/visitList.wxss +++ b/healthyService/pages/visitList/visitList.wxss @@ -364,4 +364,11 @@ page{ .popwrper{ display: flex; flex-direction: column; + } + .nonedata{ + display:flex; + width:100%; + min-height:500rpx; + align-items: center; + justify-content: center; } \ No newline at end of file diff --git a/patient/pages/expertDetail/expertDetail.js b/patient/pages/expertDetail/expertDetail.js index d15b474..45d88ad 100644 --- a/patient/pages/expertDetail/expertDetail.js +++ b/patient/pages/expertDetail/expertDetail.js @@ -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, @@ -490,11 +520,15 @@ bindchange(e){ this.setData({ hasVideoList:false }); - + }else{ 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(); }, diff --git a/patient/pages/expertDetail/expertDetail.wxml b/patient/pages/expertDetail/expertDetail.wxml index 67b87aa..2c02e4f 100644 --- a/patient/pages/expertDetail/expertDetail.wxml +++ b/patient/pages/expertDetail/expertDetail.wxml @@ -160,7 +160,7 @@ - +