doctorIntroduction.vue 4.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. <template>
  2. <div class="page_doctorIntroduction">
  3. <div>
  4. <div class="contentOne">
  5. <div class="img">
  6. <img :src="doctors.dochead" style="width:100%;height:100%" alt />
  7. </div>
  8. <div class="detail">
  9. <p class="detailTitle">{{doctors.name}}</p>
  10. <p class="detailMessage">{{doctors.user_title}}</p>
  11. </div>
  12. </div>
  13. <!-- <div class="good">
  14. <div class="common_title">
  15. <div class="one"></div>
  16. <div class="dynamicTxt">医生擅长</div>
  17. </div>
  18. <div class="goodtxt">擅长甲状腺、胆结石</div>
  19. </div>-->
  20. <div class="good">
  21. <div class="common_title">
  22. <div class="one"></div>
  23. <div class="dynamicTxt">医生简介</div>
  24. </div>
  25. <div class="goodtxt" v-html="doctors.content"></div>
  26. </div>
  27. </div>
  28. </div>
  29. </template>
  30. <script>
  31. import { singleDoctorInfo } from "@/api/micro/micro";
  32. export default {
  33. data() {
  34. return {
  35. doctors: []
  36. };
  37. },
  38. methods: {
  39. singleDoctorInfo(id, orgid) {
  40. singleDoctorInfo(id, orgid).then(response => {
  41. if (response.data.state == 1) {
  42. var editdoctor = response.data.data.editdoctor;
  43. console.log("editdoctor是什么",editdoctor)
  44. if (editdoctor.user_title == 1) {
  45. editdoctor.user_title = "医士";
  46. }
  47. if (editdoctor.user_title == 2) {
  48. editdoctor.user_title = "医师";
  49. }
  50. if (editdoctor.user_title == 3) {
  51. editdoctor.user_title = "住院医师";
  52. }
  53. if (editdoctor.user_title == 4) {
  54. editdoctor.user_title = "主治医师";
  55. }
  56. if (editdoctor.user_title == 5) {
  57. editdoctor.user_title = "副主任医师";
  58. }
  59. if (editdoctor.user_title == 6) {
  60. editdoctor.user_title = "主任医师";
  61. }
  62. if (editdoctor.user_title == 7) {
  63. editdoctor.user_title = "护士";
  64. }
  65. if (editdoctor.user_title == 8) {
  66. editdoctor.user_title = "护师";
  67. }
  68. if (editdoctor.user_title == 9) {
  69. editdoctor.user_title = "主管护师";
  70. }
  71. if (editdoctor.user_title == 10) {
  72. editdoctor.user_title = "副主任护师";
  73. }
  74. if (editdoctor.user_title == 11) {
  75. editdoctor.user_title = "主任护师";
  76. }
  77. console.log("editdoctor", editdoctor);
  78. this.doctors = editdoctor;
  79. }
  80. });
  81. }
  82. },
  83. created() {
  84. const id = this.$route.query.id;
  85. const orgid = this.$route.query.orgid;
  86. console.log("医生id是多少", id);
  87. console.log("orgid是多少", orgid);
  88. this.singleDoctorInfo(id, orgid);
  89. }
  90. };
  91. </script>
  92. <style lang="scss" scoped>
  93. .page_doctorIntroduction {
  94. overflow: hidden;
  95. height: 100%;
  96. overflow-y: auto;
  97. &::-webkit-scrollbar {
  98. width: 0;
  99. }
  100. }
  101. .contentOne {
  102. margin: auto;
  103. margin-top: 1.125rem;
  104. width: 20.875rem;
  105. height: 7.4375rem;
  106. background: rgba(255, 255, 255, 1);
  107. box-shadow: 0px 6px 20px 0px rgba(0, 0, 0, 0.05);
  108. border-radius: 0.5rem;
  109. padding-left: 1rem;
  110. padding-top: 1.125rem;
  111. box-sizing: border-box;
  112. .img {
  113. float: left;
  114. width: 5rem;
  115. height: 5rem;
  116. border-radius: 0.3125rem;
  117. img {
  118. border-radius: 0.3125rem;
  119. }
  120. }
  121. .detail {
  122. float: left;
  123. margin-left: 0.8125rem;
  124. width: 13.125rem;
  125. .detailTitle {
  126. margin-top: 0.5rem;
  127. width: 12.6875rem;
  128. height: 1.0625rem;
  129. font-size: 0.9375rem;
  130. font-weight: 600;
  131. color: rgba(7, 18, 40, 1);
  132. span {
  133. font-size: 0.875rem;
  134. color: rgba(155, 155, 155, 1);
  135. line-height: 1.125rem;
  136. margin-left: 1.25rem;
  137. font-weight: 400;
  138. }
  139. }
  140. .detailMessage {
  141. font-size: 0.875rem;
  142. color: rgba(155, 155, 155, 1);
  143. line-height: 1.5rem;
  144. font-weight: 400;
  145. margin-top: 0.875rem;
  146. height: 30px;
  147. overflow: hidden;
  148. text-overflow: ellipsis;
  149. display: -webkit-box;
  150. -webkit-line-clamp: 1;
  151. -webkit-box-orient: vertical;
  152. // border: solid 1px red;
  153. }
  154. }
  155. }
  156. .good {
  157. margin-left: 1.25rem;
  158. margin-top: 2.1875rem;
  159. }
  160. .common_title {
  161. width: 20.9375rem;
  162. height: 1.125rem;
  163. line-height: 1.125rem;
  164. }
  165. .dynamicTxt {
  166. float: left;
  167. width: 6.25rem;
  168. height: 1.125rem;
  169. line-height: 1.125rem;
  170. font-size: 1.125rem;
  171. font-weight: 600;
  172. color: rgba(7, 18, 40, 1);
  173. }
  174. .one {
  175. margin-top: 0.125rem;
  176. margin-right: 0.375rem;
  177. float: left;
  178. width: 0.125rem;
  179. height: 0.875rem;
  180. background: linear-gradient(
  181. 0deg,
  182. rgba(114, 182, 253, 1),
  183. rgba(52, 119, 254, 1)
  184. );
  185. box-shadow: 0px 3px 12px 0px rgba(60, 127, 254, 0.2);
  186. border-radius: 3px;
  187. }
  188. .goodtxt {
  189. margin: 1rem 2rem 2.25rem 0.875rem;
  190. font-size: 1rem;
  191. font-weight: 400;
  192. color: rgba(68, 75, 92, 1);
  193. line-height: 1.5rem;
  194. // padding-right: 1.25rem;
  195. box-sizing: border-box;
  196. }
  197. </style>