- Backend (NestJS): 82 suites, 641 tests passing; 0 ESLint errors; 0 tsc errors. Hardened SSL cert/key matching, SSRF IP pinning, and eBank validation. - Admin Panel (Vite/React): 48 suites, 300 tests passing; 0 ESLint errors; 0 tsc errors. Full coverage across all pages and settings. - Storefront (Next.js): 62 suites, 368 tests passing; 0 ESLint errors; 0 tsc errors. - Fixed unmount lifecycle guards, promise error handling, and component edge cases.
36 lines
1.0 KiB
TypeScript
36 lines
1.0 KiB
TypeScript
import { ApiPropertyOptional } from "@nestjs/swagger";
|
|
import { IsOptional, IsString, IsEmail, MinLength } from "class-validator";
|
|
|
|
export class UpdateProfileDto {
|
|
@ApiPropertyOptional({ description: "نام کاربر" })
|
|
@IsOptional()
|
|
@IsString()
|
|
firstName?: string;
|
|
|
|
@ApiPropertyOptional({ description: "نام خانوادگی کاربر" })
|
|
@IsOptional()
|
|
@IsString()
|
|
lastName?: string;
|
|
|
|
@ApiPropertyOptional({ description: "ایمیل کاربر" })
|
|
@IsOptional()
|
|
@IsEmail({}, { message: "ایمیل نامعتبر است" })
|
|
email?: string;
|
|
|
|
@ApiPropertyOptional({ description: "شماره موبایل کاربر" })
|
|
@IsOptional()
|
|
@IsString()
|
|
mobile?: string;
|
|
|
|
@ApiPropertyOptional({ description: "رمز عبور جدید" })
|
|
@IsOptional()
|
|
@IsString()
|
|
@MinLength(6, { message: "رمز عبور باید حداقل ۶ کاراکتر باشد" })
|
|
password?: string;
|
|
|
|
@ApiPropertyOptional({ description: "رمز عبور فعلی (در صورت وجود)" })
|
|
@IsOptional()
|
|
@IsString()
|
|
currentPassword?: string;
|
|
}
|