index.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930
  1. <template>
  2. <view class="container">
  3. <view class="nav-bar">
  4. <view class="grace-page-header" :style="{ background:headerBG }">
  5. <!-- 沉浸式状态栏 -->
  6. <view class="grace-page-status-bar" :style="{background:statusBarBG}"></view>
  7. <view class="content-header" id="gracePageHeader" :style="{minHeight:headerHeight+'px', height:headerHeight+'px', overflow:'hidden'}">
  8. <view class="content-header-l">
  9. <!-- <image class="address" src="@/static/image/back.png" mode="aspectFill" @click="$navBack()"></image> -->
  10. </view>
  11. <view class="content-header-title">健康档案</view>
  12. <!-- <image class="shareicon" src="@/static/images/white-share.png" mode="aspectFill" @click="doShare"></image> -->
  13. </view>
  14. </view>
  15. <view class="nav_box">
  16. <view class="status_bar"></view>
  17. <view class="nav_bar"></view>
  18. </view>
  19. </view>
  20. <image class="jkda_top_bg" src="@/static/image/healthRecords/jkda_top_bg.png" mode="widthFix"></image>
  21. <view class="container-body">
  22. <view class="userbox">
  23. <view class="userbox-left">
  24. <view class="userbox-headimg">
  25. <image :src="defaultHeadimg" mode="aspectFill" style="width: 100%;height: 100%"></image>
  26. </view>
  27. <view class="userbox-info">
  28. <view>{{recordInfo.name || ""}}</view>
  29. <view class="userbox-info-tag">
  30. <view>{{recordInfo.sex == 1 ? '男':recordInfo.sex == 2 ? '女':'未知' }}</view>
  31. <view>{{recordInfo.age || "--"}}岁</view>
  32. </view>
  33. </view>
  34. </view>
  35. <!-- <view class="userbox-right">
  36. <image src="@/static/image/healthRecords/right_arrow_right_icon.png" mode="aspectFill"></image>
  37. </view> -->
  38. </view>
  39. <view class="box-title">
  40. <text>健康数据</text>
  41. <!-- <view class="box-title-right">
  42. <image src="@/static/image/healthRecords/edit_add_orange_icon.png" mode="aspectFill"></image>
  43. <text>绑定智能设备</text>
  44. </view> -->
  45. </view>
  46. <view class="cardbox">
  47. <view class="cardbox-item bmibox" style="height:auto">
  48. <view class="cardbox-title">
  49. <view>
  50. <view class="cardbox-maintitle">BMI {{recordInfo.bmi || "--"}}</view>
  51. <view class="bmibox-tagbox"><view class="bmibox-tag" v-if="recordInfo.bmi">{{fat}}</view></view>
  52. </view>
  53. <image src="@/static/image/healthRecords/BMI_icon.png" mode="aspectFill"></image>
  54. </view>
  55. <!-- <view class="bmibox-info" style="margin-top: 46rpx;">
  56. <text class="bmibox-infolabel">身高</text>
  57. <view class="bmibox-infoval">{{recordInfo.height || "--"}}cm</view>
  58. <image class="bmibox-edit" src="@/static/image/healthRecords/services_edit_icon.png"
  59. @click="handleEdit('height')"></image>
  60. </view>
  61. <view class="bmibox-info" style="margin-top: 12rpx;">
  62. <text class="bmibox-infolabel">体重</text>
  63. <view class="bmibox-infoval">{{recordInfo.weight || "--"}}kg</view>
  64. <image class="bmibox-edit" src="@/static/image/healthRecords/services_edit_icon.png"
  65. @click="handleEdit('weight')"></image>
  66. </view> -->
  67. </view>
  68. <view class="cardbox-item bmibox" style="height:auto">
  69. <!-- <view class="cardbox-title">
  70. <view>
  71. <view class="cardbox-maintitle">BMI {{recordInfo.bmi || "--"}}</view>
  72. <view class="bmibox-tagbox"><view class="bmibox-tag" v-if="recordInfo.bmi">{{fat}}</view></view>
  73. </view>
  74. <image src="@/static/image/healthRecords/BMI_icon.png" mode="aspectFill"></image>
  75. </view> -->
  76. <view class="bmibox-info">
  77. <text class="bmibox-infolabel">身高</text>
  78. <view class="bmibox-infoval">{{recordInfo.height || "--"}}cm</view>
  79. <image class="bmibox-edit" src="@/static/image/healthRecords/services_edit_icon.png"
  80. @click="handleEdit('height')"></image>
  81. </view>
  82. <view class="bmibox-info" style="margin-top: 12rpx;">
  83. <text class="bmibox-infolabel">体重</text>
  84. <view class="bmibox-infoval">{{recordInfo.weight || "--"}}kg</view>
  85. <image class="bmibox-edit" src="@/static/image/healthRecords/services_edit_icon.png"
  86. @click="handleEdit('weight')"></image>
  87. </view>
  88. </view>
  89. <!-- <view class="cardbox-item" v-for="(item,index) in healthData" :key="index">
  90. <view class="cardbox-title">
  91. <view>
  92. <view class="cardbox-maintitle">{{item.title}}</view>
  93. <view>{{item.desc}}</view>
  94. </view>
  95. <image :src="item.icon" mode="aspectFill"></image>
  96. </view>
  97. <view class="cardbox-res resnum">{{item.data || '--'}}</view>
  98. <view class="cardbox-time">{{item.date && item.date.substring(5,16)}}</view>
  99. </view> -->
  100. </view>
  101. <!-- 健康史 -->
  102. <view class="box-title">
  103. <text>健康史</text>
  104. </view>
  105. <view class="cardbox">
  106. <view class="health-item" v-for="(item,index) in healthRecordsList" :key="index" @click="handleEditHealth(item,1)">
  107. <image class="health-bgicon" :src="item.bgicon"></image>
  108. <view class="health-item-info">
  109. <view class="cardbox-maintitle" style="margin-bottom: 0;">{{item.title}}</view>
  110. <view class="text-overflow" style="margin-top: 20rpx;">{{item.desc || "尚未记录"}}</view>
  111. </view>
  112. </view>
  113. </view>
  114. <!-- 生活习惯 -->
  115. <view class="box-title">
  116. <text>生活习惯</text>
  117. </view>
  118. <view class="cardbox">
  119. <view class="health-item" v-for="(item,index) in livingHabits" :key="index" @click="handleEditHealth(item,2)">
  120. <image class="health-bgicon" :src="item.bgicon"></image>
  121. <view class="health-item-info">
  122. <view class="cardbox-maintitle" style="margin-bottom: 0;">{{item.title}}</view>
  123. <view class="text-overflow" style="margin-top: 20rpx;">{{item.desc || "尚未记录"}}</view>
  124. </view>
  125. </view>
  126. </view>
  127. </view>
  128. <!-- 修改身高体重弹窗 -->
  129. <uni-popup ref="popup" :mask-click="false">
  130. <view class="popbox">
  131. <view class="popbox-title">{{title}}</view>
  132. <view class="uni-input-wrapper">
  133. <input class="uni-input" type="number" focus :placeholder="placeholder" maxlength="5"
  134. :value="inputValue" @input="clearInput" />
  135. <image class="uni-icon" src="@/static/image/healthRecords/input_close_icon.png" v-if="showClearIcon"
  136. @click="clearIcon"></image>
  137. <text>{{title =="身高"?'cm':title =="体重"?'kg':''}}</text>
  138. </view>
  139. <view class="popbox-footer">
  140. <button class="popbox-footer-btn cancel" @click="close">取消</button>
  141. <button class="popbox-footer-btn confirm" :loading="btnLoading" :disabled="btnLoading"
  142. @click="handleSubmit">确认</button>
  143. </view>
  144. </view>
  145. </uni-popup>
  146. <!-- footer -->
  147. <!-- 填写生活习惯的 -->
  148. <view class="footer" >
  149. <view class="footer-btn" @click="editHealthRecordLife">填写个人健康专属档案</view>
  150. </view>
  151. <!-- 分享弹窗 -->
  152. <u-popup :show="showShare" @close="showShare = false" >
  153. <share-box :shareItem="shareItem" :showCopy="false" @closeShare='showShare = false' ></share-box>
  154. </u-popup>
  155. </view>
  156. </template>
  157. <script>
  158. import {
  159. myRecord,
  160. HealthDataList,
  161. HealthLife,
  162. editRecord
  163. } from '@/api/healthRecords.js'
  164. export default {
  165. data() {
  166. return {
  167. opacity: 1,
  168. hasRecord: true, //是否填过档案
  169. user: {},
  170. fat: "",
  171. recordInfo: {},
  172. title: "身高",
  173. placeholder: "请输入身高",
  174. showClearIcon: false,
  175. inputValue: '',
  176. btnLoading: false,
  177. headerHeight:44,
  178. statusBarBG:"none",
  179. top:0,
  180. defaultHeadimg:"../../../static/image/healthRecords/my_heads_icon.png",
  181. healthData: [{
  182. title: '血糖',
  183. desc: '血糖健康监测',
  184. data: '',
  185. date: '',
  186. icon: "../../../static/image/healthRecords/blood_sugar_icon.png",
  187. }],
  188. healthRecordsList: [
  189. {
  190. title: '疾病史',
  191. type: "healthHistory",
  192. desc: '',
  193. bgicon: "../../../static/image/healthRecords/jbs_icon.png",
  194. }, {
  195. title: '症状史',
  196. type: "symptomHistory",
  197. desc: '',
  198. bgicon: "../../../static/image/healthRecords/zzs_icon.png",
  199. }, {
  200. title: '家族史',
  201. type: "familyHistory",
  202. desc: '',
  203. bgicon: "../../../static/image/healthRecords/jzs_icon.png",
  204. }, {
  205. title: '用药史',
  206. type: "drugHistory",
  207. desc: '',
  208. bgicon: "../../../static/image/healthRecords/yys_icon.png",
  209. }, {
  210. title: '过敏史',
  211. type: "allergyHistory",
  212. desc: '',
  213. bgicon: "../../../static/image/healthRecords/gms_icon.png",
  214. }
  215. ],
  216. livingHabits: [
  217. {
  218. title: '饮食',
  219. desc: '',
  220. type: "dietList",
  221. bgicon: "../../../static/image/healthRecords/ys_icon.png",
  222. }, {
  223. title: '睡眠情况',
  224. desc: '',
  225. type: "sleepList",
  226. bgicon: "../../../static/image/healthRecords/smqk_icon.png",
  227. }, {
  228. title: '运动',
  229. desc: '',
  230. type: "sportList",
  231. bgicon: "../../../static/image/healthRecords/yd_icon.png",
  232. }
  233. ],
  234. showShare:false,
  235. shareItem:{ imageUrl:"",title:"",path:"",isMini:true },
  236. }
  237. },
  238. onShow() {
  239. this.user = {}
  240. if (!this.$isLogin()) {
  241. this.$showLoginPage();
  242. } else {
  243. this.user = this.$getUserInfo();
  244. this.getMyRecord()
  245. // this.getHealthDataList()
  246. this.getHealthLife()
  247. }
  248. },
  249. onPageScroll(e) {
  250. this.top=e.scrollTop;
  251. },
  252. computed: {
  253. // 计算属性的 getter
  254. headerBG:function() {
  255. var top=this.top/88;
  256. return 'rgba(255,92,3, ' + top + ')';
  257. },
  258. },
  259. methods: {
  260. getBmi() {
  261. let fat = ""
  262. if(this.recordInfo && JSON.stringify(this.recordInfo) != "{}") {
  263. if(!this.$isEmpty(this.recordInfo.weight) && !this.$isEmpty(this.recordInfo.weight)) {
  264. // 计算BMI值
  265. this.recordInfo.bmi = Math.round(this.recordInfo.weight / Math.pow(this.recordInfo.height / 100, 2));
  266. // 判断体重状态
  267. if (this.recordInfo.bmi < 18.5) {
  268. fat = "偏瘦";
  269. } else if (this.recordInfo.bmi < 24) {
  270. fat = "正常";
  271. } else if (this.recordInfo.bmi < 28) {
  272. fat = "超重";
  273. } else {
  274. fat = "肥胖";
  275. }
  276. // 添加推荐体重
  277. // let lowerBound = 18.5 * Math.pow(this.recordInfo.weight / 100, 2);
  278. // let upperBound = 24 * Math.pow(this.recordInfo.weight / 100, 2);
  279. }
  280. } else {
  281. this.recordInfo.bmi = ""
  282. }
  283. this.fat = fat
  284. },
  285. // 查询今日健康生活
  286. getHealthLife() {
  287. const param = {
  288. userId: this.user.userId
  289. }
  290. HealthLife(param).then(res => {
  291. if (res.code == 200 && res.data) {
  292. this.livingHabits[0].desc = res.data && res.data.eat ? this.resetData(JSON.parse(res.data.eat)) : ''
  293. this.livingHabits[1].desc = res.data && res.data.sleep ? this.resetData(JSON.parse(res.data.sleep)) : ''
  294. this.livingHabits[2].desc = res.data && res.data.sport ? this.resetData(JSON.parse(res.data.sport)) : ''
  295. }
  296. },
  297. rej => {}
  298. )
  299. },
  300. // 填写生活习惯(每次都是新增)
  301. editHealthRecordLife() {
  302. uni.navigateTo({
  303. url: "./add?formType=healthLife"
  304. })
  305. },
  306. // 健康档案
  307. getMyRecord() {
  308. myRecord().then(res => {
  309. if (res.code == 200) {
  310. if(res.data) {
  311. this.hasRecord = true
  312. this.recordInfo = res.data
  313. this.healthRecordsList[0].desc = res.data.healthHistory ? this.resetData(JSON.parse(res.data.healthHistory)) : ""
  314. this.healthRecordsList[1].desc = res.data.symptomHistory ? this.resetData(JSON.parse(res.data.symptomHistory)) : ""
  315. this.healthRecordsList[2].desc = res.data.familyHistory ? this.resetData(JSON.parse(res.data.familyHistory)) : ""
  316. this.healthRecordsList[3].desc = res.data.drugHistory ? this.resetData(JSON.parse(res.data.drugHistory)) : ""
  317. this.healthRecordsList[4].desc = res.data.allergyHistory ? this.resetData(JSON.parse(res.data.allergyHistory)) : ""
  318. } else {
  319. this.hasRecord = false
  320. this.handelHealthRecord(1)
  321. }
  322. } else {
  323. uni.showToast({
  324. icon:'none',
  325. title: res.msg,
  326. });
  327. }
  328. this.getBmi()
  329. },
  330. rej => {}
  331. )
  332. },
  333. resetData(data) {
  334. let set = new Set();
  335. data.forEach(item => {
  336. item.question.forEach(it => {
  337. if (item.value.includes(it.name)) {
  338. if (it.isWrite == 1 && it.writeVal) {
  339. const str = it.name + "(" + it.writeVal + ")";
  340. set.add(str);
  341. } else {
  342. set.add(it.name);
  343. }
  344. } else if(item.name == '平时应酬' && it.name === '每周多少次'){
  345. if (it.writeVal) {
  346. const str = "每周" + it.writeVal + "次";
  347. set.add(str);
  348. }
  349. }
  350. });
  351. });
  352. return Array.from(set).join(",");
  353. },
  354. // 健康数据列表
  355. getHealthDataList() {
  356. const param = {
  357. pageNum: 1,
  358. pageSize: 10,
  359. userId: this.user.userId
  360. }
  361. HealthDataList(param).then(res => {
  362. if (res.code == 200 && res.data && res.data.length > 0) {
  363. this.healthData[0].data = res.data[0].bloodSugar
  364. this.healthData[0].date = res.data[0].creatTime
  365. } else {
  366. this.healthData[0].data = ""
  367. this.healthData[0].date = ""
  368. }
  369. },
  370. rej => {}
  371. );
  372. },
  373. handelHealthRecord(type) {
  374. if (type == 1) {
  375. uni.redirectTo({
  376. url: "./add"
  377. })
  378. } else {
  379. uni.navigateTo({
  380. url: "./add"
  381. })
  382. }
  383. },
  384. handleEditHealth(item,type) {
  385. // type 1:修改健康史相关 2:修改生活习惯
  386. if(type == 2) {
  387. uni.navigateTo({
  388. url: "./add?formType="+item.type
  389. })
  390. } else {
  391. uni.navigateTo({
  392. url: "./edit?id="+this.recordInfo.id + "&formType="+item.type
  393. })
  394. }
  395. },
  396. handleEdit(type) {
  397. if (type == "height") {
  398. this.title = "身高"
  399. this.placeholder = "请输入身高"
  400. this.inputValue = this.recordInfo.height || undefined
  401. } else if (type == "weight") {
  402. this.title = "体重"
  403. this.placeholder = "请输入体重"
  404. this.inputValue = this.recordInfo.weight || undefined
  405. }
  406. this.$refs.popup.open("center")
  407. },
  408. close() {
  409. this.$refs.popup.close()
  410. },
  411. // 修改身高/体重
  412. handleSubmit() {
  413. if(this.title == "身高") {
  414. // 判断字符串为正整数
  415. const reg = /^[1-9]\d*$/
  416. if(!reg.test(this.inputValue)) {
  417. uni.showToast({
  418. title: "请输入正确的身高",
  419. icon: "none"
  420. })
  421. return
  422. }
  423. }
  424. if(this.title == "体重") {
  425. // 判断字符串为数字且保留一位小数
  426. const reg = /^\d+(\.\d{1})?$/
  427. if(!reg.test(this.inputValue) || this.inputValue == 0) {
  428. uni.showToast({
  429. title: "请输入正确的体重",
  430. icon: "none"
  431. })
  432. return
  433. }
  434. }
  435. const param = {
  436. id: Number(this.recordInfo.id || 0),
  437. weight: this.title == "体重" ? this.inputValue : undefined,
  438. height: this.title == "身高" ? this.inputValue : undefined,
  439. };
  440. editRecord(param).then(res => {
  441. this.btnLoading = false
  442. if (res.code == 200) {
  443. this.recordInfo.weight = this.title == "体重" ? this.inputValue : this.recordInfo.weight
  444. this.recordInfo.height = this.title == "身高" ? this.inputValue : this.recordInfo.height
  445. this.getBmi()
  446. this.close()
  447. } else {
  448. uni.showToast({
  449. title: res.msg,
  450. icon: "none"
  451. })
  452. }
  453. },
  454. rej => {}
  455. )
  456. },
  457. clearInput(event) {
  458. this.inputValue = event.detail.value;
  459. if (event.detail.value.length > 0) {
  460. this.showClearIcon = true;
  461. } else {
  462. this.showClearIcon = false;
  463. }
  464. },
  465. clearIcon() {
  466. this.inputValue = '';
  467. this.showClearIcon = false;
  468. },
  469. doShare() {
  470. this.shareItem.title= "健康档案";
  471. this.shareItem.imageUrl='https://hos-1309931967.cos.ap-chongqing.myqcloud.com/fs/20230106/6b459adfb1004c1a96219bcdf07e337c.png';
  472. this.shareItem.compressImage = 1
  473. this.shareItem.isMini=true;
  474. this.shareItem.path='/pages_user/healthRecords/index'
  475. let cdn=uni.getStorageSync('h5Path');
  476. this.shareItem.url=cdn+'/pages/user/healthRecords/index'
  477. this.showShare=true;
  478. }
  479. }
  480. }
  481. </script>
  482. <style scoped lang="scss">
  483. @mixin u-flex($flexD, $alignI, $justifyC) {
  484. display: flex;
  485. flex-direction: $flexD;
  486. align-items: $alignI;
  487. justify-content: $justifyC;
  488. }
  489. .shareicon {
  490. height: 40rpx;
  491. width: 40rpx;
  492. }
  493. .uni-nav-bar {
  494. position: fixed;
  495. top: 0;
  496. left: 0;
  497. width: 100%;
  498. z-index: 999;
  499. overflow: hidden;
  500. .uni-nav-bar_bg {
  501. width: 100%;
  502. position: absolute;
  503. top: 0;
  504. left: 0;
  505. }
  506. }
  507. .nav-bar{
  508. .grace-page-header {
  509. position: fixed;
  510. width: 100%;
  511. left: 0;
  512. top: 0;
  513. z-index: 98;
  514. border-bottom: 0px solid #FFFFFF;
  515. .grace-page-status-bar {
  516. width: 100%;
  517. height: var(--status-bar-height);
  518. }
  519. .grace-page-header-nav {
  520. width: 100%;
  521. display: flex;
  522. flex-direction: row;
  523. flex-wrap: nowrap;
  524. align-items: center;
  525. justify-content: space-between;
  526. }
  527. }
  528. .title {
  529. font-family: PingFang SC, PingFang SC;
  530. font-weight: 500;
  531. font-size: 32rpx;
  532. color: #222222;
  533. line-height: 44rpx;
  534. }
  535. .content-header {
  536. height: 80rpx;
  537. padding: 0 24rpx;
  538. @include u-flex(row, center, space-between);
  539. &-l {
  540. font-family: PingFang SC, PingFang SC;
  541. font-weight: 500;
  542. font-size: 26rpx;
  543. color: #FFFFFF;
  544. line-height: 28rpx;
  545. @include u-flex(row, center, flex-start);
  546. .address {
  547. width: 20rpx;
  548. height: 30rpx;
  549. margin-right: 6rpx;
  550. }
  551. }
  552. &-title{
  553. display: flex;
  554. flex: 1;
  555. justify-content: center;
  556. align-items: center;
  557. font-size: 34rpx;
  558. font-weight: 444;
  559. color: #fff;
  560. }
  561. }
  562. .nav_box{
  563. width: 100%;
  564. .status_bar {
  565. height: var(--status-bar-height);
  566. width: 100%;
  567. }
  568. .nav_bar {
  569. height: 44px;
  570. width: 100%;
  571. }
  572. }
  573. }
  574. .container {
  575. position: relative;
  576. .jkda_top_bg {
  577. position: absolute;
  578. top:0;
  579. /* #ifdef H5 */
  580. top:-20px ;
  581. /* #endif */
  582. left: 0;
  583. width: 100%;
  584. height: auto;
  585. }
  586. &-body {
  587. position: relative;
  588. padding: 32rpx 24rpx;
  589. // #ifndef H5
  590. padding-top: calc(32rpx);
  591. // #endif
  592. // #ifdef H5
  593. padding-top: calc(var(--status-bar-height) + 60rpx);
  594. // #endif
  595. padding-bottom: calc(var(--window-bottom) + 170rpx);
  596. }
  597. }
  598. .popbox {
  599. background-color: #fff;
  600. width: 630rpx;
  601. padding: 40rpx;
  602. box-sizing: border-box;
  603. border-radius: 32rpx 32rpx 32rpx 32rpx;
  604. overflow: hidden;
  605. font-family: PingFang SC, PingFang SC;
  606. font-weight: 500;
  607. &-title {
  608. font-size: 34rpx;
  609. color: #333333;
  610. text-align: center;
  611. }
  612. .uni-input-wrapper {
  613. width: 100%;
  614. height: 78rpx;
  615. margin-top: 36rpx;
  616. box-sizing: border-box;
  617. background: #FFFFFF;
  618. border-radius: 16rpx 16rpx 16rpx 16rpx;
  619. border: 2rpx solid #ECECEC;
  620. padding: 0 24rpx;
  621. @include u-flex(row, center, space-between);
  622. .uni-icon {
  623. flex-shrink: 0;
  624. width: 32rpx;
  625. height: 32rpx;
  626. }
  627. }
  628. &-footer {
  629. margin-top: 40rpx;
  630. @include u-flex(row, center, space-between);
  631. &-btn {
  632. width: 248rpx;
  633. height: 84rpx;
  634. line-height: 84rpx;
  635. border-radius: 42rpx;
  636. font-size: 32rpx;
  637. vertical-align: middle;
  638. &::after {
  639. border: none;
  640. }
  641. }
  642. .cancel {
  643. background: #F4F4F4;
  644. color: #757575;
  645. }
  646. .confirm {
  647. background: #FF5C03;
  648. color: #FFFFFF;
  649. }
  650. }
  651. }
  652. .userbox {
  653. padding: 32rpx;
  654. background: #FFFFFF;
  655. border-radius: 16rpx 16rpx 16rpx 16rpx;
  656. @include u-flex(row, center, space-between);
  657. &-headimg {
  658. flex-shrink: 0;
  659. width: 140rpx;
  660. height: 140rpx;
  661. image{
  662. width: 140rpx;
  663. height: 140rpx;
  664. border-radius: 50%;
  665. }
  666. }
  667. &-left {
  668. flex-shrink: 0;
  669. flex: 1;
  670. @include u-flex(row, center, flex-start);
  671. }
  672. &-info {
  673. margin-left: 24rpx;
  674. font-family: PingFang SC, PingFang SC;
  675. font-weight: 600;
  676. font-size: 32rpx;
  677. color: #222222;
  678. &-tag {
  679. margin-top: 30rpx;
  680. font-weight: 400;
  681. font-size: 22rpx;
  682. color: #FF5C03;
  683. @include u-flex(row, center, flex-start);
  684. view {
  685. min-width: 62rpx;
  686. height: 42rpx;
  687. padding: 0 20rpx;
  688. box-sizing: border-box;
  689. background: #FCF0E7;
  690. border-radius: 24rpx 24rpx 24rpx 24rpx;
  691. text-align: center;
  692. line-height: 42rpx;
  693. margin-right: 14rpx;
  694. }
  695. }
  696. }
  697. &-right {
  698. margin-left: 24rpx;
  699. image {
  700. width: 48rpx;
  701. height: 48rpx;
  702. }
  703. }
  704. }
  705. .box-title {
  706. height: 80rpx;
  707. line-height: 80rpx;
  708. border-radius: 16rpx 16rpx 16rpx 16rpx;
  709. font-family: PingFang SC, PingFang SC;
  710. font-weight: 500;
  711. font-size: 36rpx;
  712. color: #222222;
  713. margin: 20rpx 0;
  714. @include u-flex(row, center, space-between);
  715. &-right {
  716. flex-shrink: 0;
  717. min-width: 240rpx;
  718. height: 64rpx;
  719. padding: 0 32rpx;
  720. box-sizing: border-box;
  721. background: #FFFFFF;
  722. border-radius: 32rpx 32rpx 32rpx 32rpx;
  723. font-size: 24rpx;
  724. color: #FF5C03;
  725. @include u-flex(row, center, center);
  726. image {
  727. width: 24rpx;
  728. height: 24rpx;
  729. margin-right: 8rpx;
  730. }
  731. }
  732. }
  733. .cardbox {
  734. @include u-flex(row, center, flex-start);
  735. flex-wrap: wrap;
  736. gap: 16rpx 14rpx;
  737. &-item {
  738. width: 344rpx;
  739. height: 264rpx;
  740. background: #FFFFFF;
  741. border-radius: 16rpx 16rpx 16rpx 16rpx;
  742. padding: 24rpx 24rpx 24rpx 24rpx;
  743. box-sizing: border-box;
  744. overflow: hidden;
  745. }
  746. .bmibox-tagbox {
  747. min-width: 72rpx;
  748. height: 40rpx;
  749. }
  750. .bmibox {
  751. &-tag {
  752. min-width: 72rpx;
  753. height: 40rpx;
  754. line-height: 40rpx;
  755. text-align: center;
  756. padding: 0 12rpx;
  757. box-sizing: border-box;
  758. display: inline-block;
  759. background: #FCF0E7;
  760. border-radius: 8rpx 8rpx 8rpx 8rpx;
  761. font-family: PingFang SC, PingFang SC;
  762. font-weight: 400;
  763. font-size: 24rpx;
  764. color: #FF5C03;
  765. }
  766. &-info {
  767. @include u-flex(row, center, flex-start);
  768. font-family: PingFang SC, PingFang SC;
  769. font-weight: 400;
  770. font-size: 24rpx;
  771. color: #999999;
  772. }
  773. &-infolabel {
  774. min-width: 48rpx;
  775. flex-shrink: 0;
  776. }
  777. &-infoval {
  778. flex: 1;
  779. padding: 0 12rpx;
  780. text-align: center;
  781. font-weight: 500;
  782. color: #222222;
  783. }
  784. &-edit {
  785. width: 32rpx;
  786. height: 32rpx;
  787. flex-shrink: 0;
  788. }
  789. }
  790. &-maintitle {
  791. margin-bottom: 4rpx;
  792. font-weight: 600;
  793. font-size: 30rpx;
  794. color: #333333;
  795. }
  796. &-title {
  797. @include u-flex(row, center, space-between);
  798. font-weight: 400;
  799. font-size: 24rpx;
  800. color: #999999;
  801. image {
  802. width: 72rpx;
  803. height: 72rpx;
  804. flex-shrink: 0;
  805. }
  806. }
  807. .resnum {
  808. font-family: DIN, DIN;
  809. font-weight: 500;
  810. font-size: 64rpx;
  811. }
  812. &-res {
  813. height: 78rpx;
  814. margin: 20rpx 0 6rpx;
  815. font-family: PingFang SC, PingFang SC;
  816. font-weight: 600;
  817. font-size: 48rpx;
  818. color: #333333;
  819. }
  820. &-time {
  821. font-weight: 400;
  822. font-size: 22rpx;
  823. color: #999999;
  824. }
  825. }
  826. .health-item {
  827. width: 343rpx;
  828. height: 224rpx;
  829. padding: 24rpx;
  830. box-sizing: border-box;
  831. background: #FFFFFF;
  832. border-radius: 16rpx 16rpx 16rpx 16rpx;
  833. overflow: hidden;
  834. position: relative;
  835. font-family: PingFang SC, PingFang SC;
  836. font-weight: 400;
  837. font-size: 24rpx;
  838. color: #999999;
  839. }
  840. .health-item-info {
  841. position: relative;
  842. }
  843. .health-bgicon {
  844. position: absolute;
  845. right: 0;
  846. bottom: 0;
  847. width: 168rpx;
  848. height: 168rpx;
  849. }
  850. .text-overflow {
  851. word-break:break-all;
  852. overflow: hidden;
  853. text-overflow: ellipsis;
  854. display: -webkit-box;
  855. -webkit-line-clamp: 4;
  856. -webkit-box-orient: vertical;
  857. }
  858. .footer {
  859. width: 100%;
  860. height: 152rpx;
  861. padding: 20rpx 24rpx;
  862. box-sizing: border-box;
  863. background: #FFFFFF;
  864. box-shadow: 0rpx -6rpx 8rpx 0rpx rgba(114, 114, 114, 0.1);
  865. position: fixed;
  866. bottom: var(--window-bottom);
  867. left: 0;
  868. &-btn {
  869. height: 112rpx;
  870. background: #FF5C03;
  871. border-radius: 16rpx 16rpx 16rpx 16rpx;
  872. font-family: PingFang SC, PingFang SC;
  873. font-weight: 600;
  874. font-size: 34rpx;
  875. color: #FFFFFF;
  876. line-height: 112rpx;
  877. text-align: center;
  878. }
  879. }
  880. </style>