mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 22:00:31 +00:00
WIP
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
import { DATATYPES_LENGTH } from '@/data/DataTypes';
|
||||
import { IsInt, IsOptional, IsString, Length, Min, Max } from 'class-validator';
|
||||
|
||||
export class AccountDTOSchema {
|
||||
@IsString()
|
||||
@Length(3, DATATYPES_LENGTH.STRING)
|
||||
name: string;
|
||||
|
||||
// @IsString()
|
||||
// @IsInt()
|
||||
@IsOptional()
|
||||
// @Length(3, 6)
|
||||
code?: string;
|
||||
|
||||
@IsOptional()
|
||||
currencyCode?: string;
|
||||
|
||||
@IsString()
|
||||
@Length(3, DATATYPES_LENGTH.STRING)
|
||||
accountType: string;
|
||||
|
||||
@IsString()
|
||||
@IsOptional()
|
||||
@Length(0, DATATYPES_LENGTH.TEXT)
|
||||
description?: string;
|
||||
|
||||
@IsInt()
|
||||
@IsOptional()
|
||||
@Min(0)
|
||||
@Max(DATATYPES_LENGTH.INT_10)
|
||||
parentAccountId?: number;
|
||||
}
|
||||
Reference in New Issue
Block a user