From 0383ad6be2d000299b2b1af03113279927ffbb48 Mon Sep 17 00:00:00 2001 From: zzc <1761997216@qq.com> Date: Wed, 10 Jun 2026 00:34:12 +0800 Subject: [PATCH] fix: rating --- pages/index/index.vue | 10 ++++++++-- pages/mine/mine.vue | 18 +++++++++++++++--- pages/rating/detail.vue | 25 ++++++++++++++++++++++++- pages/rating/index.vue | 28 +++++++++++++++++++++++++++- 4 files changed, 74 insertions(+), 7 deletions(-) diff --git a/pages/index/index.vue b/pages/index/index.vue index 88c9fa6..2202c76 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -150,6 +150,10 @@ const switchCategory = (categoryId) => { const topicList = ref([]); +const getCurrentCategoryTitle = () => { + return categories.value.find((category) => category.id === currentCategoryId.value)?.title || "推荐"; +}; + const goToRating = (topicId, itemId) => { uni.$trackRecord({ eventName: 'jumpto_rating', @@ -216,8 +220,9 @@ onReachBottom(() => { onShareAppMessage(async () => { const shareToken = await getShareToken("index"); getShareReward(); + const categoryTitle = getCurrentCategoryTitle(); return { - title: "夯拉评分", + title: `夯拉评分 | ${categoryTitle}榜单正在热议`, path: "/pages/index/index?shareToken=" + shareToken, }; }); @@ -225,8 +230,9 @@ onShareAppMessage(async () => { onShareTimeline(async () => { const shareToken = await getShareToken("index"); getShareReward(); + const categoryTitle = getCurrentCategoryTitle(); return { - title: "夯拉评分", + title: `${categoryTitle}圈都在玩夯拉评分,来看看谁最夯`, query: `shareToken=${shareToken}`, }; }); diff --git a/pages/mine/mine.vue b/pages/mine/mine.vue index 9d970c2..6255935 100644 --- a/pages/mine/mine.vue +++ b/pages/mine/mine.vue @@ -93,7 +93,7 @@