mine.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. <template>
  2. <view class="main">
  3. <view class="pr">
  4. <view class="header-content">
  5. <image src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/img/mybanner.png" style="width:100%;height:260rpx;"></image>
  6. </view>
  7. <view class="pr" style="z-index:2">
  8. <view class="plr15">
  9. <view class="bdr4 pb20">
  10. <view class="m-dpflex m-justify-start m-align-center" style="height: 165rpx;">
  11. <image binderror="_binderror" mode="scaleToFill" :src="info.avatar" style="width: 120rpx;height: 120rpx;border-radius: 50%;"></image>
  12. <text class="line1 f20 fb plr15 text-white">{{info.nickname}}</text>
  13. <navigator hoverClass="none" :url="'editinfo?name='+info.nickname+'&phone='+info.phone">
  14. <image class="header-img" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/myedit.png"></image>
  15. </navigator>
  16. <view class="pr tr m-flex">
  17. <!-- <view class="tip msg" v-if="true"></view> -->
  18. <navigator hoverClass="none" url="message">
  19. <image class="header-img" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/myinfo.png"></image>
  20. </navigator>
  21. </view>
  22. </view>
  23. <view class="pr m-xcenter plr20 header-box" style="padding: 40rpx 40rpx;background-color: #fff;border-radius: 16rpx;">
  24. <navigator class="m-flex tl f14 m-ycenter dpb" hoverClass="none" url="../personal/personal_information">
  25. <view class="m-gray-big f20 fb pr10">{{info.balance/100}}</view>
  26. <view class="m-gray-letter mt5 f12">余额(元)</view>
  27. </navigator>
  28. <view @click="gocoupon" class="m-flex tl f14 m-ycenter">
  29. <view class="m-gray-big f20 fb">{{info.coupon_num}}</view>
  30. <view class="m-gray-letter mt5 f12">优惠券(张)</view>
  31. </view>
  32. </view>
  33. </view>
  34. </view>
  35. </view>
  36. <view class="fb f18 plr20">我的订单</view>
  37. <view class="margin-lr-sm m-dpflex m-justify-start m-align-center overflow bg-white margin-top-sm" style="padding-top: 40rpx;padding-bottom: 40rpx;border-radius: 16rpx;box-shadow: 0 0 50rpx 0 rgba(0, 0, 0, 0.1);">
  38. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="../common_tools/my_consulting/my_consulting">
  39. <image style="width: 76rpx;height: 76rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/img/myzixun.png"
  40. mode=""></image>
  41. <!-- <view class="tip"></view> -->
  42. <view class="f14 m-gray-small mt10 line1">我的咨询</view>
  43. </navigator>
  44. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="../common_tools/my_consulting/my_appointment">
  45. <image style="width: 76rpx;height: 76rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/img/myyuyue.png"
  46. mode=""></image>
  47. <!-- <view class="tip"></view> -->
  48. <view class="f14 m-gray-small mt10 line1">我的预约</view>
  49. </navigator>
  50. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="../common_tools/my_consulting/my_opinion">
  51. <image style="width: 76rpx;height: 76rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/img/myyijian.png"
  52. mode=""></image>
  53. <!-- <view class="tip"></view> -->
  54. <view class="f14 m-gray-small mt10 line1">我的意见单</view>
  55. </navigator>
  56. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="../service_box/box_details">
  57. <image style="width: 76rpx;height: 76rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/img/myservice.png"
  58. mode=""></image>
  59. <!-- <view class="tip"></view> -->
  60. <view class="f14 m-gray-small mt10 line1">服务包订单</view>
  61. </navigator>
  62. </view>
  63. <navigator class="pr m-xcenter plr20 pt20" hoverClass="none" url="../archives/my_archives">
  64. <view class="fb f18 pr m-flex tl">健康档案</view>
  65. <view class="pr m-gray-small">档案列表</view>
  66. <label class="m-gray-letter iconfont icon-arrow-right f18 dpb"></label>
  67. </navigator>
  68. <view class="mt20 pr pb40" style="margin-left: 20rpx;margin-right: 20rpx;box-shadow: 0 0 50rpx 0 rgba(0, 0, 0, 0.1);height:380rpx;">
  69. <navigator class="m-ycenter pt40" hoverClass="none" url="../archives/add_archives" v-if="!istrue">
  70. <view class="bdr30 m-theme br-theme tc plr20 pt8 pb8 f14 width40">新增健康档案</view>
  71. <!-- <view class="pt20 f12 m-gray-letter">点击添加新的健康档案</view> -->
  72. </navigator>
  73. <swiper duration="500" @change="swiperChange" v-if="istrue" :current="itemcurrent" interval="5000" style="height:380rpx;"
  74. class="swiper-box">
  75. <swiper-item class="" style="box-sizing: border-box;" v-for="(ite,index) in patientList" :key="index">
  76. <view class="bg-white" style="border-radius: 16rpx;height: 100%;">
  77. <view @click="gotoinfo(ite)" style="height: 100%;">
  78. <view class="fb f18 pt20 margin-left">{{ite.name}}</view>
  79. <view class="f14 m-gray-letter pt10 margin-left">年龄:<text class="text-black">{{ite.age}}岁</text></view>
  80. <view class="plr10 m-dpflex m-justify-start m-align-center overflow pb30 pt30" style="margin-top:60rpx;border-top: 2rpx solid rgb(248,248,248);">
  81. <view class="width33 m-ycenter overflow pr">
  82. <view class="fb f18">{{ite.order_num}}</view>
  83. <view class="f12 m-gray-small mt6 line1">病例信息</view>
  84. </view>
  85. <view class="width33 m-ycenter overflow pr">
  86. <view class="fb f18">{{ite.pack_docter_num}}</view>
  87. <view class="f12 m-gray-small mt6 line1">就诊记录</view>
  88. </view>
  89. <view class="width33 m-ycenter overflow pr">
  90. <view class="fb f18">{{ite.perfectd_degree}}</view>
  91. <view class="f12 m-gray-small mt6 line1">个人资料</view>
  92. </view>
  93. </view>
  94. </view>
  95. </view>
  96. </swiper-item>
  97. </swiper>
  98. <view class="dots">
  99. <view :class="index==itemcurrent?'dot active':'dot'" v-for="(item,index) in patientList.length" :key="index"></view>
  100. </view>
  101. </view>
  102. <view class="fb f18 plr20 pt40">常用工具</view>
  103. <view class="bg-white margin-lr-sm margin-top-sm" style="border-radius: 16rpx;box-shadow: 0 0 50rpx 0 rgba(0, 0, 0, 0.1);">
  104. <view class="plr10 m-dpflex m-justify-start m-align-center overflow pt30 pb30">
  105. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="/pages/common_tools/home_doctor">
  106. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/mydoctor.png"></image>
  107. <view class="f14 m-gray-small mt10 line1">家庭医生</view>
  108. </navigator>
  109. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="/pages/common_tools/me_follow">
  110. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/myguanzhu.png"></image>
  111. <view class="f14 m-gray-small mt10 line1">我的关注</view>
  112. </navigator>
  113. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="/pages/common_tools/collection/collection">
  114. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/wenzhang.png"></image>
  115. <view class="f14 m-gray-small mt10 line1">收藏文章</view>
  116. </navigator>
  117. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="/pages/common_tools/me_order/me_order">
  118. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/baodan.png"></image>
  119. <!-- <view class="tip"></view> -->
  120. <view class="f14 m-gray-small mt10 line1">我的保单</view>
  121. </navigator>
  122. </view>
  123. <view class="plr10 m-dpflex m-justify-start m-align-center overflow pb30">
  124. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="/pages/common_tools/me_evaluate">
  125. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/pinjia.png"></image>
  126. <view class="f14 m-gray-small mt10 line1">我的评价</view>
  127. </navigator>
  128. <navigator class="width25 m-ycenter overflow pr" hoverClass="none" url="/pages/common_tools/help_feedback/help_feedback">
  129. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/myhple.png"></image>
  130. <view class="f14 m-gray-small mt10 line1">帮助反馈</view>
  131. </navigator>
  132. <view class="width25 m-ycenter overflow pr">
  133. <image style="width: 42rpx;height: 42rpx;" src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/toolimg/kefu.png"></image>
  134. <view class="f14 m-gray-small mt10 line1">客服咨询</view>
  135. </view>
  136. </view>
  137. </view>
  138. </view>
  139. <view class="cu-tabbar-height"></view>
  140. <view class="cu-tabbar-height"></view>
  141. <u-no-network></u-no-network>
  142. </view>
  143. </template>
  144. <script>
  145. import store from '@/store'
  146. export default {
  147. onLoad(options) {
  148. },
  149. onShow() {
  150. this.getUserInfo()
  151. this.getarchives()
  152. },
  153. data() {
  154. return {
  155. itemcurrent: 0,
  156. info: {},
  157. istrue: false,
  158. patientList: []
  159. }
  160. },
  161. methods: {
  162. swiperChange(e) {
  163. this.itemcurrent = e.detail.current
  164. },
  165. getUserInfo: async function() {
  166. let res = await this.$request.post('/api/v1/user/userInfo')
  167. if (res.status == 0) {
  168. this.info = res.data
  169. console.log(this.info)
  170. store.commit('setUser', this.info)
  171. // getApp().globalData.imService = new IMService();
  172. // let loginResult = getApp().globalData.imService.login(e.detail.userInfo);
  173. // if (loginResult) {
  174. // //连接IM
  175. // getApp().globalData.imService.connectIM();
  176. // }
  177. }
  178. },
  179. gotoinfo(ite) {
  180. uni.navigateTo({
  181. url: "../archives/archives_info?id=" + ite.id
  182. })
  183. },
  184. getarchives: async function() {
  185. let res = await this.$request.post("/api/v1/patient/patientList")
  186. if (res.status == 0) {
  187. this.patientList = res.data.data
  188. console.log(this.patientList)
  189. if (this.patientList.length != 0) {
  190. this.istrue = true
  191. }
  192. }
  193. },
  194. gocoupon() {
  195. uni.navigateTo({
  196. url: "../personal/coupon/coupon"
  197. })
  198. }
  199. }
  200. };
  201. </script>
  202. <style scoped>
  203. @import url("./mine.css");
  204. .header-content {
  205. position: absolute;
  206. top: 0;
  207. right: 0;
  208. bottom: 0;
  209. left: 0;
  210. width: 100%;
  211. z-index: -1;
  212. overflow: hidden;
  213. box-sizing: border-box;
  214. }
  215. .header-box {
  216. box-shadow: 0px 8rpx 34rpx -6rpx rgba(248, 151, 164, 0.13);
  217. }
  218. .header-img {
  219. width: 36rpx;
  220. height: 36rpx;
  221. }
  222. .tip {
  223. position: absolute;
  224. top: 0;
  225. right: 20%;
  226. bottom: 0;
  227. background-color: red;
  228. width: 12rpx;
  229. height: 12rpx;
  230. border-radius: 50%;
  231. }
  232. .msg {
  233. top: -3rpx;
  234. right: -9rpx;
  235. }
  236. swiper {
  237. height: 320rpx;
  238. }
  239. .swiper-wrapper {
  240. padding: 0 10rpx;
  241. box-sizing: border-box;
  242. }
  243. .swiper-item {
  244. width: 100%;
  245. height: 300rpx;
  246. box-shadow: 0 26rpx 40rpx 0 rgba(255, 255, 255, 0.31);
  247. background: url("http://file.supermm.me/miniProgram/images/personal/bg_doc.png") no-repeat bottom center;
  248. }
  249. .dots {
  250. position: absolute;
  251. left: 0;
  252. right: 0;
  253. bottom: -40rpx;
  254. display: flex;
  255. justify-content: center;
  256. }
  257. .dots .dot {
  258. margin: 0 8rpx;
  259. width: 14rpx;
  260. height: 14rpx;
  261. background: #E4E4E4;
  262. border-radius: 8rpx;
  263. transition: all .6s;
  264. }
  265. .dots .dot.active {
  266. width: 24rpx;
  267. background: rgb(153, 153, 153);
  268. }
  269. .game-wrap {
  270. position: relative;
  271. width: 100%;
  272. height: 100%;
  273. overflow: hidden;
  274. box-sizing: border-box;
  275. }
  276. .game-item {
  277. height: 100%;
  278. background: url("https://file.supermm.me/h5/wechat-h5/integral/personeBg001.jpg") no-repeat;
  279. background-size: 100% 100%;
  280. background-position: center center;
  281. border-radius: 100rpx;
  282. }
  283. </style>