mirror of
https://github.com/astuto/astuto.git
synced 2025-12-16 11:47:56 +01:00
Add users management to site settings (#126)
This commit is contained in:
committed by
GitHub
parent
bc15140512
commit
37fb99a868
29
app/javascript/interfaces/IUser.ts
Normal file
29
app/javascript/interfaces/IUser.ts
Normal file
@@ -0,0 +1,29 @@
|
||||
// Roles
|
||||
export const USER_ROLE_USER = 'user';
|
||||
export const USER_ROLE_MODERATOR = 'moderator';
|
||||
export const USER_ROLE_ADMIN = 'admin';
|
||||
|
||||
export type UserRoles =
|
||||
typeof USER_ROLE_USER |
|
||||
typeof USER_ROLE_MODERATOR |
|
||||
typeof USER_ROLE_ADMIN;
|
||||
|
||||
// Statuses
|
||||
export const USER_STATUS_ACTIVE = 'active';
|
||||
export const USER_STATUS_BLOCKED = 'blocked';
|
||||
export const USER_STATUS_DELETED = 'deleted';
|
||||
|
||||
export type UserStatuses =
|
||||
typeof USER_STATUS_ACTIVE |
|
||||
typeof USER_STATUS_BLOCKED |
|
||||
typeof USER_STATUS_DELETED;
|
||||
|
||||
interface IUser {
|
||||
id: number;
|
||||
email: string;
|
||||
fullName: string;
|
||||
role: UserRoles;
|
||||
status: UserStatuses;
|
||||
}
|
||||
|
||||
export default IUser;
|
||||
Reference in New Issue
Block a user