pl4y-data-library
Version:
This library contains the dtos, enums, schemas, and other data objects needed in the pl4y ecosystem.
100 lines (78 loc) • 1.62 kB
text/typescript
import {
IsBoolean,
IsEmail,
IsNotEmpty,
IsNumber,
IsOptional,
IsPhoneNumber,
IsString,
MinLength,
ValidateNested,
} from "class-validator";
import { Type } from "class-transformer";
import { Role } from "../../enums/roles.enum";
import { Address } from "./address.dto";
import { UserType } from "../../enums/user-types.enum";
export class User {
_id?: string;
id?: string;
first_name: string;
last_name: string;
email: string;
phone?: string;
password: string;
isAdmin?: boolean;
picture?: string;
balance: number;
tenantId: string;
refreshToken?: string;
hasShippingAddress?: boolean;
role: Role;
status?: string;
membership?: string;
billingAddress: Address;
shippingAddress: Address;
parentId?: string;
type?: UserType;
rate?: number;
session_location?: string;
}