| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538 | 
							- <template>
 
- 	<view class="content">
 
- 		<view class="bg"></view>
 
- 		<view class="cont">
 
- 			<view class="doc-box">
 
- 				<view class="left">
 
- 					<image  @click="showImg()" :src="doctor.avatar" mode="aspectFill"></image>
 
- 				</view>
 
- 				<view class="right">
 
- 					<view class="doc-name-box">
 
- 						<view class="doc-name">
 
- 							{{doctor.doctorName}}
 
- 						</view>
 
- 						<view class="doc-ping">
 
- 							<u-rate activeColor="#ffc603" count="5" readonly v-model="doctor.pingStar"></u-rate>
 
- 						</view>
 
- 					</view>
 
- 					<view class="doc-dept-box">
 
- 						{{department.deptName}}|{{doctor.position}}
 
- 					</view>
 
- 					<view class="doc-his-box">
 
- 						{{hospital.hospitalName}}
 
- 					</view>
 
- 				</view>
 
- 				
 
- 			</view>
 
- 			<view class="desc-box">
 
- 				<view class="title-box">
 
- 					<view class="line"></view>
 
- 					<view class="title">擅长方向</view>
 
- 				</view>
 
- 				<view class="desc" >
 
- 					{{doctor.speciality}}
 
- 				</view>
 
- 			</view>			 
 
- 			<view class="desc-box">
 
- 				<view class="title-box">
 
- 					<view class="line"></view>
 
- 					<view class="title">医生介绍</view>
 
- 				</view>
 
- 				<view class="desc" >
 
- 					{{doctor.introduction}}
 
- 				</view>
 
- 			</view>
 
- 			<view class="desc-box" v-if="imgs&&imgs.length>0">
 
- 				<view class="title-box">
 
- 					<view class="line"></view>
 
- 					<view class="title">荣誉资质</view>
 
- 				</view>
 
- 				<view class="desc doc-imgs" >
 
- 					<image v-for="i in imgs" :src="i" mode="aspectFill" @click="previewImage"></image>
 
- 				</view>
 
- 			</view>
 
- 			<view class="desc-box" v-if="videoUrl">
 
- 				<view class="title-box">
 
- 					<view class="line"></view>
 
- 					<view class="title">医生风采</view>
 
- 				</view>
 
- 				<view class="desc" >
 
- 					<video :src="videoUrl" :poster="thumbnail" :autoplay='true' class="doc-video"></video>
 
- 				</view>
 
- 			</view>
 
- 		</view>
 
- 	</view>
 
- </template>
 
- <script>
 
- 	import {checkFollow,doFollow,getDoctorDetails,getDoctorPingList} from '@/api/doctor.js'
 
- 	export default {
 
- 		data() {
 
- 			return {
 
- 				isFollow:false,
 
- 				doctorId:null,
 
- 				doctor:null,
 
- 				department:null,
 
- 				hospital:null,
 
- 				pings:[],
 
- 				videoUrl: '',
 
- 				imgs: [],
 
- 				thumbnail: ''
 
- 			}
 
- 		},
 
- 		onLoad(options) {
 
- 			this.doctorId=options.doctorId;
 
- 			
 
- 		},
 
- 		onShow() {
 
- 			this.getDoctorDetails();
 
- 			 
 
- 		},
 
- 		methods: {
 
- 			showImg(){
 
- 				var data=[];
 
- 				data.push(this.doctor.avatar)
 
- 				uni.previewImage({
 
- 					current: 0,
 
- 					urls: data
 
- 				});
 
- 			},
 
- 			previewImage() {
 
- 				uni.previewImage({
 
- 					current: 0,
 
- 					urls: this.imgs
 
- 				});
 
- 			},
 
- 			getDoctorDetails() {
 
- 				//联网加载数据
 
- 				var that = this;
 
- 				var data = {
 
- 					doctorId: this.doctorId
 
- 				};
 
- 				getDoctorDetails(data).then(res => {
 
- 					if(res.code==200){
 
- 						this.doctor=res.data.doctor;
 
- 						this.department=res.data.department;
 
- 						this.hospital=res.data.hospital;
 
- 						this.thumbnail = this.doctor&&this.doctor.thumbnail;
 
- 						this.videoUrl = this.doctor&&this.doctor.videoUrl;
 
- 						this.imgs = this.doctor&&this.doctor.honorImgUrl? this.doctor.honorImgUrl.split(','):[];
 
- 					}else{
 
- 						uni.showToast({
 
- 							icon:'none',
 
- 							title: "请求失败",
 
- 						});
 
- 					}
 
- 				});
 
- 			},
 
- 		}
 
- 	}
 
