chore: contact us module

This commit is contained in:
Matin
2025-02-04 14:05:37 +03:30
parent c12e0fb4d4
commit 5e9561b417
7 changed files with 34 additions and 64 deletions
@@ -1,9 +1,19 @@
import { ApiProperty } from "@nestjs/swagger";
import { IsNotEmpty, IsString } from "class-validator";
import { IsEmail, IsNotEmpty, IsString } from "class-validator";
import { ContactUsMessage } from "../../../common/enums/message.enum";
export class CreateContactUsDto {
@IsNotEmpty({ message: ContactUsMessage.FULLNAME_IS_REQUIRED })
@IsString({ message: ContactUsMessage.FULLNAME_STRING })
@ApiProperty({ description: "full name of person need to create contact us", example: "متین جمشیدی" })
fullName: string;
@IsNotEmpty({ message: ContactUsMessage.FULLNAME_STRING })
@IsEmail()
@ApiProperty({ description: "email of person need to contact us", example: "matin@gmail.com" })
email: string;
@IsNotEmpty({ message: ContactUsMessage.TITLE_IS_REQUIRED })
@IsString({ message: ContactUsMessage.TITLE_STRING })
@ApiProperty({ description: "title of contact us", example: "عنوان پیام" })