hookehuyr

refactor(前端): 简化奖励页面的筛选逻辑并更新欢迎页文案

移除前端对奖励项目的搜索和筛选处理,完全交由API处理
更新欢迎页创建家庭的描述,明确年龄限制
...@@ -141,18 +141,9 @@ const hasMore = ref(true); ...@@ -141,18 +141,9 @@ const hasMore = ref(true);
141 const sortedRewardItems = computed(() => { 141 const sortedRewardItems = computed(() => {
142 // 确保couponList.value是数组类型 142 // 确保couponList.value是数组类型
143 const couponArray = Array.isArray(couponList.value) ? couponList.value : []; 143 const couponArray = Array.isArray(couponList.value) ? couponList.value : [];
144 - let items = [...couponArray];
145 144
146 - // Filter by search query 145 + // 搜索、积分范围筛选和排序都由API处理,前端直接返回API数据
147 - if (searchQuery.value) { 146 + return couponArray;
148 - items = items.filter(item =>
149 - item.title && item.title.toLowerCase().includes(searchQuery.value.toLowerCase())
150 - );
151 - }
152 -
153 - // 积分范围筛选现在由API处理,这里不需要前端筛选
154 - // 排序也由API处理,这里保持原始顺序
155 - return items;
156 }); 147 });
157 148
158 const toggleSortOrder = () => { 149 const toggleSortOrder = () => {
......
1 <!-- 1 <!--
2 * @Date: 2025-08-27 17:43:45 2 * @Date: 2025-08-27 17:43:45
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2025-09-18 17:55:04 4 + * @LastEditTime: 2025-09-19 14:00:38
5 * @FilePath: /lls_program/src/pages/Welcome/index.vue 5 * @FilePath: /lls_program/src/pages/Welcome/index.vue
6 * @Description: 欢迎页 6 * @Description: 欢迎页
7 --> 7 -->
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
27 <view> 27 <view>
28 <h3 class="font-bold">创建家庭</h3> 28 <h3 class="font-bold">创建家庭</h3>
29 <p class="text-gray-600 text-sm"> 29 <p class="text-gray-600 text-sm">
30 - 家长创建家庭,设置专属口令 30 + 60岁以上家长创建家庭,设置专属口令
31 </p> 31 </p>
32 </view> 32 </view>
33 </view> 33 </view>
......