- </script>
 
- <style scoped lang="scss">
 
- 	.content{
 
- 		height: 100%;
 
- 		position: relative;
 
- 		.bg{
 
- 			width: 100%;
 
- 			height:280rpx;
 
- 			background-color: #2583EB;
 
- 			background: linear-gradient(#2583EB, #2EDAD4);
 
- 			border-radius: 0rpx 0rpx 50rpx 50rpx;
 
- 			position: fixed;
 
- 			// z-index: 1;
 
- 		}
 
- 		.cont{
 
- 			top:50rpx;
 
- 			position: relative;
 
- 			padding: 0rpx 20rpx;
 
- 			z-index: 999;
 
- 			width: 100%;
 
- 			display: flex;
 
- 			flex-direction: column;
 
- 			.doc-box{
 
- 				margin-bottom: 20rpx;
 
- 				padding: 30rpx;
 
- 				box-shadow: 0px 0px 5px 2px rgba(0,0,0,0.05);
 
- 				background-color: #fff;
 
- 				border-radius: 15rpx;
 
- 				display: flex;
 
- 				align-items: center;
 
- 				justify-content: flex-start;
 
- 				.left{
 
- 					width: 190upx;
 
- 					height: 190upx;
 
- 					border-radius: 8upx;
 
- 					image{
 
- 						width: 190upx;
 
- 						height: 190upx;
 
- 					}
 
- 				}
 
- 				.right{
 
- 					display: flex;
 
- 					flex-direction: column;
 
- 					justify-content: flex-start;
 
- 					margin-left: 20rpx;
 
- 					height:190upx;
 
- 					width: calc(100% - 210upx);
 
- 					.doc-name-box{
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: flex-start;
 
- 						position: relative;
 
- 						.doc-name{
 
- 							font-size: 38rpx;
 
- 							font-weight: bold;
 
- 						}
 
- 						.doc-ping{
 
- 							margin-left: 10rpx;
 
- 						}
 
- 						.doc-star{
 
- 							position: absolute;
 
- 							top:5rpx;
 
- 							right:0rpx;
 
- 							width:32rpx;
 
- 							height:32rpx;
 
- 							image{
 
- 								width:100%;
 
- 								height:100%;
 
- 							}
 
- 						}
 
- 					}
 
- 					.doc-dept-box{
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: flex-start;
 
- 						margin-top: 15rpx;
 
- 						font-size: 28upx;
 
- 						font-family: PingFang SC;
 
- 						color: #2d2b36;
 
- 						 
 
- 					}
 
- 					.doc-his-box{
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: flex-start;
 
- 						margin-top: 15rpx;
 
- 						font-size: 28upx;
 
- 						font-family: PingFang SC;
 
- 						color: #9a9a9c;
 
- 						 
 
- 					}
 
- 					.doc-spec-box{
 
- 						width: 100%;
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: space-between;
 
- 						margin-top: 15rpx;
 
- 						.spec-left{
 
- 							width: 80%;
 
- 							display: flex;
 
- 							align-items: center;
 
- 							justify-content: flex-start;
 
- 							.title{
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								color: #9a9a9c;
 
- 							}
 
- 							.spec{
 
- 								// margin-left: 10rpx;
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								color: #9a9a9c;
 
- 							}
 
- 						}
 
- 						.spec-right{
 
- 							.btn{
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								color: #2583EB;
 
- 							}
 
- 						}
 
- 						
 
- 					}
 
- 				}
 
- 				
 
- 			}
 
- 			.price-box{
 
- 				margin-bottom: 20rpx;
 
- 				padding: 15rpx;
 
- 				box-shadow: 0px 0px 5px 2px rgba(0,0,0,0.05);
 
- 				background-color: #fff;
 
- 				border-radius: 15rpx;
 
- 				.title-box{
 
- 					display: flex;
 
- 					flex-direction: row;
 
- 					align-items: center;
 
- 					justify-content: flex-start;
 
- 					.title{
 
- 						font-size: 32upx;
 
- 						font-family: PingFang SC;
 
- 						font-weight: bold;
 
- 						color: #111111;
 
- 					}
 
- 					.line{
 
- 						margin-right: 15rpx;
 
- 						height: 30rpx;
 
- 						width: 6rpx;
 
- 						background-color: #2583EB;
 
- 						
 
- 					}
 
- 					 
 
- 				}
 
- 				.price-list{
 
- 					display: flex;
 
- 					flex-direction: column;
 
- 					align-items: flex-start;
 
- 					justify-content: flex-start;
 
- 					margin-top: 15rpx;
 
- 					padding: 15rpx;
 
- 					.price-item{
 
- 						margin-bottom: 15rpx;
 
- 						padding: 15rpx;
 
- 						width: 100%;
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: space-between;
 
- 						border-radius: 15rpx;
 
- 						background-color: #f1f6fc;
 
- 						.left{
 
- 							.price-name{
 
- 								font-size: 32upx;
 
- 								font-family: PingFang SC;
 
- 								color: #111111;
 
- 								display: flex;
 
- 								align-items: center;
 
- 								justify-content: flex-start;
 
- 								.price{
 
- 									margin-left: 15rpx;
 
- 									font-size: 32upx;
 
- 									font-family: PingFang SC;
 
- 									color: #fe9460;
 
- 									
 
- 								}
 
- 							}
 
- 							.price-desc{
 
- 								margin-top: 20rpx;
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								color: #9a9a9c;
 
- 							}
 
- 							
 
- 						}
 
- 						.right{
 
- 							.btn{
 
- 								padding: 15rpx 30rpx;
 
- 								background-color: #ff9561;
 
- 								color: #fff;
 
- 								font-size: 28rpx;
 
- 								border-radius: 15rpx;
 
- 							}
 
- 						}
 
- 					}
 
- 				}
 
- 			}
 
- 			.his-box{
 
- 				margin-bottom: 20rpx;
 
- 				padding: 15rpx;
 
- 				box-shadow: 0px 0px 5px 2px rgba(0,0,0,0.05);
 
- 				background-color: #fff;
 
- 				border-radius: 15rpx;
 
- 				.title-box{
 
- 					display: flex;
 
- 					flex-direction: row;
 
- 					align-items: center;
 
- 					justify-content: flex-start;
 
- 					.title{
 
- 						font-size: 32upx;
 
- 						font-family: PingFang SC;
 
- 						font-weight: bold;
 
- 						color: #111111;
 
- 					}
 
- 					.line{
 
- 						margin-right: 15rpx;
 
- 						height: 30rpx;
 
- 						width: 6rpx;
 
- 						background-color: #2583EB;
 
- 						
 
- 					}
 
- 					 
 
- 				}
 
- 				.his{
 
- 					display: flex;
 
- 					align-items: center;
 
- 					justify-content: space-between;
 
- 					margin-top: 15rpx;
 
- 					.left{
 
- 						display: flex;
 
- 						flex-direction: column;
 
- 						align-items: flex-start;
 
- 						justify-content: center;
 
- 						.his-name{
 
- 							font-size: 32upx;
 
- 							font-family: PingFang SC;
 
- 							color: #111111;
 
- 						}
 
- 						.his-desc{
 
- 							margin-top: 15rpx;
 
- 							font-size: 28upx;
 
- 							font-family: PingFang SC;
 
- 							color: #9a9a9c;
 
- 						}
 
- 					}
 
- 					.right{
 
- 						image{
 
- 							width:30rpx;
 
- 							height:30rpx;
 
- 						}
 
- 					}
 
- 				}
 
- 			}
 
- 			.desc-box{
 
- 				margin-bottom: 20rpx;
 
- 				padding: 15rpx;
 
- 				box-shadow: 0px 0px 5px 2px rgba(0,0,0,0.05);
 
- 				background-color: #fff;
 
- 				border-radius: 15rpx;
 
- 				.title-box{
 
- 					display: flex;
 
- 					flex-direction: row;
 
- 					align-items: center;
 
- 					justify-content: flex-start;
 
- 					.title{
 
- 						font-size: 32upx;
 
- 						font-family: PingFang SC;
 
- 						font-weight: bold;
 
- 						color: #111111;
 
- 					}
 
- 					.line{
 
- 						margin-right: 15rpx;
 
- 						height: 30rpx;
 
- 						width: 6rpx;
 
- 						background-color: #2583EB;
 
- 						
 
- 					}
 
- 					 
 
- 				}
 
- 				.desc{
 
- 					margin-top: 15rpx;
 
- 					font-size: 28upx;
 
- 					font-family: PingFang SC;
 
- 					color: #9a9a9c;
 
- 				}
 
- 			}
 
- 			.ping-box{
 
- 				margin-bottom: 20rpx;
 
- 				padding: 15rpx;
 
- 				box-shadow: 0px 0px 5px 2px rgba(0,0,0,0.05);
 
- 				background-color: #fff;
 
- 				border-radius: 15rpx;
 
- 				.title-box{
 
- 					display: flex;
 
- 					flex-direction: row;
 
- 					align-items: center;
 
- 					justify-content: space-between;
 
- 					.left{
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: center;
 
- 						.title{
 
- 							font-size: 32upx;
 
- 							font-family: PingFang SC;
 
- 							font-weight: bold;
 
- 							color: #111111;
 
- 						}
 
- 						.line{
 
- 							margin-right: 15rpx;
 
- 							height: 30rpx;
 
- 							width: 6rpx;
 
- 							background-color: #2583EB;
 
- 							
 
- 						}
 
- 					}
 
- 					.more{
 
- 						display: flex;
 
- 						align-items: center;
 
- 						justify-content: center;
 
- 						font-size: 28upx;
 
- 						font-family: PingFang SC;
 
- 						color: #9a9a9c;
 
- 						image{
 
- 							margin-left: 10rpx;
 
- 							width: 30rpx;
 
- 							height:30rpx;
 
- 						}
 
- 					}
 
- 					
 
- 					 
 
- 				}
 
- 				.ping-list{
 
- 					display: flex;
 
- 					flex-direction: column;
 
- 					align-items: flex-start;
 
- 					justify-content: flex-start;
 
- 					margin-top: 15rpx;
 
- 					padding: 15rpx;
 
- 					.ping-item{
 
- 						padding: 20rpx 0rpx;
 
- 						border-bottom: 1rpx solid #efefef;
 
- 						width: 100%;
 
- 						display: flex;
 
- 						align-items: flex-start;
 
- 						justify-content: flex-start;
 
- 						&:last-child{
 
- 							padding-bottom: 0rpx;
 
- 							border-bottom: none;
 
- 						}
 
- 						.left{
 
- 							image{
 
- 								width:80rpx;
 
- 								height:80rpx;
 
- 								border-radius: 50%;
 
- 							}
 
- 						}
 
- 						.right{
 
- 							width: 100%;
 
- 							margin-left: 15rpx;
 
- 							.user-name-box{
 
- 								display: flex;
 
- 								align-items: center;
 
- 								justify-content: space-between;
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								font-weight: bold;
 
- 								color: #111111;
 
- 							}
 
- 							.ping-cont{
 
- 								margin-top: 10rpx;
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								color: #9a9a9c;
 
- 							}
 
- 							.ping-time{
 
- 								margin-top: 10rpx;
 
- 								font-size: 28upx;
 
- 								font-family: PingFang SC;
 
- 								color: #9a9a9c;
 
- 							}
 
- 							 
 
- 						}
 
- 					}
 
- 				}
 
- 			}
 
- 		}
 
- 	}
 
- 	.doc-video {
 
- 		width: 680rpx;
 
- 		height: 382.5rpx;
 
- 	}
 
- 	.doc-imgs {
 
- 		display: flex;
 
- 		flex-direction: row;
 
- 		flex-wrap: wrap;
 
- 		align-items: center;
 
- 		image {
 
- 			height: 180rpx;
 
- 			width: 320rpx;
 
- 			margin: 0 10rpx 20rpx;
 
- 		}
 
- 	}
 
- </style>
 
 
  |