2016-05-03 20:29:24 +08:00
|
|
|
import {User, UserRoles} from "../../common/entities/User";
|
2016-04-22 19:23:44 +08:00
|
|
|
export interface IUserManager {
|
2016-12-27 06:36:38 +08:00
|
|
|
findOne(filter: any, cb: (error: any, result: User) => void): void;
|
|
|
|
find(filter: any, cb: (error: any, result: Array<User>) => void): void;
|
|
|
|
createUser(user: User, cb: (error: any, result: User) => void): void;
|
|
|
|
deleteUser(id: number, cb: (error: any, result: string) => void): void;
|
|
|
|
changeRole(id: number, newRole: UserRoles, cb: (error: any) => void): void;
|
|
|
|
changePassword(request: any, cb: (error: any, result: string) => void): void;
|
2016-04-22 19:23:44 +08:00
|
|
|
}
|