home.wxml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239
  1. <!--pages/home/home.wxml-->
  2. <view class="fullscreen-bg">
  3. <t-navbar title="中医健康管家" t-class-title="nav-title" />
  4. <scroll-view class="page-scroll__container" type="list" scroll-y style="height: {{pageHeight}};">
  5. <view class="follow-container">
  6. <view class="follow-box" bind:tap="showFollowPopup">
  7. <image src="../../assets/bg/icon_notice@3x.png" mode="heightFix" class="notice-icon" />
  8. <view class="pieces">{{popupList.length}}</view>
  9. <view class="follow-text" wx:if="{{popupList.length>0}}">{{popupList[0].title}}</view>
  10. </view>
  11. <view class="tool-bar-wrapper">
  12. <view class="tool" wx:if="{{location.description}}">
  13. <text>{{location.description}}</text>
  14. </view>
  15. <view class="tool" wx:if="{{solarTerms.description}}">
  16. <text>{{solarTerms.description}}</text>
  17. </view>
  18. </view>
  19. </view>
  20. <view class="body-img">
  21. <!-- 使用 image 标签确保图片清晰度 -->
  22. <image class="body-bg-image" src="../../assets/bg/pic_body@2x.png" mode="aspectFit" />
  23. <view class="header-container">
  24. <view class="user-info-wrapper" wx:if="{{patient}}">
  25. <view class="user-box">
  26. <text class="user-name">{{patient.name}}</text>
  27. <t-icon color="{{patientIconColor}}" name="{{patientIcon}}" size="20px"></t-icon>
  28. </view>
  29. <view class="user-pageBox">
  30. <text class="user-age" wx:if="{{patient.age}}">{{patient.age}}岁</text>
  31. <text class="user-description" overflow="fade" max-lines="1">{{patientDescription}}</text>
  32. </view>
  33. </view>
  34. </view>
  35. <view wx:if="{{healthReport.loading}}" class="loading-center">
  36. <t-loading theme="circular" size="48px" color="#2d92fd" />
  37. </view>
  38. <view class="healthyAnalyze" bindtap="goHealthAnalyze" wx:elif="{{isShowComplete}}">
  39. 请完成健康评估
  40. </view>
  41. <view class="steps-container" wx:else>
  42. <vertical-steps statusList="{{statusList}}" dataset="{{healthReport.data}}" bind:position="onBodyModel" />
  43. <view class="warn-box" wx:if="{{healthIndex.data.length>0}}">
  44. <image src="../../assets/bg/icon_warning@3x.png" class="warn-img" />
  45. <view class="right-box" bind:tap="tabValue">
  46. <view style="margin-bottom:10rpx" wx:for="{{healthIndex.data}}" wx:key="{{item.quotaId}}">{{item}}</view>
  47. </view>
  48. </view>
  49. </view>
  50. <view class="report-container" bind:tap="toReportPage" wx:if="{{healthReport.data.reportTime}}">
  51. <view class="report-box">
  52. <view>
  53. <image src="../../assets/bg/icon_file@3x.png" class="report-img" />
  54. </view>
  55. <view class="text-box" wx:if="{{healthReport.data.reportTime}}">
  56. <view class="text-one">健康分析报告</view>
  57. <view class="text-two">日期:{{healthReport.data.reportTime}}</view>
  58. </view>
  59. </view>
  60. </view>
  61. </view>
  62. <view class="care-container" wx:if="{{displayList.length>0}}">
  63. <view class="care-box">
  64. <view class="care-header">
  65. <image src="../../assets/icon/icon_plan@3x.png" class="care-icon" />
  66. <text>调养计划</text>
  67. </view>
  68. <view class="care-list">
  69. <block wx:for="{{displayList}}" wx:key="id">
  70. <view class="care-item">
  71. <view class="item-main" bindtap="toggleItem" data-index="{{index}}">
  72. <text class="dot"></text>
  73. <text class="item-title">{{item.conditioningProgramName}}</text>
  74. <text class="item-next-time" wx:if="{{item.arrangeDate && item.isOffline==='Y'}}">下一次时间:{{item.arrangeDate}}</text>
  75. <t-icon name="{{item.expanded ? 'chevron-up' : 'chevron-down'}}" size="24rpx" class="item-arrow" color="#C0C4CC" />
  76. </view>
  77. <!-- 这里放详细内容 -->
  78. <view class="item-detail" wx:if="{{item.expanded}}">
  79. <view style="width: 60%;">
  80. <!-- 轮播媒体容器 -->
  81. <view class="carousel-container" wx:if="{{item.carouselMediaList && item.carouselMediaList.length > 0}}">
  82. <!-- 轮播组件 -->
  83. <media-carousel
  84. mediaList="{{item.carouselMediaList}}"
  85. showIndicator="{{true}}" autoplay="{{true}}"
  86. interval="{{4000}}" circular="{{true}}"
  87. bind:fullscreenchange="onCarouselFullscreenChange"
  88. itemId="{{item.id}}" />
  89. </view>
  90. <view class="item-box">
  91. <view class="flex" wx:if="{{item.arrangeDate && item.isOffline==='Y'}}"><text>下一次时间:</text><text>{{item.arrangeDate}}</text></view>
  92. <view class="flex">
  93. <text wx:if="{{item.isOffline==='Y'}}">已完成:<text style="color:#2ec4b6">{{item.finishCount}}次</text><text style="margin:0 5px">/</text>
  94. <text>{{item.totalMeasure}}次</text></text>
  95. </view>
  96. <view>频次:每{{item.frequencyType}}天{{item.frequencyMeasure}}{{item.convertUnit}}</view>
  97. <view>开具医生:{{item.operateBy}}</view>
  98. <view wx:if="{{item.isOffline==='Y'}}">机构:{{item.conditioningProgramSupplierName}}</view>
  99. </view>
  100. </view>
  101. <view data-id="{{item.id}}" wx:if="{{item.isOffline==='N'}}" class="verify-record" bindtap="isGoPunchcard" data-signinTime="{{item.signinTime}}">{{
  102. item.signinTime?'已打卡':'打卡'
  103. }}</view>
  104. <view catchtap="onRecord" data-id="{{item.id}}" wx:if="{{item.isOffline==='Y'}}" class="verify-record">核销记录</view>
  105. </view>
  106. </view>
  107. </block>
  108. </view>
  109. <view class="expand-all" wx:if="{{careList.length > 4}}" bindtap="toggleAll">
  110. <t-icon name="{{allExpanded ? 'chevron-up' : 'chevron-down'}}" size="32rpx" class="expand-arrow" color="#C0C4CC" />
  111. </view>
  112. </view>
  113. </view>
  114. <view class="science-list-wrapper" wx:if="{{scienceList.length}}">
  115. <view class="list-title" bind:tap="toSciencePage">
  116. <view class="missionary">健康宣教</view>
  117. <view class="title-box serch">
  118. <text>查询</text>
  119. <t-icon name="chevron-right-double"></t-icon>
  120. </view>
  121. </view>
  122. <science-card wx:for="{{scienceList}}" wx:key="id" item="{{item}}" index="{{index}}"></science-card>
  123. </view>
  124. <science-card style="display: none;">
  125. <!--?-->
  126. </science-card>
  127. <view style="height: {{container.safeBottomOffset}}px;flex: none;"></view>
  128. </scroll-view>
  129. </view>
  130. <!-- 将 tabbar 移到最外层 -->
  131. <view class="tabbar-container" wx:if="{{false}}">
  132. <tabbar wx:if="{{!tabbarHidden}}" tabbarValue="{{tabbarValue}}" patientId="{{patient.patientId}}"></tabbar>
  133. </view>
  134. <view wx:if="{{sheet}}" class="draggable-sheet-shade" catch:tap="hideDraggableSheet"></view>
  135. <draggable-sheet class="draggable-sheet-wrapper" style="height: {{container.height}}px;" initial-child-size="0" min-child-size="0" max-child-size="1" snap="{{true}}" snap-sizes="{{[0.5]}}" worklet:onsizeupdate="onDraggableSizeUpdate">
  136. <scroll-view class="scrollable draggable-sheet-container" type="custom" scroll-y associative-container="draggable-sheet" show-scrollbar="{{false}}" bounces="{{false}}">
  137. <sticky-section>
  138. <sticky-header>
  139. <view class="draggable-sheet-bar">
  140. <view class="indicator" />
  141. </view>
  142. <view wx:if="{{position.CT}}" style="text-align: center;">预警信息</view>
  143. </sticky-header>
  144. <block wx:if="{{position.LT}}">
  145. <view class="card-wrapper" wx:for="{{position.LT}}" wx:key="*this">
  146. <t-cell wx:if="{{item.title}}" t-class="card-header cell-border-gradient" title="{{item.title}}" />
  147. <view wx:if="{{item.description}}" class="card-body">&emsp;&emsp;{{item.description}}</view>
  148. </view>
  149. </block>
  150. <block wx:if="{{position.RB}}">
  151. <view class="card-wrapper">
  152. <t-cell t-class="card-header cell-border-gradient" title="中医证素解释" />
  153. <view class="card-body">
  154. <view class="row" wx:for="{{position.RB.factorItems}}" wx:key="*this">
  155. <view class="primary">{{item.factorItemName}}</view>
  156. <view style="margin-top: 4px;" wx:if="{{item.factorItemDescription}}">&emsp;&emsp;{{item.factorItemDescription}}</view>
  157. </view>
  158. </view>
  159. </view>
  160. <view class="card-wrapper">
  161. <t-cell t-class="card-header cell-border-gradient" title="中医证型解释" />
  162. <view class="card-body">
  163. <view class="row" wx:for="{{position.RB.diagnoseSyndromes}}" wx:key="*this">
  164. <view class="primary">{{item.diagnoseSyndromeName}}</view>
  165. <view style="margin-top: 4px;" wx:if="{{item.diagnoseSyndromeAnalysis}}">&emsp;&emsp;{{item.diagnoseSyndromeAnalysis}}</view>
  166. </view>
  167. </view>
  168. </view>
  169. </block>
  170. <block wx:if="{{position.RT}}">
  171. <view class="card-wrapper">
  172. <t-cell t-class="card-header cell-border-gradient" title="{{position.RT.constitutionGroupName}}" />
  173. <view class="card-body">
  174. <span class="row">{{position.RT.constitutionGroupDefinition}}</span>
  175. </view>
  176. </view>
  177. <view class="card-wrapper">
  178. <t-cell t-class="card-header cell-border-gradient" title="舌象解释" />
  179. <view class="card-body">
  180. <view>&emsp;&emsp;{{position.RT.tongueAnalysisResult}}</view>
  181. <view class="picture-wrapper">
  182. <image src="{{position.RT.upImg}}" mode="aspectFit" />
  183. <image src="{{position.RT.downImg}}" mode="aspectFit" />
  184. </view>
  185. </view>
  186. </view>
  187. <view class="card-wrapper">
  188. <t-cell t-class="card-header cell-border-gradient" title="面象解释" />
  189. <view class="card-body">
  190. <view>&emsp;&emsp;{{position.RT.faceAnalysisResult}}</view>
  191. <view wx:if="{{position.RT.faceImg}}" class="picture-wrapper">
  192. <image src="{{position.RT.faceImg}}" mode="aspectFit" />
  193. </view>
  194. </view>
  195. </view>
  196. </block>
  197. <block wx:if="{{position.CT}}">
  198. <view class="CT row" wx:for="{{position.CT}}" wx:key="*this">{{item}}</view>
  199. </block>
  200. <view class="bottom-wrapper">
  201. <form-button index="2" bind:tap="hideDraggableSheet" disableOnClick="{{false}}"></form-button>
  202. </view>
  203. </sticky-section>
  204. </scroll-view>
  205. <tabbar tabbarValue="{{tabbarValue}}" patientId="{{patient.patientId}}" wx:if="{{!tabbarHidden}}"></tabbar>
  206. <t-popup visible="{{isShowPopup}}" usingCustomNavbar bind:visible-change="onVisibleChange" placement="center">
  207. <view class="popup-container">
  208. <view class="popup-block">
  209. <scroll-view class="scroll_live" scroll-y="{{true}}" show-scrollbar="{{false}}" enhanced="{{true}}" animation="{{animationData}}">
  210. <view class="popup-item" wx:for="{{popupList}}" wx:key="{{id}}">
  211. <text class="popup-text">{{index+1}}.{{item.title}}</text>
  212. <text class="popup-action" bind:tap="goComplete" data-page="{{item.page}}" data-id="{{item.pendingWorkId}}" data-title="{{item.title}}">{{item.button}}</text>
  213. </view>
  214. </scroll-view>
  215. </view>
  216. <t-icon t-class="close-btn" name="close-circle" size="64rpx" color="#fff" bind:tap="onClose" />
  217. </view>
  218. </t-popup>
  219. </draggable-sheet>