[AI Generated]: refactor(Views): 优化测量报告页面结构与样式
This commit is contained in:
@@ -2,16 +2,14 @@
|
||||
<view class="scrollViewContent">
|
||||
<!-- 测量信息卡片 -->
|
||||
<view class="info-card">
|
||||
<view class="info-header">
|
||||
<view class="info-avatar"></view>
|
||||
<view class="info-meta">
|
||||
<view class="info-time">{{ report.measureTime }}</view>
|
||||
<view class="info-name">{{ report.userName }}</view>
|
||||
</view>
|
||||
<view class="info-avatar"></view>
|
||||
<view class="info-meta">
|
||||
<view class="info-name">陈万宁</view>
|
||||
<view class="info-time">2026-05-06 09:30</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 体重卡片 -->
|
||||
<!-- 最近测量卡 -->
|
||||
<view class="weight-card">
|
||||
<!-- 卡头 -->
|
||||
<view class="card-header">
|
||||
@@ -26,21 +24,21 @@
|
||||
<view class="weight-row">
|
||||
<view class="weight-main">
|
||||
<view class="weight-num-wrap">
|
||||
<text class="weight-int">{{ report.weight }}</text>
|
||||
<text class="weight-dec">{{ report.weightDecimal }}</text>
|
||||
<text class="weight-int">{{ record.weight }}</text>
|
||||
<text class="weight-dec">{{ record.weightDecimal }}</text>
|
||||
<text class="weight-unit">kg</text>
|
||||
</view>
|
||||
<view class="weight-date">{{ report.weightDate }}</view>
|
||||
<view class="weight-date">{{ record.date }}</view>
|
||||
</view>
|
||||
<view class="weight-diff">
|
||||
<view class="diff-num-wrap">
|
||||
<view class="diff-num {{ report.diff < 0 ? 'diff-down' : 'diff-up' }}">{{ report.diff < 0 ? -report.diff : report.diff }}</view>
|
||||
<view class="diff-num {{ record.diff < 0 ? 'diff-down' : 'diff-up' }}">{{ record.diff < 0 ? -record.diff : record.diff }}</view>
|
||||
<view class="diff-unit">
|
||||
kg
|
||||
<text class="diff-arrow {{ report.diff < 0 ? 'arrow-down' : 'arrow-up' }}"></text>
|
||||
<text class="diff-arrow {{ record.diff < 0 ? 'arrow-down' : 'arrow-up' }}"></text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="diff-label">{{ report.diff < 0 ? '体重较上次减轻' : '体重较上次增加' }}</view>
|
||||
<view class="diff-label">{{ record.diff < 0 ? '体重较上次减轻' : '体重较上次增加' }}</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -54,17 +52,17 @@
|
||||
<view class="metric-label-text">身高</view>
|
||||
</view>
|
||||
<view class="metric-value-row">
|
||||
<text class="metric-value">{{ report.height }}</text>
|
||||
<text class="metric-value">{{ record.height }}</text>
|
||||
<text class="metric-unit">cm</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="metric-col">
|
||||
<view class="metric-label">
|
||||
<view class="metric-label-text">BMI</view>
|
||||
<view class="metric-label-value">{{ report.bmiLabel }}</view>
|
||||
<view class="metric-label-value">{{ record.bmiLabel }}</view>
|
||||
</view>
|
||||
<view class="metric-value-row">
|
||||
<text class="metric-value">{{ report.bmi }}</text>
|
||||
<text class="metric-value">{{ record.bmi }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="metric-col">
|
||||
@@ -72,12 +70,16 @@
|
||||
<view class="metric-label-text">标准体重</view>
|
||||
</view>
|
||||
<view class="metric-value-row">
|
||||
<text class="metric-value">{{ report.stdWeight }}</text>
|
||||
<text class="metric-value">{{ record.stdWeight }}</text>
|
||||
<text class="metric-unit">kg</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="card-lianjie">
|
||||
<image src="/images/home/lianjie.png" mode=""/>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 详细数据卡 -->
|
||||
@@ -95,21 +97,21 @@
|
||||
<view class="detail-item">
|
||||
<view class="detail-label">体脂率</view>
|
||||
<view class="detail-value-row">
|
||||
<text class="detail-value">{{ report.bodyFat }}</text>
|
||||
<text class="detail-value">{{ record.bodyFat }}</text>
|
||||
<text class="detail-unit">%</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="detail-item">
|
||||
<view class="detail-label">体脂肪</view>
|
||||
<view class="detail-value-row">
|
||||
<text class="detail-value">{{ report.bodyFatMass }}</text>
|
||||
<text class="detail-value">{{ record.bodyFatMass }}</text>
|
||||
<text class="detail-unit">kg</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="detail-item">
|
||||
<view class="detail-label">基础代谢</view>
|
||||
<view class="detail-value-row">
|
||||
<text class="detail-value">{{ report.bmr }}</text>
|
||||
<text class="detail-value">{{ record.bmr }}</text>
|
||||
<text class="detail-unit">kcal</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
Reference in New Issue
Block a user