# 07-个人中心页面(原型) ## 目标 实现 Web 端个人中心和健康档案管理页面原型。 --- ## 前置要求 - 路由配置完成 - 认证状态 Store 已创建 - 体质状态 Store 已创建 --- ## 实施步骤 ### 步骤 1:个人中心页面 创建 `src/views/profile/ProfileView.vue`: ```vue {{ authStore.user?.nickname?.charAt(0) || 'U' }} {{ authStore.user?.nickname || '用户' }} {{ authStore.user?.phone }} {{ constitutionNames[constitutionStore.result.primaryType] }} 健康管理 健康档案 查看和管理您的健康信息 体质报告 {{ constitutionStore.result ? `当前体质:${constitutionNames[constitutionStore.result.primaryType]}` : '暂无测评记录' }} 对话历史 查看AI咨询记录 其他 健康商城 选购适合您的保健品 关于我们 了解健康AI助手 退出登录 版本 1.0.0(原型版) ``` ### 步骤 2:健康档案页面 创建 `src/views/profile/HealthRecordView.vue`: ```vue 健康档案 基础信息 {{ mockProfile.name }} {{ mockProfile.gender }} {{ mockProfile.age }}岁 {{ mockProfile.height }}cm {{ mockProfile.weight }}kg {{ bmi }} {{ mockProfile.bloodType }} 体质信息 {{ constitutionNames[constitutionStore.result.primaryType] }} {{ constitutionDescriptions[constitutionStore.result.primaryType].description }} 测评时间:{{ formatTime(constitutionStore.result.assessedAt) }} 开始测评 既往病史 {{ disease }} 过敏信息 {{ allergy }} 生活习惯 {{ mockProfile.sleepTime }} {{ mockProfile.wakeTime }} {{ mockProfile.exerciseFrequency }} 以上为模拟数据,后续将支持编辑和同步 ``` --- ## 验收标准 - [ ] 个人中心页面正常显示 - [ ] 菜单跳转正常 - [ ] 退出登录正常 - [ ] 健康档案页面正常显示 - [ ] 体质信息正确展示 --- ## 预计耗时 30-35 分钟 --- ## 完成 至此,Web 原型开发所有页面文档创建完成! 可以开始第四阶段:后端开发。
{{ authStore.user?.phone }}
查看和管理您的健康信息
{{ constitutionStore.result ? `当前体质:${constitutionNames[constitutionStore.result.primaryType]}` : '暂无测评记录' }}
查看AI咨询记录
选购适合您的保健品
了解健康AI助手
版本 1.0.0(原型版)
{{ constitutionDescriptions[constitutionStore.result.primaryType].description }}
测评时间:{{ formatTime(constitutionStore.result.assessedAt) }}