chore: contact us module
This commit is contained in:
@@ -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: "عنوان پیام" })
|
||||
|
||||
Reference in New Issue
Block a user