watchIndex.vue 39 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428
  1. <template>
  2. <view class="watch-con">
  3. <view class="userbox">
  4. <image class="home_top_bg" src="@/static/images/pages_watch/images/home_top_bg.png" mode="widthFix"></image>
  5. <view class="user">
  6. <view class="user-navbox">
  7. <scroll-view class="tab-bar" :scroll-x="true" :show-scrollbar="false"
  8. :scroll-into-view="scrollInto">
  9. <view :class="selectUser == index ? 'user-navitem user-navitem-active':'user-navitem'" :id="'tab'+index"
  10. v-for="(item,index) in userList" :key="index" @click="handleUser(index)">
  11. <view>{{item.name}}</view>
  12. <view class="user-navbox-line" :style="{display: selectUser == index ? 'flex':'none'}">
  13. <image src="@/static/images/pages_watch/icons/tag_icon.png" mode="aspectFill"></image>
  14. </view>
  15. </view>
  16. </scroll-view>
  17. </view>
  18. <view class="user-family" @click="navigateToUrl('/pages_watch/index/myfamily/index')">
  19. <image src="@/static/images/pages_watch/icons/my_family_icon.png" mode="aspectFill"></image>
  20. <view>我的家人</view>
  21. </view>
  22. </view>
  23. </view>
  24. <mescroll-body ref="mescrollRef" @init="mescrollInit" top="0" bottom="0" :down="downOption" :up="upOption" @down="downCallback">
  25. <view class="watch-con-body">
  26. <!-- banner -->
  27. <swiper v-if="userList[selectUser] && userList[selectUser].deviceId && userList[selectUser].deviceId.length > 0" style="height: 350rpx;padding: 0 12rpx;box-sizing: border-box;"
  28. :current="activeTab" :duration="300" :previous-margin="userDeviceList.length > 0 &&activeTab == userDeviceList.length ? '92rpx':'0'" :next-margin="activeTab == userDeviceList.length ? '0':'92rpx'" @change="onSwiperChange">
  29. <swiper-item class="swiper-item" v-for="(item,index) in userDeviceList" :key="index">
  30. <view class="bindbox-banner" :style="{height: activeTab == index ?'308rpx':'260rpx'}">
  31. <view class="bindbox-head">
  32. <image class="bindbox-img" src="@/static/images/pages_watch/images/watch_icon.png" mode="aspectFill"></image>
  33. <view class="bindbox-headr" @tap="navigateToUrl('/pages_watch/index/targetInfo?selectUser='+selectUser+'&selectUserInfo='+ JSON.stringify(userList[selectUser]))">
  34. <view>
  35. <view class="bindbox-title textOne" v-show="selectUser == 0">
  36. {{item.user && item.user.nickName ? item.user.nickName : defaultName || '--' }}
  37. </view>
  38. <view class="bindbox-title textOne" v-show="selectUser != 0">
  39. {{userList[selectUser].name}}
  40. </view>
  41. <view>点击查看佩戴者信息</view>
  42. </view>
  43. <image src="@/static/images/pages_watch/icons/edit_white_arrow_right_icon.png"></image>
  44. </view>
  45. </view>
  46. <view class="bindbox-info">
  47. <view class="bindbox-info-l">
  48. <view class="bindbox-info-name">
  49. <view>手表</view>
  50. <view class="bindbox-info-desc">{{item.ble || '--'}}</view>
  51. </view>
  52. <view class="bindbox-info-status">
  53. <view>状态</view>
  54. <!-- 0-OFFLINE 1-ONLINE 2-UNACTIVE 3-DISABLE 4-NOT EXIST -->
  55. <view class="bindbox-info-desc">
  56. {{item.status == 1 ? '在线' : '离线'}}
  57. <navigator url="/pages_watch/index/equipment/offlineReason" hover-class="none" style="display: inherit;">
  58. <image class="question_mark_icon" src="@/static/images/pages_watch/icons/question_mark_icon.png" mode="aspectFill"></image>
  59. </navigator>
  60. </view>
  61. </view>
  62. </view>
  63. <view style="flex-shrink: 0;margin-left: 30rpx;">
  64. <view class="status_btn demonstrate_btn" style="margin-bottom: 20rpx;width: 192rpx;" @click="handleGuide">操作视频<image src="@/static/images/pages_watch/icons/edit_white_arrow_right_icon.png"></image>
  65. </view>
  66. <view class="bindbox-info-r" @tap="navigateToUrl('/pages_watch/index/equipment/index?selectUser='+selectUser)">
  67. 设备管理
  68. <image src="@/static/images/pages_watch/icons/arrow_right_orange_icon.png"></image>
  69. </view>
  70. </view>
  71. </view>
  72. </view>
  73. </swiper-item>
  74. <swiper-item class="swiper-item">
  75. <view class="add-device" :style="{height: activeTab == userDeviceList.length ?'308rpx':'260rpx', width:activeTab == userDeviceList.length ?'308rpx':'260rpx'}" @click="handleBind">
  76. <view class="add-device-icon">
  77. <image src="@/static/images/pages_watch/icons/add_watch_icon.png" mode="aspectFill"></image>
  78. </view>
  79. <text>添加手表</text>
  80. </view>
  81. </swiper-item>
  82. </swiper>
  83. <view class="banner" v-else>
  84. <image class="banner_bg" src="@/static/images/pages_watch/images/gold_circle_bg.png" mode="heightFix"></image>
  85. <image class="banner_bg_watch" src="@/static/images/pages_watch/images/watch_img.png" mode="heightFix"></image>
  86. <view style="position: relative;z-index: 1;">
  87. <view class="status_text">未绑定</view>
  88. <view class="status_desc">还没绑定健康手表,扫描 手表二维码去绑定</view>
  89. <view class="status_btnbox">
  90. <button class="status_btn binding_btn" :loading="btnLoading" :disabled="btnLoading" @click="handleBind">
  91. {{btnLoading ? "绑定中...":"立即绑定"}}
  92. <image v-show="!btnLoading" src="@/static/images/pages_watch/icons/arrow_right_orange_icon.png"></image>
  93. </button>
  94. <view class="status_btn demonstrate_btn" @click="handleGuide">操作视频<image src="@/static/images/pages_watch/icons/edit_white_arrow_right_icon.png"></image>
  95. </view>
  96. </view>
  97. </view>
  98. </view>
  99. <view style="padding: 0 24rpx;">
  100. <!-- 健康风险 -->
  101. <view class="health-risks">
  102. <view class="health-risks-title">
  103. <view class="health-risks-titlel"><text>健康</text>风险</view>
  104. <navigator url="/pages_watch/message/detail?title=手表通知" hover-class="none" class="health-risks-titler" >
  105. <text>更多提醒</text>
  106. <text class="health-risks-msgnum" v-show="alarmTotal > 0">{{alarmTotal}}</text>
  107. <image src="@/static/images/pages_watch/icons/arrow_right_icon.png"></image>
  108. </navigator>
  109. </view>
  110. <view class="health-risks-msg">
  111. <view class="health-risks-msgitem" v-for="(item,index) in alarmInfoList" :key="index">
  112. <view class="textOne health-risks-msgtxt">{{item.description}}</view>
  113. <view class="health-risks-msgbtn" @tap="navigateToUrl('/pages_watch/message/detail?title=手表通知')">{{item.type == "event"? '去就医':"去查看"}}</view>
  114. </view>
  115. </view>
  116. </view>
  117. <view class="navbox">
  118. <view class="tongue-diagnosis" @tap="navigateToUrl('/pages/user/healthRecords/index','健康档案')">
  119. <view>
  120. <view class="tongue-diagnosis-title">健康档案</view>
  121. <view>为您精准诊断</view>
  122. </view>
  123. <image src="@/static/images/pages_watch/icons/jkda.png" mode="aspectFill"></image>
  124. </view>
  125. <!-- <view class="health-report" @tap="navigateToUrl('/pages_watch/health/healthReport?selectUser='+selectUser,'健康报告')">
  126. <view>
  127. <view class="health-report-title">健康报告</view>
  128. <view>分析健康状态</view>
  129. </view>
  130. <image src="@/static/images/pages_watch/icons/health_report_icon.png" mode="aspectFill"></image>
  131. </view> -->
  132. <view class="health-report" @tap="navigateToUrl('/pages_watch/health/healthWeekReport?selectUser='+selectUser,'健康周报')">
  133. <view>
  134. <view class="health-report-title">健康周报</view>
  135. <view>分析健康状态</view>
  136. </view>
  137. <image src="@/static/images/pages_watch/icons/health_report_icon.png" mode="aspectFill"></image>
  138. </view>
  139. </view>
  140. <!-- 健康检测 -->
  141. <view class="box-title">
  142. <text class="box-title-left">健康监测</text>
  143. <view class="box-title-right">
  144. <view class="box-title-rightedit" @tap="navigateToUrl('/pages_watch/healthMonitoring/index')">
  145. <image src="@/static/images/pages_watch/icons/edit_add_icon.png"></image>
  146. <text>编辑卡片</text>
  147. </view>
  148. </view>
  149. </view>
  150. <sports ref='sports' v-if="showSports"></sports>
  151. <view class="health-monitoring">
  152. <view class="health-monitoring-item" v-for="(item,index) in indexInfo" :key="index"
  153. @tap="handleMonitoring(item)">
  154. <view class="health-monitoring-title">
  155. <view>
  156. <view class="health-monitoring-maintitle">{{item.type.type}}</view>
  157. <view>{{item.type.title}}</view>
  158. </view>
  159. <image :src="item.type.icon" mode="aspectFill"></image>
  160. </view>
  161. <view class="health-monitoring-res resnum">{{item.data || '--'}}</view>
  162. <view class="health-monitoring-time">{{item.date && item.date.substring(5,16)}}</view>
  163. </view>
  164. </view>
  165. </view>
  166. </view>
  167. </mescroll-body>
  168. </view>
  169. </template>
  170. <script>
  171. import sports from "@/pages_watch/components/sports/sports.vue";
  172. import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
  173. import mescrollBody from "@/uni_modules/mescroll-uni/components/mescroll-body/mescroll-body.vue";
  174. import permision from "@/utils/permission.js";
  175. import { getWatchUserInfo,getStatus,editUser,editMyfamily,editDevice } from "@/api/pages_watch/user.js";
  176. import { alarmInfo, queryIndexWatchData,getBatchData,getInfoByDeviceIds } from "@/api/pages_watch/index.js";
  177. import { getAppVersion } from '@/api/pages_watch/common.js';
  178. // import { appCheckUdate,openDownload } from '@/utils/APPUpdate.js'
  179. const avatar="/static/images/pages_watch/images/my_heads_icon.png";
  180. export default {
  181. mixins: [MescrollMixin], // 使用mixin
  182. components: {
  183. mescrollBody,
  184. sports
  185. },
  186. data() {
  187. return {
  188. avatar,
  189. mescroll: null,
  190. downOption: { //下拉刷新
  191. auto: false // 不自动加载 (mixin已处理第一个tab触发downCallback)
  192. },
  193. upOption: { //上拉加载
  194. auto: false, // 不自动加载
  195. page: {
  196. num: 0, // 当前页码,默认0,回调之前会加1,即callback(page)会从1开始
  197. size: 10 // 每页数据的数量
  198. },
  199. noMoreSize: 5, //如果列表已无数据,可设置列表的总数量要大于半页才显示无更多数据;避免列表数据过少(比如只有一条数据),显示无更多数据会不好看; 默认5
  200. empty: {
  201. tip: '~ 暂无疗法 ~' // 提示
  202. // btnText: '去看看'
  203. },
  204. use:false
  205. },
  206. userboxWidth: "",
  207. scrollInto: "tab0",
  208. activeTab: 0,
  209. userDeviceList: [],
  210. // 当前的设备编号
  211. deviceId: uni.getStorageSync("deviceId"),
  212. // 当前登录用户的信息
  213. userInfo: {},
  214. // 所有家庭成员(包括自己)
  215. userList: [{
  216. name: "自己",
  217. deviceId: [],
  218. relationship: ""
  219. }],
  220. // 选中的家庭成员
  221. selectUser: 0,
  222. // 立即绑定按钮loading
  223. btnLoading: false,
  224. // 健康风险
  225. alarmInfoList: [],
  226. // 健康风险未读提醒
  227. alarmTotal: 0,
  228. // 健康监测信息
  229. indexInfo: [
  230. {
  231. data: "",
  232. date: "",
  233. type: {
  234. type: "血糖",
  235. title: "血糖健康监测",
  236. icon: "/static/images/pages_watch/icons/blood_sugar_icon.png"
  237. }
  238. }
  239. ,{
  240. data: "",
  241. date: "",
  242. type: {
  243. type: "血压",
  244. title: "血压健康监测",
  245. icon:"/static/images/pages_watch/icons/blood_pressure_icon.png"
  246. }
  247. },{
  248. data: "",
  249. date: "",
  250. type: {
  251. type: "心率",
  252. title: "心脏健康管理",
  253. icon:"/static/images/pages_watch/icons/heart_rate_icon.png"
  254. }
  255. },{
  256. data: "",
  257. date: "",
  258. type: {
  259. type: "血氧",
  260. title: "血氧风险管控",
  261. icon:"/static/images/pages_watch/icons/blood_oxygen_icon.png"
  262. }
  263. },{
  264. data: "",
  265. date: "",
  266. type: {
  267. type: "体温",
  268. title: "体温健康监测",
  269. icon:"/static/images/pages_watch/icons/temperature_icon.png"
  270. }
  271. },{
  272. data: "",
  273. date: "",
  274. type: {
  275. type: "血脂",
  276. title: "血脂健康监测",
  277. icon:"/static/images/pages_watch/icons/blood_fat_icon.png"
  278. }
  279. },{
  280. data: "",
  281. date: "",
  282. type: {
  283. type: "尿酸",
  284. title: "尿酸健康监测",
  285. icon:"/static/images/pages_watch/icons/uric_acid_icon.png"
  286. }
  287. },
  288. // {
  289. // data: "",
  290. // date: "",
  291. // type: {
  292. // type: "血酮",
  293. // title: "血酮健康监测",
  294. // icon:"/static/images/pages_watch/icons/blood_ketone_icon.png"
  295. // }
  296. // },
  297. {
  298. data: "",
  299. date: "",
  300. type: {
  301. type: "睡眠",
  302. title: "睡眠健康监测",
  303. icon:"/static/images/pages_watch/icons/sleep_icon.png"
  304. }
  305. },
  306. ],
  307. isForce:false,
  308. showSports: false,
  309. defaultName: ''
  310. }
  311. },
  312. watch: {
  313. deviceId: {
  314. handler(oldVal,newVal) {
  315. this.getAlarmInfo()
  316. if(this.$refs.sports) {
  317. const isFamily = this.selectUser != 0
  318. this.$refs.sports.getServerData(isFamily)
  319. }
  320. },
  321. immediate: true
  322. }
  323. },
  324. created() {
  325. //#ifndef H5 || APP-PLUS
  326. this.userboxWidth = `width:${uni.getStorageSync('menuInfo').menuLeft}`
  327. //#endif
  328. uni.$on('getScanCodeInfo',(data)=>{
  329. const deviceId = data.imei || ""
  330. this.verifyDeviceId(data,deviceId)
  331. })
  332. },
  333. beforeDestroy() {
  334. uni.$off("getScanCodeInfo")
  335. },
  336. methods: {
  337. initReady() {
  338. },
  339. initShow() {
  340. this.showSports = true
  341. if (this.$isLogin()) {
  342. const acindex = this.userDeviceList.length > 0 && this.userDeviceList.length == this.activeTab ? this.userDeviceList.length - 1 : this.activeTab
  343. this.activeTab = acindex
  344. const user = uni.getStorageSync('userInfo') ? JSON.parse(uni.getStorageSync('userInfo')): {}
  345. this.defaultName = user.nickName
  346. this.getUser()
  347. this.getAlarmInfo()
  348. this.$nextTick(()=>{
  349. const isFamily = this.selectUser != 0
  350. this.$refs.sports.getServerData(isFamily)
  351. })
  352. } else {
  353. setTimeout(()=>{
  354. this.mescroll.endSuccess();
  355. }, 500)
  356. }
  357. // #ifdef APP-PLUS
  358. // this.checkUpdateApp();
  359. // #endif
  360. },
  361. mescrollInit(mescroll) {
  362. this.mescroll = mescroll;
  363. },
  364. /*下拉刷新的回调 */
  365. downCallback(mescroll) {
  366. this.initShow()
  367. },
  368. onChangeSubnav(e) {
  369. this.$emit("onChangeSubnav",e)
  370. },
  371. handleGuide() {
  372. uni.navigateTo({
  373. url: "/pages_watch/index/equipment/instructions"
  374. })
  375. },
  376. // swiper划动
  377. onSwiperChange(e) {
  378. this.activeTab = e.detail.current
  379. const acindex = this.userDeviceList.length > 0 && this.userDeviceList.length == this.activeTab ? this.userDeviceList.length - 1 : this.activeTab
  380. this.deviceId = this.userList[this.selectUser].deviceId[acindex] || ""
  381. uni.setStorageSync("deviceId",this.deviceId)
  382. // 所有成员的健康监测卡片展示类别一致
  383. this.getIndexInfo(this.userInfo.monitorDataTypeOrder)
  384. if(this.$refs.sports) {
  385. const isFamily = this.selectUser != 0
  386. this.$refs.sports.getServerData(isFamily)
  387. }
  388. },
  389. getUser() {
  390. getWatchUserInfo({isFamily: false}).then(res => {
  391. setTimeout(()=>{
  392. this.mescroll.endSuccess();
  393. }, 500)
  394. if (res.code == 200) {
  395. this.userInfo = res.user
  396. uni.setStorageSync("userWatchInfo", JSON.stringify(res.user))
  397. let otherDevice = this.userInfo.otherDevice ? JSON.parse(this.userInfo.otherDevice) : []
  398. otherDevice = otherDevice.map(item=>({
  399. ...item,
  400. deviceId: item.deviceId ? item.deviceId.split(',') : []
  401. }))
  402. const arry = [{
  403. name: "自己",
  404. deviceId: this.userInfo.deviceId || [],
  405. relationship: ""
  406. }]
  407. this.userList = arry.concat(otherDevice)
  408. if(this.$isEmpty(this.userList[this.selectUser])) {
  409. // 用户删除家人后没有选中的信息就选中第一个
  410. this.selectUser = 0
  411. this.activeTab = 0
  412. }
  413. this.deviceId = this.userList[this.selectUser].deviceId&&this.userList[this.selectUser].deviceId.length > 0 ? this.userList[this.selectUser].deviceId[this.activeTab] : ''
  414. uni.setStorageSync("deviceId",this.deviceId)
  415. this.getInfoByDeviceIds()
  416. this.getIndexInfo(this.userInfo.monitorDataTypeOrder)
  417. }
  418. }).catch(()=>{
  419. setTimeout(()=>{
  420. this.mescroll.endSuccess();
  421. }, 500)
  422. })
  423. },
  424. // 首页轮播绑定信息
  425. getInfoByDeviceIds() {
  426. let ids = this.userList[this.selectUser].deviceId
  427. if(ids&&ids.length> 0) {
  428. const param = {
  429. deviceIds: ids.join(','),
  430. isFamily: this.selectUser != 0
  431. }
  432. getInfoByDeviceIds(param).then(res=>{
  433. if(res.code == 200) {
  434. this.userDeviceList = res.data && res.data.length > 0 ? res.data : []
  435. }
  436. })
  437. } else {
  438. this.userDeviceList = []
  439. }
  440. },
  441. // 绑定
  442. async handleBind() {
  443. if (!this.$isLogin()) {
  444. this.$showLoginPage()
  445. } else {
  446. // #ifdef APP-PLUS
  447. if(!plus.runtime.isAgreePrivacy()) {
  448. uni.showToast({title: "请同意隐私政策",icon: "none"});
  449. return;
  450. }
  451. let status = await this.checkAppCamera()
  452. if(status == 1) {
  453. uni.navigateTo({
  454. url: '/pages_watch/healthMonitoring/scanCode?typeFun=getScanCodeInfo'
  455. })
  456. }
  457. // #endif
  458. // #ifdef MP-WEIXIN
  459. this.checkWXCamera()
  460. // #endif
  461. }
  462. },
  463. scanQRCode() {
  464. uni.scanCode({
  465. success(res) {
  466. if (res.result) {
  467. // 扫描成功,处理二维码内容
  468. console.log('扫描结果:', res.scanType,res.result);
  469. const scanInfo = JSON.parse(res.result)
  470. const deviceId = scanInfo.dev_info.imei || ""
  471. this.verifyDeviceId(scanInfo.dev_info,deviceId)
  472. } else {
  473. // 扫描失败
  474. uni.showToast({
  475. title: '扫描失败',
  476. icon: 'none'
  477. });
  478. }
  479. },
  480. fail() {}
  481. });
  482. },
  483. // 验证设备
  484. verifyDeviceId(scanInfo,deviceId) {
  485. // index,0表示自己,如果是自己绑定直接调用修改用户信息接口
  486. this.btnLoading = true
  487. if(this.selectUser == 0) {
  488. editDevice(scanInfo).then(res=>{
  489. this.btnLoading = false
  490. if(res.code == 200) {
  491. uni.showToast({
  492. title: res.msg,
  493. icon: "none",
  494. position: 'top',
  495. duration: 2000
  496. })
  497. this.getUser()
  498. } else {
  499. uni.showToast({
  500. title: res.msg,
  501. icon: "none",
  502. position: 'top',
  503. duration: 2000
  504. })
  505. }
  506. }).catch(err=>{
  507. this.btnLoading = false
  508. })
  509. } else {
  510. this.bindDeviceId(deviceId)
  511. // getStatus({deviceId: deviceId}).then(res=>{
  512. // if(res.code == 200) {
  513. // if(res.data === 0 || res.data === 1 || res.data === 2 || res.data === 3) {
  514. // this.bindDeviceId(deviceId)
  515. // } else {
  516. // this.btnLoading = false
  517. // uni.showToast({
  518. // title: '绑定失败',
  519. // icon: "none",
  520. // position: 'top',
  521. // duration: 2000
  522. // })
  523. // }
  524. // }else {
  525. // this.btnLoading = false
  526. // uni.showToast({
  527. // title: res.msg,
  528. // icon: "none",
  529. // position: 'top',
  530. // duration: 2000
  531. // })
  532. // }
  533. // }).catch(err=>{
  534. // this.btnLoading = false
  535. // })
  536. }
  537. },
  538. // 绑定设备
  539. bindDeviceId(deviceId) {
  540. let param = this.userList.map((item,idx)=>({
  541. ...item,
  542. deviceId: idx == this.selectUser && !item.deviceId.includes(deviceId) ? item.deviceId.concat([deviceId]).join(','): item.deviceId.join(',')
  543. }))
  544. // 去掉自己
  545. param.splice(0,1)
  546. editMyfamily({otherDevice: JSON.stringify(param)}).then(res=>{
  547. this.btnLoading = false
  548. if(res.code == 200) {
  549. uni.showToast({
  550. title: "绑定成功",
  551. icon: "none",
  552. position: 'top',
  553. duration: 2000
  554. })
  555. this.getUser()
  556. } else {
  557. uni.showToast({
  558. title: res.msg,
  559. icon: "none",
  560. position: 'top',
  561. duration: 2000
  562. })
  563. }
  564. }).catch(err => {
  565. this.btnLoading = false
  566. console.log('err', err);
  567. })
  568. },
  569. // 切换绑定的成员信息
  570. handleUser(index) {
  571. this.selectUser = index
  572. this.activeTab = 0
  573. this.scrollInto = 'tab' + index
  574. this.deviceId = this.userList[index].deviceId[this.activeTab] || ""
  575. uni.setStorageSync("deviceId",this.deviceId)
  576. this.getInfoByDeviceIds()
  577. // 所有成员的健康监测卡片展示类别一致
  578. this.getIndexInfo(this.userInfo.monitorDataTypeOrder)
  579. },
  580. navigateToUrl(url,title) {
  581. if (this.$isLogin()) {
  582. if((title == "健康报告" || title == "健康周报") && !this.deviceId) {
  583. uni.showToast({
  584. title: "请先绑定设备",
  585. icon: "none"
  586. })
  587. return
  588. }
  589. uni.navigateTo({
  590. url: url
  591. })
  592. } else {
  593. this.$showLoginPage()
  594. }
  595. },
  596. // 健康风险预警信息
  597. getAlarmInfo() {
  598. if(!this.deviceId) {
  599. this.alarmInfoList = []
  600. this.alarmTotal = 0
  601. return
  602. }
  603. const param = {
  604. deviceId: this.deviceId,
  605. pageNum: 1,
  606. pageSize: 3,
  607. }
  608. alarmInfo(param).then((res) => {
  609. if (res.code == 200) {
  610. this.alarmInfoList = res.rows
  611. this.alarmTotal = res.unreadNum
  612. }
  613. }).catch((err) => {});
  614. },
  615. // 健康监测信息
  616. getIndexInfo(monitorDataTypeOrder) {
  617. if(!this.deviceId) {
  618. getBatchData({ids: monitorDataTypeOrder}).then(res => {
  619. if (res.code == 200) {
  620. this.indexInfo = res.data.map(item=>({
  621. data: "",
  622. date: "",
  623. type: item
  624. }))
  625. }
  626. }).catch((err) => {});
  627. } else {
  628. const param = {
  629. deviceId: this.deviceId,
  630. type: monitorDataTypeOrder
  631. }
  632. queryIndexWatchData(param).then(res => {
  633. if (res.code == 200) {
  634. this.indexInfo = res.data
  635. }
  636. }).catch((err) => {});
  637. }
  638. },
  639. handleMonitoring(item) {
  640. if (this.$isLogin()) {
  641. if(!this.deviceId) {
  642. uni.showToast({
  643. title: "请先绑定设备",
  644. icon: "none"
  645. })
  646. return
  647. }
  648. let url = ""
  649. switch (item.type.type) {
  650. case "血糖":
  651. url = "/pages_watch/healthMonitoring/bloodSugar"
  652. break;
  653. case "血压":
  654. url = "/pages_watch/healthMonitoring/bloodPressure"
  655. break;
  656. case "心率":
  657. url = "/pages_watch/healthMonitoring/heartRate"
  658. break;
  659. case "血氧":
  660. url = "/pages_watch/healthMonitoring/bloodOxygen"
  661. break;
  662. case "睡眠":
  663. url = "/pages_watch/healthMonitoring/sleep"
  664. break;
  665. case "舌诊":
  666. url = "/pages/user/tongue/tongueList"
  667. break;
  668. case "体温":
  669. url = "/pages_watch/healthMonitoring/bodyTemperature"
  670. break;
  671. case "尿酸":
  672. url = "/pages_watch/healthMonitoring/uricAcid"
  673. break;
  674. case "压力":
  675. url = "/pages_watch/healthMonitoring/pressure"
  676. break;
  677. default:
  678. url = ""
  679. break;
  680. }
  681. if (url) {
  682. uni.navigateTo({
  683. url: url
  684. })
  685. } else {
  686. uni.showToast({
  687. title: '功能开发中...',
  688. icon: 'none',
  689. position: 'top',
  690. duration: 2000
  691. })
  692. }
  693. } else {
  694. this.$showLoginPage()
  695. }
  696. },
  697. async checkAppCamera() {
  698. let status = permision.isIOS ? await permision.requestIOS("camera") : await permision.requestAndroid("android.permission.CAMERA")
  699. if(status === null || status == 1) {
  700. status == 1
  701. } else if(status == 2) {
  702. uni.showModal({
  703. content: "相机权限已关闭",
  704. showCancel: false,
  705. success: () => {}
  706. })
  707. } else if(status.code) {
  708. uni.showModal({
  709. content: status.message
  710. })
  711. } else {
  712. uni.showModal({
  713. content: "为了使用相机功能,请点击设置开启相机权限",
  714. confirmText: "设置",
  715. success: (res) => {
  716. if(res.confirm) {
  717. permision.gotoAppSetting()
  718. }
  719. }
  720. })
  721. }
  722. return status
  723. },
  724. checkWXCamera() {
  725. const that = this
  726. uni.getSetting({
  727. success(res) {
  728. // 判断是否拥有此权限进行拉起授权 和 重新授权功能
  729. if (!res.authSetting['scope.camera']) {
  730. // 未授权此项权限 拉起授界面
  731. uni.authorize({
  732. scope: 'scope.camera',
  733. success() {
  734. // 授权成功后 就可以执行 需要权限的 操作函数了
  735. // 使用已授权的功能
  736. that.scanQRCode();
  737. },
  738. fail(err) {
  739. /*
  740. 第一次拒绝授权后必须在 uni.authorize的fail中使用
  741. uni.openSetting 才能进入设置界面打开授权按钮
  742. */
  743. uni.showToast({
  744. title: '您拒绝了授权',
  745. icon: 'none'
  746. });
  747. // 这里必须经过一个confirm 不然也会出现问题(啥问题我也不知道)
  748. uni.showModal({
  749. title: '是否重新授权相机功能',
  750. success(res) {
  751. if (res.confirm) {
  752. uni.openSetting({
  753. success() {
  754. console.log('开启权限成功');
  755. },
  756. fail() {
  757. console.log('开启权限失败');
  758. }
  759. });
  760. } else if (res.cancel) {
  761. console.log('拒绝开启开启权限');
  762. }
  763. }
  764. });
  765. }
  766. });
  767. } else {
  768. that.scanQRCode()
  769. }
  770. }
  771. });
  772. },
  773. /* 检查更新 在线更新 */
  774. checkUpdateApp:function(){
  775. // 获取manifest.json里的配置信息
  776. if(this.isForce){
  777. return;
  778. }
  779. let that=this;
  780. this.isForce=true;
  781. plus.runtime.getProperty(plus.runtime.appid, function(widgetinfo) {
  782. // console.log("App widgetinfo:"+JSON.stringify(widgetinfo));
  783. // 可以根据manifest.json里的应用名称来进行针对性的APP升级
  784. // if (widgetinfo.name == that.$qconfig.appName) { //APP名称
  785. // 获取manifest.json里的版本号
  786. let platform = uni.getSystemInfoSync().platform;
  787. let isAndroid=platform=="android";
  788. let type=isAndroid?1:2;
  789. getAppVersion(type).then(srcData => {
  790. this.isForce=false;
  791. if(srcData.code==200){
  792. let data = srcData.data;
  793. let version = widgetinfo.versionCode,//用户当前版本
  794. appVersion = data.versionCode,//升级包版本
  795. appName = widgetinfo.name, //app名称
  796. updata = data.isForce,//是否强制热更新
  797. appurl = data.url,//升级包地址
  798. intro = data.note;//升级包提示
  799. //如果用户版本号小于升级包版本号,先升级
  800. let afterVer=that.$qconfig.isAppStore?data.appStoreUpdate:true;
  801. // let afterVer= true;
  802. if(data && (version < appVersion) && afterVer){
  803. uni.showModal({
  804. title:"更新提示",
  805. confirmText:"立即升级",
  806. content:intro,
  807. cancelText:'确定',
  808. confirmText:'取消',
  809. success: (res) => {
  810. if (res.cancel) {
  811. openDownload(srcData.data);
  812. } else if (res.confirm) {
  813. if(updata==1){
  814. console.log('用户点击取消');
  815. uni.showToast({
  816. title:"请先升级APP版本",
  817. icon:"none",
  818. duration:2000
  819. })
  820. //退出app
  821. setTimeout(function(){
  822. plus.runtime.quit();
  823. },2000)
  824. }
  825. }
  826. },
  827. fail: () => {
  828. uni.hideLoading();
  829. }
  830. })
  831. }
  832. }
  833. },
  834. rej => {}
  835. ).catch(()=>{
  836. //联网失败, 结束加载
  837. // this.mescroll.endErr();
  838. });
  839. // }
  840. });
  841. },
  842. }
  843. }
  844. </script>
  845. <style lang="scss" scoped>
  846. @mixin u-flex($flexD, $alignI, $justifyC) {
  847. display: flex;
  848. flex-direction: $flexD;
  849. align-items: $alignI;
  850. justify-content: $justifyC;
  851. }
  852. .indexSubsection {
  853. height: 88rpx;
  854. display: flex;
  855. align-items: center;
  856. justify-content: center;
  857. }
  858. .watch-con {
  859. padding-top: calc(var(--status-bar-height) + 44px + 88rpx);
  860. padding-bottom: var(--window-bottom);
  861. min-height: 100vh;
  862. box-sizing: border-box;
  863. background: linear-gradient(180deg, #FDF0DA 0%, #FDF4EB 75%, #F5F7FA 100%) no-repeat;
  864. background-size: 100% 504rpx;
  865. color: #222222;
  866. &-body {
  867. padding: 0 0 32rpx 0;
  868. }
  869. .userbox {
  870. width: 100%;
  871. overflow: hidden;
  872. position: fixed;
  873. z-index: 9999;
  874. left: 0;
  875. top: calc(var(--status-bar-height) + 44px);
  876. .home_top_bg {
  877. width: 100%;
  878. position: absolute !important;
  879. left: 0;
  880. top: -44px;
  881. z-index: 0;
  882. }
  883. }
  884. .tab-bar {
  885. width: 100%;
  886. flex-direction: row;
  887. white-space: nowrap;
  888. }
  889. .user {
  890. width: 100%;
  891. height: 88rpx;
  892. padding: 0 24rpx;
  893. box-sizing: border-box;
  894. @include u-flex(row, center, space-between);
  895. font-family: PingFang SC, PingFang SC;
  896. font-weight: 500;
  897. color: #222222;
  898. overflow: hidden;
  899. position: relative;
  900. &-navbox {
  901. flex: 1;
  902. margin-right: 20rpx;
  903. overflow: hidden;
  904. @include u-flex(row, center, flex-start);
  905. font-size: 32rpx;
  906. &-line {
  907. display: inherit;
  908. margin-top: 16rpx;
  909. image {
  910. width: 40rpx;
  911. height: 12rpx;
  912. }
  913. }
  914. }
  915. &-navitem {
  916. min-width: 90rpx;
  917. padding: 0 20rpx;
  918. box-sizing: border-box;
  919. text-align: center;
  920. @include u-flex(column, center, center);
  921. display: inline-flex;
  922. flex-wrap: nowrap;
  923. &-active {
  924. font-size: 40rpx;
  925. color: #FF7700;
  926. }
  927. }
  928. &-family {
  929. flex-shrink: 0;
  930. font-weight: 400;
  931. font-size: 20rpx;
  932. text-align: center;
  933. image {
  934. width: 32rpx;
  935. height: 32rpx;
  936. }
  937. }
  938. }
  939. .banner {
  940. height: 312rpx;
  941. padding: 32rpx;
  942. margin: 24rpx 24rpx 0 24rpx;
  943. overflow: hidden;
  944. background: linear-gradient(180deg, #FBA457 0%, #FE7040 100%);
  945. border-radius: 16rpx 16rpx 16rpx 16rpx;
  946. font-family: PingFang SC, PingFang SC;
  947. color: #FFFFFF;
  948. box-sizing: border-box;
  949. position: relative;
  950. .banner_bg {
  951. width: 414rpx;
  952. height: 312rpx;
  953. position: absolute !important;
  954. right: 0;
  955. top: 0;
  956. }
  957. .banner_bg_watch {
  958. width: 264rpx;
  959. height: 307rpx;
  960. position: absolute !important;
  961. right: 0;
  962. top: 0;
  963. }
  964. .status_text {
  965. padding-left: 28rpx;
  966. line-height: 60rpx;
  967. font-weight: 600;
  968. font-size: 48rpx;
  969. position: relative;
  970. &::after {
  971. content: "";
  972. width: 8rpx;
  973. height: 40rpx;
  974. background: #FFFFFF;
  975. border-radius: 4rpx 4rpx 4rpx 4rpx;
  976. position: absolute;
  977. left: 0;
  978. top: 50%;
  979. transform: translateY(-50%);
  980. }
  981. }
  982. .status_desc {
  983. width: 264rpx;
  984. padding-top: 20rpx;
  985. padding-bottom: 24rpx;
  986. font-weight: 400;
  987. font-size: 24rpx;
  988. line-height: 36rpx;
  989. }
  990. .status_btnbox{
  991. @include u-flex(row, center, flex-start);
  992. }
  993. .binding_btn {
  994. background: #FFFFFF;
  995. color: #FF7700;
  996. margin-right: 16rpx !important;
  997. }
  998. }
  999. .status_btn {
  1000. width: 200rpx;
  1001. height: 64rpx;
  1002. line-height: 64rpx;
  1003. border-radius: 36rpx 36rpx 36rpx 36rpx;
  1004. @include u-flex(row, center, center);
  1005. display: inline-flex;
  1006. font-weight: 500;
  1007. font-size: 26rpx;
  1008. border: 2rpx solid #FFFFFF;
  1009. box-sizing: border-box;
  1010. margin: 0;
  1011. &::after {
  1012. border: none;
  1013. }
  1014. image {
  1015. width: 32rpx;
  1016. height: 32rpx;
  1017. }
  1018. }
  1019. .demonstrate_btn {
  1020. image {
  1021. width: 48rpx !important;
  1022. height: 48rpx !important;
  1023. }
  1024. }
  1025. .swiper-item {
  1026. padding: 0 12rpx;
  1027. box-sizing: border-box;
  1028. height: 350rpx;
  1029. @include u-flex(row, center, flex-start);
  1030. }
  1031. .bindbox{
  1032. &-banner{
  1033. width: 100%;
  1034. min-width: 624rpx;
  1035. padding: 0 24rpx;
  1036. box-sizing: border-box;
  1037. @include u-flex(column, inherit, center);
  1038. background: linear-gradient( 180deg, #FBA457 0%, #FE7040 100%);
  1039. box-shadow: 0rpx 0rpx 14rpx 6rpx rgba(236,115,69,0.2);
  1040. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1041. overflow: hidden;
  1042. font-family: PingFang SC, PingFang SC;
  1043. font-weight: 400;
  1044. font-size: 24rpx;
  1045. color: #FFFFFF;
  1046. }
  1047. &-head {
  1048. width: 100%;
  1049. @include u-flex(row, center, flex-start);
  1050. }
  1051. &-img {
  1052. flex-shrink: 0;
  1053. width: 88rpx;
  1054. height: 88rpx;
  1055. padding: 8rpx;
  1056. box-sizing: border-box;
  1057. margin-right: 20rpx;
  1058. background: #FEF2E0;
  1059. border-radius: 50%;
  1060. }
  1061. &-headr {
  1062. flex: 1;
  1063. @include u-flex(row, center, space-between);
  1064. overflow: hidden;
  1065. image {
  1066. width: 48rpx;
  1067. height: 48rpx;
  1068. }
  1069. }
  1070. &-title {
  1071. font-weight: 600;
  1072. font-size: 36rpx;
  1073. line-height: 60rpx;
  1074. }
  1075. &-info {
  1076. width: 100%;
  1077. margin-top: 46rpx;
  1078. @include u-flex(row, center, space-between);
  1079. .question_mark_icon {
  1080. width: 24rpx;
  1081. height: 24rpx;
  1082. margin-left: 10rpx;
  1083. }
  1084. }
  1085. &-info-l {
  1086. flex: 1;
  1087. @include u-flex(row, center, flex-start);
  1088. }
  1089. &-info-desc {
  1090. margin-top: 18rpx;
  1091. font-weight: 500;
  1092. font-size: 28rpx;
  1093. color: #FFFFFF;
  1094. @include u-flex(row, center, center);
  1095. }
  1096. &-info-name {
  1097. text-align: center;
  1098. padding-right: 30rpx;
  1099. border-right: 2rpx solid rgba(255,255,255,0.2);
  1100. }
  1101. &-info-status {
  1102. padding-left: 30rpx;
  1103. text-align: center;
  1104. }
  1105. &-info-r {
  1106. width: 192rpx;
  1107. height: 64rpx;
  1108. background: #FFFFFF;
  1109. border-radius: 32rpx 32rpx 32rpx 32rpx;
  1110. font-family: PingFang SC, PingFang SC;
  1111. font-weight: 500;
  1112. font-size: 26rpx;
  1113. color: #FF7700;
  1114. line-height: 64rpx;
  1115. text-align: center;
  1116. @include u-flex(row, center, center);
  1117. image {
  1118. height: 32rpx;
  1119. width: 32rpx;
  1120. }
  1121. }
  1122. }
  1123. .add-device {
  1124. width: 308rpx;
  1125. height: 308rpx;
  1126. background: #FFFFFF;
  1127. box-shadow: 0rpx 0rpx 14rpx 8rpx rgba(236,115,69,0.1);
  1128. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1129. @include u-flex(column, center, center);
  1130. font-family: PingFang SC, PingFang SC;
  1131. font-weight: 400;
  1132. font-size: 28rpx;
  1133. color: #757575;
  1134. .add-device-icon {
  1135. width: 144rpx;
  1136. height: 144rpx;
  1137. margin-bottom: 16rpx;
  1138. border-radius: 32rpx 32rpx 32rpx 32rpx;
  1139. border: 4rpx dashed #FF7700;
  1140. @include u-flex(column, center, center);
  1141. image {
  1142. width: 56rpx;
  1143. height: 56rpx;
  1144. }
  1145. }
  1146. }
  1147. .health-risks {
  1148. margin-top: 20rpx;
  1149. padding: 4rpx 16rpx 16rpx 16rpx;
  1150. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1151. box-sizing: border-box;
  1152. background: linear-gradient(180deg, #FFF1ED 0%, #FFFFFF 100%);
  1153. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1154. border: 2rpx solid;
  1155. border-image: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(255, 255, 255, 1)) 2 2;
  1156. &-title {
  1157. padding: 20rpx 12rpx;
  1158. @include u-flex(row, center, space-between);
  1159. font-weight: 400;
  1160. font-size: 24rpx;
  1161. color: #757575;
  1162. }
  1163. &-titlel {
  1164. font-weight: 600;
  1165. font-size: 32rpx;
  1166. color: #333333;
  1167. text {
  1168. color: #FF7700;
  1169. }
  1170. }
  1171. &-titler {
  1172. @include u-flex(row, center, flex-start);
  1173. image {
  1174. width: 32rpx;
  1175. height: 32rpx;
  1176. flex-shrink: 0;
  1177. }
  1178. }
  1179. &-msgnum {
  1180. min-width: 46rpx;
  1181. height: 28rpx;
  1182. padding: 0 12rpx;
  1183. line-height: 28rpx;
  1184. box-sizing: border-box;
  1185. background: linear-gradient(136deg, #EE7D4E 0%, #E86235 100%);
  1186. border-radius: 14rpx 14rpx 14rpx 14rpx;
  1187. font-weight: 400;
  1188. font-size: 20rpx;
  1189. color: #FFFFFF;
  1190. margin: 0 8rpx;
  1191. flex-shrink: 0;
  1192. text-align: center;
  1193. }
  1194. &-msg {
  1195. padding: 20rpx 16rpx 0 16rpx;
  1196. background: #FFFFFF;
  1197. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1198. color: #333333;
  1199. font-weight: 400;
  1200. font-size: 26rpx;
  1201. }
  1202. &-msgitem {
  1203. margin-bottom: 20rpx;
  1204. @include u-flex(row, center, space-between);
  1205. }
  1206. &-msgtxt {
  1207. line-height: 52rpx;
  1208. padding-left: 26rpx;
  1209. position: relative;
  1210. &::before {
  1211. content: "";
  1212. width: 8rpx;
  1213. height: 8rpx;
  1214. background: rgba(255, 119, 0, 0.5);
  1215. border-radius: 50%;
  1216. position: absolute;
  1217. left: 0;
  1218. top: 50%;
  1219. transform: translateY(-50%);
  1220. }
  1221. }
  1222. &-msgbtn {
  1223. min-width: 108rpx;
  1224. height: 48rpx;
  1225. padding: 0 24rpx;
  1226. margin-left: 50rpx;
  1227. box-sizing: border-box;
  1228. line-height: 48rpx;
  1229. background: #FCF0E7;
  1230. border-radius: 26rpx 26rpx 26rpx 26rpx;
  1231. flex-shrink: 0;
  1232. font-weight: 500;
  1233. font-size: 20rpx;
  1234. color: #FF7700;
  1235. }
  1236. }
  1237. .navbox {
  1238. @include u-flex(row, center, flex-start);
  1239. // gap: 16rpx;
  1240. margin-top: 20rpx;
  1241. .tongue-diagnosis {
  1242. flex: 1;
  1243. height: 160rpx;
  1244. margin-right: 16rpx;
  1245. background: linear-gradient(180deg, #FBE2B0 0%, #FFCA80 100%);
  1246. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1247. font-weight: 400;
  1248. font-size: 26rpx;
  1249. color: #D36208;
  1250. padding: 0 24rpx;
  1251. @include u-flex(row, center, space-between);
  1252. image {
  1253. width: 97rpx;
  1254. height: 96rpx;
  1255. }
  1256. &-title {
  1257. font-weight: 600;
  1258. font-size: 32rpx;
  1259. margin-bottom: 10rpx;
  1260. }
  1261. }
  1262. .health-report {
  1263. flex: 1;
  1264. height: 160rpx;
  1265. padding: 0 24rpx;
  1266. background: linear-gradient(180deg, #D6E3FF 0%, #95AFFF 100%);
  1267. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1268. font-weight: 400;
  1269. font-size: 26rpx;
  1270. color: #455FAD;
  1271. @include u-flex(row, center, space-between);
  1272. image {
  1273. width: 99rpx;
  1274. height: 105rpx;
  1275. }
  1276. &-title {
  1277. font-weight: 600;
  1278. font-size: 32rpx;
  1279. margin-bottom: 10rpx;
  1280. }
  1281. }
  1282. }
  1283. .box-title {
  1284. height: 80rpx;
  1285. margin-top: 20rpx;
  1286. line-height: 80rpx;
  1287. font-weight: 500;
  1288. font-size: 36rpx;
  1289. color: #222222;
  1290. @include u-flex(row, center, space-between);
  1291. &-right {
  1292. flex-shrink: 0;
  1293. }
  1294. .arrow_right_icon {
  1295. font-weight: 400;
  1296. font-size: 24rpx;
  1297. color: #757575;
  1298. @include u-flex(row, center, flex-start);
  1299. image {
  1300. height: 48rpx;
  1301. width: 48rpx;
  1302. }
  1303. }
  1304. &-rightedit {
  1305. min-width: 192rpx;
  1306. height: 64rpx;
  1307. padding: 0 32rpx;
  1308. box-sizing: border-box;
  1309. background: #FFFFFF;
  1310. border-radius: 32rpx 32rpx 32rpx 32rpx;
  1311. font-weight: 500;
  1312. font-size: 24rpx;
  1313. color: #757575;
  1314. @include u-flex(row, center, center);
  1315. image {
  1316. width: 24rpx;
  1317. height: 24rpx;
  1318. margin-right: 4rpx;
  1319. }
  1320. }
  1321. }
  1322. .health-monitoring {
  1323. @include u-flex(row, center, flex-start);
  1324. flex-wrap: wrap;
  1325. // gap: 16rpx;
  1326. margin-bottom: -16rpx;
  1327. margin-right: -16rpx;
  1328. &-item {
  1329. width: 343rpx;
  1330. min-height: 264rpx;
  1331. margin: 0 16rpx 16rpx 0;
  1332. overflow: hidden;
  1333. background: #FFFFFF;
  1334. border-radius: 16rpx 16rpx 16rpx 16rpx;
  1335. padding: 24rpx 34rpx 24rpx 24rpx;
  1336. box-sizing: border-box;
  1337. }
  1338. &-maintitle {
  1339. margin-bottom: 4rpx;
  1340. font-weight: 500;
  1341. font-size: 30rpx;
  1342. color: #333333;
  1343. }
  1344. &-title {
  1345. @include u-flex(row, center, space-between);
  1346. font-weight: 400;
  1347. font-size: 24rpx;
  1348. color: #999999;
  1349. image {
  1350. width: 72rpx;
  1351. height: 72rpx;
  1352. flex-shrink: 0;
  1353. }
  1354. }
  1355. .resnum {
  1356. font-family: DIN, DIN;
  1357. font-weight: 500;
  1358. font-size: 64rpx;
  1359. }
  1360. &-res {
  1361. height: 78rpx;
  1362. margin: 20rpx 0 6rpx;
  1363. font-family: PingFang SC, PingFang SC;
  1364. font-weight: 600;
  1365. font-size: 48rpx;
  1366. color: #333333;
  1367. }
  1368. &-time {
  1369. font-weight: 400;
  1370. font-size: 22rpx;
  1371. color: #999999;
  1372. }
  1373. }
  1374. }
  1375. </style>