2021-07-03 21:48:27 +00:00
|
|
|
export interface IUser {
|
|
|
|
id?: number;
|
|
|
|
login?: string;
|
2021-07-07 04:53:02 +00:00
|
|
|
firstName?: string | null;
|
|
|
|
lastName?: string | null;
|
|
|
|
email?: string;
|
|
|
|
authorities?: string[];
|
2021-07-03 21:48:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
export class User implements IUser {
|
2021-07-07 04:53:02 +00:00
|
|
|
constructor(
|
|
|
|
public id: number,
|
|
|
|
public login: string,
|
|
|
|
public firstName?: string,
|
|
|
|
public lastName?: string,
|
|
|
|
public email?: string,
|
|
|
|
public authorities?: string[]
|
|
|
|
) {}
|
2021-07-03 21:48:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
export function getUserIdentifier(user: IUser): number | undefined {
|
|
|
|
return user.id;
|
|
|
|
}
|