feat(client): add create user

This commit is contained in:
2025-06-25 13:38:43 +05:00
parent 448e4264a5
commit 8f5dd07bf5
7 changed files with 38 additions and 10 deletions

View File

@@ -1,5 +1,5 @@
import api from '@/api/api';
import { AllUserResponse, User } from '@/types/user';
import { AllUserResponse, User, UserUpdate } from '@/types/user';
export class UserService {
static async getProfile(): Promise<User> {
@@ -23,4 +23,10 @@ export class UserService {
const user = api.getUserById(userId);
return user;
}
static async createUser(user: UserUpdate): Promise<User> {
console.log('createUser');
const createdUser = api.createUser(user);
return createdUser;
}
}