修正帖子列表、帖子详情的头像与名字显示问题
Change-Id: Ibcb01510f9474ea43c8739f3013c3aaa32e32640
diff --git a/Merge/front/src/api/api_ljc.js b/Merge/front/src/api/api_ljc.js
index b8130ca..1adea99 100644
--- a/Merge/front/src/api/api_ljc.js
+++ b/Merge/front/src/api/api_ljc.js
@@ -1,4 +1,5 @@
import axios from 'axios';
+import { getUserInfo } from '../utils/auth';
const api = axios.create({
baseURL: 'http://10.126.59.25:5715/api/',
@@ -14,8 +15,12 @@
export const getFavorites = (userId) => api.get(`/user/${userId}/favorites`);
// 关注相关API
-export const followUser = (followeeId) => api.post(`/follow/${followeeId}`);
-export const unfollowUser = (followeeId) => api.delete(`/follow/${followeeId}`);
+export const followUser = (followeeId) => {
+ return api.post(`/follow/${followeeId}`);
+};
+export const unfollowUser = (followeeId) => {
+ return api.delete(`/follow/${followeeId}`);
+};
// 帖子相关API
export const getUserPosts = (userId) => api.get(`/user/${userId}/posts`);
diff --git a/Merge/front/src/api/posts_api.js b/Merge/front/src/api/posts_api.js
index a336da0..06cf2c7 100644
--- a/Merge/front/src/api/posts_api.js
+++ b/Merge/front/src/api/posts_api.js
@@ -2,7 +2,7 @@
// 整合不同后端服务的帖子功能
// WZY 后端服务 - 帖子CRUD、点赞、评论
-const WZY_BASE_URL = 'http://10.126.59.25:5714'
+const WZY_BASE_URL = 'http://192.168.5.235:5714'
// LJC 后端服务 - 用户相关功能
const LJC_BASE_URL = 'http://10.126.59.25:5715'
diff --git a/Merge/front/src/api/search_jwlll.js b/Merge/front/src/api/search_jwlll.js
index 085507b..01b743f 100644
--- a/Merge/front/src/api/search_jwlll.js
+++ b/Merge/front/src/api/search_jwlll.js
@@ -5,7 +5,7 @@
// JWLLL 后端服务 - 仅用于推荐和搜索
const JWLLL_BASE_URL = 'http://10.126.59.25:5717'
// WZY 后端服务 - 用于帖子详情、点赞、评论等
-const WZY_BASE_URL = 'http://10.126.59.25:5714'
+const WZY_BASE_URL = 'http://192.168.5.235:5714'
// 通用请求函数
const request = async (url, options = {}) => {