refactor(biji): 更新 API基础路径和相关调用
- 将 VITE_API_BASE_URL 从 https://biji-houdaun.311169.xyz 修改为 /api- 更新前端 API 调用路径,统一添加 /api前缀 - 修改后端 SecurityConfig 和 SystemController,以适应新的 API 路径
This commit is contained in:
@@ -136,11 +136,11 @@ export const validateToken = () => axiosApi.post('/api/user/validate-token');
|
||||
|
||||
// System APIs
|
||||
export const getRegistrationStatus = () => {
|
||||
return axiosApi.get('/system/registration/status');
|
||||
return axiosApi.get('/api/system/registration/status');
|
||||
};
|
||||
|
||||
export const toggleRegistration = (enabled) => {
|
||||
return axiosApi.post('/system/registration/toggle', enabled, {
|
||||
return axiosApi.post('/api/system/registration/toggle', enabled, {
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
}
|
||||
@@ -148,7 +148,7 @@ export const toggleRegistration = (enabled) => {
|
||||
};
|
||||
|
||||
export const generateRegistrationCode = () => {
|
||||
return axiosApi.post('/system/registration/generate-code');
|
||||
return axiosApi.post('/api/system/registration/generate-code');
|
||||
};
|
||||
|
||||
// 更新密码
|
||||
|
||||
Reference in New Issue
Block a user