feat(client): add userEdit
This commit is contained in:
@@ -3,7 +3,7 @@ import axiosRetry from 'axios-retry';
|
||||
import { Auth, Tokens } from '@/types/auth';
|
||||
import { useAuthStore } from '@/store/authStore';
|
||||
import { AuthService } from '@/services/authService';
|
||||
import { User, UserCreate } from '@/types/user';
|
||||
import { User, UserCreate, UserUpdate } from '@/types/user';
|
||||
|
||||
const baseURL = `${import.meta.env.VITE_APP_HTTP_PROTOCOL}://${
|
||||
import.meta.env.VITE_APP_API_URL
|
||||
@@ -119,8 +119,12 @@ const api = {
|
||||
return response.data;
|
||||
},
|
||||
|
||||
async updateUser(userId: number, user: UserUpdate): Promise<User> {
|
||||
const response = await base.put<User>(`/account/${userId}`, user);
|
||||
return response.data;
|
||||
},
|
||||
|
||||
// keyrings
|
||||
async setPassword(userId: number, password: string): Promise<any> {},
|
||||
};
|
||||
|
||||
export default api;
|
||||
|
Reference in New Issue
Block a user