From 023f12038851502632d9e9f82baccf9c9a4a4bd0 Mon Sep 17 00:00:00 2001 From: Ultrame <1019265060@qq.com> Date: Sat, 8 Nov 2025 20:38:16 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=AA=E4=BA=BA=E9=A1=B5=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/user_pages/myself/index.tsx | 1 + src/user_pages/other/index.tsx | 42 ++++++++++++++++++++------------- 2 files changed, 27 insertions(+), 16 deletions(-) diff --git a/src/user_pages/myself/index.tsx b/src/user_pages/myself/index.tsx index 4718a88..af9d3f7 100644 --- a/src/user_pages/myself/index.tsx +++ b/src/user_pages/myself/index.tsx @@ -170,6 +170,7 @@ const MyselfPage: React.FC = () => { const handle_wallet = () => { Taro.navigateTo({ url: "/user_pages/wallet/index", + // url: "/user_pages/other/index?userid=16" }); }; diff --git a/src/user_pages/other/index.tsx b/src/user_pages/other/index.tsx index 84aa223..1e92c07 100644 --- a/src/user_pages/other/index.tsx +++ b/src/user_pages/other/index.tsx @@ -16,12 +16,13 @@ import { UserService, UserInfoType } from "@/services/userService"; import * as LoginService from "@/services/loginService"; import CustomNavbar from "@/components/CustomNavbar"; import { useGlobalState } from "@/store/global"; +import { BackNavbar } from "@/components"; const OtherUserPage: React.FC = () => { // 获取页面参数 const instance = Taro.getCurrentInstance(); const user_id = instance.router?.params?.userid; - if(!user_id) { + if (!user_id) { Taro.showToast({ title: "用户不存在", icon: "none", @@ -87,9 +88,8 @@ const OtherUserPage: React.FC = () => { nickname: userData.nickname || "", avatar_url: userData.avatar_url || "", join_date: userData.subscribe_time - ? `${new Date(userData.subscribe_time).getFullYear()}年${ - new Date(userData.subscribe_time).getMonth() + 1 - }月加入` + ? `${new Date(userData.subscribe_time).getFullYear()}年${new Date(userData.subscribe_time).getMonth() + 1 + }月加入` : "", stats: { following_count: userData.stats?.following_count || 0, @@ -200,12 +200,11 @@ const OtherUserPage: React.FC = () => { // 处理发送消息 const handle_send_message = () => { Taro.navigateTo({ - url: `/mode_user/message/chat/index?user_id=${ - user_info.id || "" - }&nickname=${user_info.nickname || ""}`, + url: `/mode_user/message/chat/index?user_id=${user_info.id || "" + }&nickname=${user_info.nickname || ""}`, }); }; - + const handleOnTab = (tab) => { setActiveTab(tab) } @@ -219,19 +218,28 @@ const OtherUserPage: React.FC = () => { return ( - + {/* Taro.navigateBack()}> - {/* 右侧占位,保持标题居中 */} - + */} + {/* 顶部导航栏 */} + { + Taro.navigateBack(); + }} + /> {/* 主要内容 */} - + {/* 用户信息区域 */} { recommendList={[]} loading={loading} error={null} + isShowNoData={game_records.length === 0} errorImg="ICON_LIST_EMPTY" - emptyText="暂无消息,去互动看看吧" - loadMoreMatches={() => {}} + emptyText="暂无球局信息" + loadMoreMatches={() => { }} collapse={true} style={{ paddingBottom: 0, overflow: "hidden" }} defaultShowNum={3} @@ -306,9 +315,10 @@ const OtherUserPage: React.FC = () => { recommendList={[]} loading={loading} error={null} + isShowNoData={ended_game_records.length === 0} errorImg="ICON_LIST_EMPTY" - emptyText="暂无消息,去互动看看吧" - loadMoreMatches={() => {}} + emptyText="暂无球局信息" + loadMoreMatches={() => { }} collapse={true} style={{ paddingBottom: "90px", overflow: "hidden" }} defaultShowNum={3}