mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-13 19:30:30 +00:00
refactor: mail templates
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
import { ArrayMinSize, IsArray, IsNotEmpty, IsObject, IsString } from "class-validator";
|
||||
import { AddressItem } from "../MailNotification.types";
|
||||
|
||||
export class CommonMailOptionsDto {
|
||||
@IsArray()
|
||||
@ArrayMinSize(1)
|
||||
@IsNotEmpty()
|
||||
from: Array<string>;
|
||||
|
||||
@IsString()
|
||||
@IsNotEmpty()
|
||||
subject: string;
|
||||
|
||||
@IsString()
|
||||
@IsNotEmpty()
|
||||
message: string;
|
||||
|
||||
@IsArray()
|
||||
@ArrayMinSize(1)
|
||||
@IsNotEmpty()
|
||||
to: Array<string>;
|
||||
|
||||
@IsArray()
|
||||
cc?: Array<string>;
|
||||
|
||||
@IsArray()
|
||||
bcc?: Array<string>;
|
||||
|
||||
@IsObject()
|
||||
formatArgs?: Record<string, any>;
|
||||
|
||||
@IsArray()
|
||||
toOptions: Array<AddressItem>;
|
||||
|
||||
@IsArray()
|
||||
fromOptions: Array<AddressItem>;
|
||||
}
|
||||
Reference in New Issue
Block a user