Эх сурвалжийг харах

refactor: 行页面移除成长里程碑(OctopusGraph组件+action页面清空)

Xiaogang Liao 2 сар өмнө
parent
commit
f8b85e23a2

+ 2 - 59
cfc-frontend/components/OctopusGraph.vue

@@ -29,7 +29,7 @@
   </view>
 
   <!-- ===== 关系健康概览 ===== -->
-  <view class="rq-section" v-if="isLoggedIn && (healthAlerts.length > 0 || milestones.length > 0)">
+  <view class="rq-section" v-if="isLoggedIn && healthAlerts.length > 0">
     <view class="rq-header">
       <text class="rq-title">关系健康</text>
       <text class="rq-more" @click="$emit('questionnaire')">去做问卷</text>
@@ -49,19 +49,7 @@
         </view>
       </view>
     </view>
-    <!-- 里程碑列表 -->
-    <view class="rq-milestones" v-if="milestones.length > 0">
-      <view class="rq-milestone-card" v-for="m in milestones" :key="m.memberId">
-        <view class="rq-milestone-icon">
-          <text class="rq-milestone-emoji">🎂</text>
-        </view>
-        <view class="rq-milestone-info">
-          <text class="rq-milestone-name">{{ m.memberName }}</text>
-          <text class="rq-milestone-desc">{{ m.daysUntil > 0 ? m.daysUntil + '天后生日' : '今天生日' }}</text>
-        </view>
-      </view>
-    </view>
-    <!-- 快捷操作 -->
+  <!-- 快捷操作 -->
     <view class="rq-quick-actions">
       <view class="rq-action-btn" @click="$emit('interactionLog')">
         <text class="rq-action-icon">📝</text>
@@ -81,7 +69,6 @@ export default {
   props: {
     contactList: { type: Array, default: function() { return [] } },
     healthAlerts: { type: Array, default: function() { return [] } },
-    milestones: { type: Array, default: function() { return [] } },
     isLoggedIn: { type: Boolean, default: false }
   }
 }
@@ -248,50 +235,6 @@ export default {
   padding: 8rpx 20rpx;
   border-radius: 20rpx;
 }
-/* 里程碑卡片 */
-.rq-milestones {
-  display: flex;
-  flex-direction: column;
-  gap: 12rpx;
-  margin-bottom: 16rpx;
-}
-.rq-milestone-card {
-  background: #F0F9FF;
-  border-radius: 16rpx;
-  padding: 20rpx;
-  display: flex;
-  align-items: center;
-  gap: 16rpx;
-  border: 1rpx solid #BAE6FD;
-}
-.rq-milestone-icon {
-  width: 64rpx;
-  height: 64rpx;
-  border-radius: 50%;
-  background: #fff;
-  display: flex;
-  align-items: center;
-  justify-content: center;
-  flex-shrink: 0;
-}
-.rq-milestone-emoji {
-  font-size: 32rpx;
-}
-.rq-milestone-info {
-  flex: 1;
-  display: flex;
-  flex-direction: column;
-  gap: 4rpx;
-}
-.rq-milestone-name {
-  font-size: 28rpx;
-  font-weight: 600;
-  color: #333;
-}
-.rq-milestone-desc {
-  font-size: 24rpx;
-  color: #0EA5E9;
-}
 /* 快捷操作 */
 .rq-quick-actions {
   display: flex;

+ 8 - 45
cfc-frontend/pages/action/index.vue

@@ -8,6 +8,13 @@
       tagline="知行合一 · 快乐成长"
       quote="千里之行,始于足下" />
 
+    <!-- 家庭成员选择条 -->
+    <FamilyMemberStrip
+      v-if="isLoggedIn"
+      :members="familyMembersVisible"
+      :selectedMemberId="selectedMemberId"
+      @select="onFamilyMemberSelect" />
+
     <!-- 游客登录引导卡 -->
     <template v-if="!isLoggedIn">
       <LoginGuideCard
@@ -125,7 +132,7 @@ import ContactImport from '../../components/ContactImport.vue'
 import OctopusGraph from '../../components/OctopusGraph.vue'
 import FamilyRelationGraph from '../../components/FamilyRelationGraph.vue'
 import WuxingSandbox from '../../components/wuxing-sandbox.vue'
-import { getVisibleSections, getEnergyOverview, getFamilyEnergySandbox, getTodayTasksByCategory, getActivityList, getProductsByDomain, getChildren, getContactList, getVisibleFamilyMembers, getFeaturedArticles, getHealthAlerts, getMilestones } from '../../utils/api.js'
+import { getVisibleSections, getEnergyOverview, getFamilyEnergySandbox, getTodayTasksByCategory, getActivityList, getProductsByDomain, getChildren, getContactList, getVisibleFamilyMembers, getFeaturedArticles, getHealthAlerts } from '../../utils/api.js'
 
 export default {
   components: { TabTransition, PageBanner, LoginGuideCard, FamilyEnergyBar, DimensionTasks, DimensionActivities, DimensionProducts, DimensionArticles, ContactCard, ContactImport, FamilyRelationGraph, OctopusGraph, WuxingSandbox },
@@ -707,50 +714,6 @@ export default {
   padding: 8rpx 20rpx;
   border-radius: 20rpx;
 }
-/* 里程碑卡片 */
-.rq-milestones {
-  display: flex;
-  flex-direction: column;
-  gap: 12rpx;
-  margin-bottom: 16rpx;
-}
-.rq-milestone-card {
-  background: #F0F9FF;
-  border-radius: 16rpx;
-  padding: 20rpx;
-  display: flex;
-  align-items: center;
-  gap: 16rpx;
-  border: 1rpx solid #BAE6FD;
-}
-.rq-milestone-icon {
-  width: 64rpx;
-  height: 64rpx;
-  border-radius: 50%;
-  background: #fff;
-  display: flex;
-  align-items: center;
-  justify-content: center;
-  flex-shrink: 0;
-}
-.rq-milestone-emoji {
-  font-size: 32rpx;
-}
-.rq-milestone-info {
-  flex: 1;
-  display: flex;
-  flex-direction: column;
-  gap: 4rpx;
-}
-.rq-milestone-name {
-  font-size: 28rpx;
-  font-weight: 600;
-  color: #333;
-}
-.rq-milestone-desc {
-  font-size: 24rpx;
-  color: #0EA5E9;
-}
 /* 快捷操作 */
 .rq-quick-actions {
   display: flex;