mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-07-16 18:56:22 +00:00
55 lines
1011 B
TypeScript
55 lines
1011 B
TypeScript
import { RoleType } from '@app/common/constants/role.type.enum';
|
|
import { UserStatusEnum } from '@app/common/constants/user-status.enum';
|
|
import { IsEnum, IsNotEmpty, IsOptional, IsString } from 'class-validator';
|
|
|
|
export class InviteUserDto {
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public uuid: string;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public email: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
public jobTitle?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
public companyName?: string;
|
|
|
|
@IsEnum(UserStatusEnum)
|
|
@IsNotEmpty()
|
|
public status: UserStatusEnum;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public firstName: string;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public lastName: string;
|
|
|
|
@IsEnum(RoleType)
|
|
@IsNotEmpty()
|
|
public invitedBy: RoleType;
|
|
}
|
|
export class InviteUserSpaceDto {
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public uuid: string;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public inviteUserUuid: string;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public spaceUuid: string;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
public invitationCode: string;
|
|
}
|