优化
This commit is contained in:
@@ -16,8 +16,10 @@ import { UserService, UserInfoType } from "@/services/userService";
|
||||
import * as LoginService from "@/services/loginService";
|
||||
import { useGlobalState } from "@/store/global";
|
||||
import { GeneralNavbar } from "@/components";
|
||||
import { useUserActions } from "@/store/userStore";
|
||||
|
||||
const OtherUserPage: React.FC = () => {
|
||||
const { fetchUserInfo } = useUserActions();
|
||||
// 获取页面参数
|
||||
const instance = Taro.getCurrentInstance();
|
||||
const user_id = instance.router?.params?.userid;
|
||||
@@ -182,6 +184,7 @@ const OtherUserPage: React.FC = () => {
|
||||
is_following
|
||||
);
|
||||
setIsFollowing(new_follow_status);
|
||||
fetchUserInfo()
|
||||
Taro.showToast({
|
||||
title: new_follow_status ? "关注成功" : "已取消关注",
|
||||
icon: "success",
|
||||
@@ -237,7 +240,7 @@ const OtherUserPage: React.FC = () => {
|
||||
}}
|
||||
/>
|
||||
{/* 主要内容 */}
|
||||
<View
|
||||
<View
|
||||
className="other_main_content"
|
||||
style={{ paddingTop: `${totalHeight}px` }}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user