“提交项目”

This commit is contained in:
2026-03-03 14:41:39 +08:00
commit afffb8340c
127 changed files with 12504 additions and 0 deletions

29
ui/src/api/auth.js Normal file
View File

@@ -0,0 +1,29 @@
import { http } from './http'
export async function getCaptcha() {
const { data } = await http.get('/api/auth/captcha')
return data.data
}
export async function login(req) {
const { data } = await http.post('/api/auth/login', req)
return data.data
}
export async function register(req) {
const { data } = await http.post('/api/auth/register', req)
return data.data
}
export async function me() {
const { data } = await http.get('/api/auth/me')
return data.data
}
export async function updateProfile(data) {
await http.post('/api/auth/profile', data)
}
export async function updatePassword(data) {
await http.post('/api/auth/password', data)
}