@hed-hog/contact 0.0.270 → 0.0.274

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -162,6 +162,47 @@
162
162
  "avatarRemoveSuccess": "Avatar removido.",
163
163
  "avatarInvalidType": "Selecione um arquivo de imagem válido.",
164
164
  "avatarTooLarge": "A imagem deve ter no máximo 5MB.",
165
+ "owner": "Responsável",
166
+ "unassigned": "Não atribuído",
167
+ "source": "Origem",
168
+ "sourceReferral": "Indicação",
169
+ "sourceWebsite": "Site",
170
+ "sourceSocial": "Social",
171
+ "sourceInbound": "Inbound",
172
+ "sourceOutbound": "Outbound",
173
+ "sourceOther": "Outro",
174
+ "lifecycleStage": "Estágio",
175
+ "lifecycleNew": "Novo",
176
+ "lifecycleContacted": "Contatado",
177
+ "lifecycleQualified": "Qualificado",
178
+ "lifecycleProposal": "Proposta",
179
+ "lifecycleNegotiation": "Negociação",
180
+ "lifecycleCustomer": "Cliente",
181
+ "lifecycleLost": "Perdido",
182
+ "nextActionAt": "Próxima ação",
183
+ "nextActionEmpty": "Sem follow-up",
184
+ "registerInteraction": "Registrar interação",
185
+ "registerInteractionDescription": "Registre o último contato com esta pessoa.",
186
+ "scheduleFollowup": "Agendar follow-up",
187
+ "scheduleFollowupDescription": "Defina data e responsável para a próxima ação.",
188
+ "interactionType": "Tipo de interação",
189
+ "interactionTypeCall": "Ligação",
190
+ "interactionTypeEmail": "E-mail",
191
+ "interactionTypeWhatsapp": "WhatsApp",
192
+ "interactionTypeMeeting": "Reunião",
193
+ "interactionTypeNote": "Nota",
194
+ "interactionDate": "Data da interação",
195
+ "interactionOutcome": "Resultado",
196
+ "interactionOutcomePlaceholder": "Ex: Interessado, pediu proposta...",
197
+ "interactionNotesPlaceholder": "Escreva um resumo rápido...",
198
+ "interactionCreateSuccess": "Interação registrada com sucesso.",
199
+ "interactionCreateError": "Falha ao registrar interação.",
200
+ "nextActionRequired": "A data da próxima ação é obrigatória.",
201
+ "schedule": "Agendar",
202
+ "register": "Registrar",
203
+ "saveAndNew": "Salvar e novo",
204
+ "formShortcutsHint": "Atalhos: Ctrl/Cmd+S para salvar, Esc para fechar.",
205
+ "duplicateWarning": "Possível duplicidade encontrada: {names}.",
165
206
  "createdAt": "Criado em",
166
207
  "close": "Fechar",
167
208
  "copiedToClipboard": "Copiado para a área de transferência!",
@@ -1,17 +1,17 @@
1
- table: person_individual
2
- columns:
3
- - type: pk
4
- references:
5
- table: person
6
- column: id
7
- - name: birth_date
8
- type: date
9
- isNullable: true
10
- - name: gender
11
- type: enum
12
- isNullable: true
13
- values: [male, female, other]
14
- - name: job_title
15
- isNullable: true
16
- - type: created_at
17
- - type: updated_at
1
+ table: person_individual
2
+ columns:
3
+ - type: pk
4
+ references:
5
+ table: person
6
+ column: id
7
+ - name: birth_date
8
+ type: date
9
+ isNullable: true
10
+ - name: gender
11
+ type: enum
12
+ isNullable: true
13
+ values: [male, female, other]
14
+ - name: job_title
15
+ isNullable: true
16
+ - type: created_at
17
+ - type: updated_at
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hed-hog/contact",
3
- "version": "0.0.270",
3
+ "version": "0.0.274",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "dependencies": {
@@ -10,9 +10,9 @@
10
10
  "@nestjs/jwt": "^11",
11
11
  "@nestjs/mapped-types": "*",
12
12
  "@hed-hog/api-prisma": "0.0.5",
13
- "@hed-hog/address": "0.0.270",
13
+ "@hed-hog/address": "0.0.274",
14
14
  "@hed-hog/api-locale": "0.0.13",
15
- "@hed-hog/core": "0.0.270",
15
+ "@hed-hog/core": "0.0.274",
16
16
  "@hed-hog/api-pagination": "0.0.6",
17
17
  "@hed-hog/api-mail": "0.0.8",
18
18
  "@hed-hog/api": "0.0.4"
@@ -7,15 +7,15 @@
7
7
  "documentTypeNotFound": "Document Type not found",
8
8
  "addressTypesNotFound": "Address Types not found",
9
9
  "contactTypesNotFound": "Contact Types not found",
10
- "documentTypesNotFound": "Document Types not found",
11
- "moreThanOnePrimaryContact": "More than one contact of the same type cannot be marked as primary.",
12
- "moreThanOnePrimaryAddress": "More than one address of the same type cannot be marked as primary.",
13
- "moreThanOnePrimaryDocument": "More than one document of the same type cannot be marked as primary.",
14
- "companyRegistrationDisabled": "Company registration is disabled. Only individual records can be created.",
15
- "employeeRelationTypeMissing": "Configure the employee relationship type before linking an individual to a company.",
16
- "employeeRelationSelfReference": "A person cannot be linked as an employee of the same record.",
17
- "employeeCompanyInvalidTarget": "Only company records can be selected as employer.",
18
- "validation": {
10
+ "documentTypesNotFound": "Document Types not found",
11
+ "moreThanOnePrimaryContact": "More than one contact of the same type cannot be marked as primary.",
12
+ "moreThanOnePrimaryAddress": "More than one address of the same type cannot be marked as primary.",
13
+ "moreThanOnePrimaryDocument": "More than one document of the same type cannot be marked as primary.",
14
+ "companyRegistrationDisabled": "Company registration is disabled. Only individual records can be created.",
15
+ "employeeRelationTypeMissing": "Configure the employee relationship type before linking an individual to a company.",
16
+ "employeeRelationSelfReference": "A person cannot be linked as an employee of the same record.",
17
+ "employeeCompanyInvalidTarget": "Only company records can be selected as employer.",
18
+ "validation": {
19
19
  "codeMustBeString": "Code must be a string",
20
20
  "countryCodeMustBeString": "Country code must be a string",
21
21
  "nameMustBeString": "Name must be a string",
@@ -7,15 +7,15 @@
7
7
  "documentTypeNotFound": "Tipo de Documento não encontrado",
8
8
  "addressTypesNotFound": "Tipos de Endereço não encontrados",
9
9
  "contactTypesNotFound": "Tipos de Contato não encontrados",
10
- "documentTypesNotFound": "Tipos de Documento não encontrados",
11
- "moreThanOnePrimaryContact": "Não é permitido mais de um contato do mesmo tipo marcado como principal.",
12
- "moreThanOnePrimaryAddress": "Não é permitido mais de um endereço do mesmo tipo marcado como principal.",
13
- "moreThanOnePrimaryDocument": "Não é permitido mais de um documento do mesmo tipo marcado como principal.",
14
- "companyRegistrationDisabled": "O cadastro de empresas esta desabilitado. Apenas pessoas fisicas podem ser cadastradas.",
15
- "employeeRelationTypeMissing": "Configure o tipo de relacionamento empregado antes de vincular uma pessoa física a uma empresa.",
16
- "employeeRelationSelfReference": "Uma pessoa não pode ser vinculada como empregada do mesmo cadastro.",
17
- "employeeCompanyInvalidTarget": "Apenas cadastros do tipo empresa podem ser selecionados como empregador.",
18
- "validation": {
10
+ "documentTypesNotFound": "Tipos de Documento não encontrados",
11
+ "moreThanOnePrimaryContact": "Não é permitido mais de um contato do mesmo tipo marcado como principal.",
12
+ "moreThanOnePrimaryAddress": "Não é permitido mais de um endereço do mesmo tipo marcado como principal.",
13
+ "moreThanOnePrimaryDocument": "Não é permitido mais de um documento do mesmo tipo marcado como principal.",
14
+ "companyRegistrationDisabled": "O cadastro de empresas esta desabilitado. Apenas pessoas fisicas podem ser cadastradas.",
15
+ "employeeRelationTypeMissing": "Configure o tipo de relacionamento empregado antes de vincular uma pessoa física a uma empresa.",
16
+ "employeeRelationSelfReference": "Uma pessoa não pode ser vinculada como empregada do mesmo cadastro.",
17
+ "employeeCompanyInvalidTarget": "Apenas cadastros do tipo empresa podem ser selecionados como empregador.",
18
+ "validation": {
19
19
  "codeMustBeString": "Código deve ser uma string",
20
20
  "countryCodeMustBeString": "Código do país deve ser uma string",
21
21
  "nameMustBeString": "Nome deve ser uma string",
@@ -1,71 +1,71 @@
1
- import { getLocaleText } from '@hed-hog/api-locale';
2
- import {
3
- IsDateString,
4
- IsEnum,
5
- IsInt,
6
- IsOptional,
7
- IsString,
8
- } from 'class-validator';
1
+ import { getLocaleText } from '@hed-hog/api-locale';
2
+ import {
3
+ IsDateString,
4
+ IsEnum,
5
+ IsInt,
6
+ IsOptional,
7
+ IsString,
8
+ } from 'class-validator';
9
9
 
10
10
  export enum PersonType {
11
11
  INDIVIDUAL = 'individual',
12
12
  COMPANY = 'company'
13
13
  }
14
14
 
15
- export enum PersonStatus {
16
- ACTIVE = 'active',
17
- INACTIVE = 'inactive'
18
- }
19
-
20
- export enum PersonGender {
21
- MALE = 'male',
22
- FEMALE = 'female',
23
- OTHER = 'other'
24
- }
25
-
26
- export class CreateDTO {
27
- @IsString({ message: (args) => getLocaleText('validation.nameMustBeString', args.value) })
28
- name: string;
15
+ export enum PersonStatus {
16
+ ACTIVE = 'active',
17
+ INACTIVE = 'inactive'
18
+ }
19
+
20
+ export enum PersonGender {
21
+ MALE = 'male',
22
+ FEMALE = 'female',
23
+ OTHER = 'other'
24
+ }
25
+
26
+ export class CreateDTO {
27
+ @IsString({ message: (args) => getLocaleText('validation.nameMustBeString', args.value) })
28
+ name: string;
29
29
 
30
30
  @IsEnum(PersonType, { message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
31
31
  type: PersonType;
32
-
33
- @IsEnum(PersonStatus, { message: (args) => getLocaleText('validation.statusMustBeEnum', args.value) })
34
- status: PersonStatus = PersonStatus.ACTIVE;
35
-
36
- @IsOptional()
37
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
38
- avatar_id?: number | null;
39
-
40
- @IsOptional()
41
- @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
42
- birth_date?: string | null;
43
-
44
- @IsOptional()
45
- @IsEnum(PersonGender, { message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
46
- gender?: PersonGender | null;
47
-
48
- @IsOptional()
49
- @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
50
- job_title?: string | null;
51
-
52
- @IsOptional()
53
- @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
54
- trade_name?: string | null;
55
-
56
- @IsOptional()
57
- @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
58
- foundation_date?: string | null;
59
-
60
- @IsOptional()
61
- @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
62
- legal_nature?: string | null;
63
-
64
- @IsOptional()
65
- @IsString({ message: (args) => getLocaleText('validation.notesMustBeString', args.value) })
66
- notes?: string | null;
67
-
68
- @IsOptional()
69
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
70
- employer_company_id?: number | null;
71
- }
32
+
33
+ @IsEnum(PersonStatus, { message: (args) => getLocaleText('validation.statusMustBeEnum', args.value) })
34
+ status: PersonStatus = PersonStatus.ACTIVE;
35
+
36
+ @IsOptional()
37
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
38
+ avatar_id?: number | null;
39
+
40
+ @IsOptional()
41
+ @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
42
+ birth_date?: string | null;
43
+
44
+ @IsOptional()
45
+ @IsEnum(PersonGender, { message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
46
+ gender?: PersonGender | null;
47
+
48
+ @IsOptional()
49
+ @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
50
+ job_title?: string | null;
51
+
52
+ @IsOptional()
53
+ @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
54
+ trade_name?: string | null;
55
+
56
+ @IsOptional()
57
+ @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
58
+ foundation_date?: string | null;
59
+
60
+ @IsOptional()
61
+ @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
62
+ legal_nature?: string | null;
63
+
64
+ @IsOptional()
65
+ @IsString({ message: (args) => getLocaleText('validation.notesMustBeString', args.value) })
66
+ notes?: string | null;
67
+
68
+ @IsOptional()
69
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
70
+ employer_company_id?: number | null;
71
+ }
@@ -1,149 +1,149 @@
1
- import { AddressTypeEnum } from '../../address-type.enum';
2
- import { PersonGender } from './create.dto';
3
- import { getLocaleText } from '@hed-hog/api-locale';
4
- import { Type } from 'class-transformer';
5
- import {
6
- IsArray,
7
- IsBoolean,
8
- IsDateString,
9
- IsEnum,
10
- IsInt,
11
- IsOptional,
12
- IsString,
13
- ValidateNested,
14
- } from 'class-validator';
15
-
16
- export class UpdateAllContactDTO {
17
- @IsOptional()
18
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
19
- id?: number;
20
-
21
- @IsString({ message: (args) => getLocaleText('validation.valueMustBeString', args.value) })
22
- value: string;
23
-
24
- @IsBoolean({ message: (args) => getLocaleText('validation.isPrimaryMustBeBoolean', args.value) })
25
- is_primary: boolean;
26
-
27
- @IsInt({ message: (args) => getLocaleText('validation.contactTypeIdMustBeInteger', args.value) })
28
- contact_type_id: number;
29
- }
30
-
31
- export class UpdateAllAddressDTO {
32
- @IsOptional()
33
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
34
- id?: number;
35
-
36
- @IsString({ message: (args) => getLocaleText('validation.line1MustBeString', args.value) })
37
- line1: string;
38
-
39
- @IsOptional()
40
- @IsString({ message: (args) => getLocaleText('validation.line2MustBeString', args.value) })
41
- line2?: string;
42
-
43
- @IsString({ message: (args) => getLocaleText('validation.cityMustBeString', args.value) })
44
- city: string;
45
-
46
- @IsString({ message: (args) => getLocaleText('validation.stateMustBeString', args.value) })
47
- state: string;
48
-
49
- @IsOptional()
50
- @IsString({ message: (args) => getLocaleText('validation.countryCodeMustBeString', args.value) })
51
- country_code?: string;
52
-
53
- @IsOptional()
54
- @IsString({ message: (args) => getLocaleText('validation.postalCodeMustBeString', args.value) })
55
- postal_code?: string;
56
-
57
- @IsBoolean({ message: (args) => getLocaleText('validation.isPrimaryMustBeBoolean', args.value) })
58
- is_primary: boolean;
59
-
60
- @IsEnum(AddressTypeEnum, {
61
- message: (args) => getLocaleText('validation.addressTypeMustBeEnum', args.value),
62
- })
63
- address_type: AddressTypeEnum;
64
- }
65
-
66
- export class UpdateAllDocumentDTO {
67
- @IsOptional()
68
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
69
- id?: number;
70
-
71
- @IsString({ message: (args) => getLocaleText('validation.valueMustBeString', args.value) })
72
- value: string;
73
-
74
- @IsInt({ message: (args) => getLocaleText('validation.documentTypeIdMustBeInteger', args.value) })
75
- document_type_id: number;
76
- }
77
-
78
- export class UpdateAllPersonDTO {
79
- @IsString({ message: (args) => getLocaleText('validation.nameMustBeString', args.value) })
80
- name: string;
81
-
82
- @IsString({ message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
83
- type: string;
84
-
85
- @IsString({ message: (args) => getLocaleText('validation.statusMustBeEnum', args.value) })
86
- status: string;
87
-
88
- @IsOptional()
89
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
90
- avatar_id?: number | null;
91
-
92
- @IsOptional()
93
- @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
94
- birth_date?: string | null;
95
-
96
- @IsOptional()
97
- @IsEnum(PersonGender, { message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
98
- gender?: PersonGender | null;
99
-
100
- @IsOptional()
101
- @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
102
- job_title?: string | null;
103
-
104
- @IsOptional()
105
- @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
106
- trade_name?: string | null;
107
-
108
- @IsOptional()
109
- @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
110
- foundation_date?: string | null;
111
-
112
- @IsOptional()
113
- @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
114
- legal_nature?: string | null;
115
-
116
- @IsOptional()
117
- @IsString({ message: (args) => getLocaleText('validation.notesMustBeString', args.value) })
118
- notes?: string | null;
119
-
120
- @IsOptional()
121
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
122
- employer_company_id?: number | null;
123
-
124
- @IsOptional()
125
- @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
126
- headquarter_id?: number | null;
127
-
128
- @IsOptional()
129
- @IsArray({ message: (args) => getLocaleText('validation.contactsMustBeArray', args.value) })
130
- @Type(() => Number)
131
- @IsInt({ each: true, message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
132
- branch_ids?: number[];
133
-
134
- @IsArray({ message: (args) => getLocaleText('validation.contactsMustBeArray', args.value) })
135
- @ValidateNested({ each: true })
136
- @Type(() => UpdateAllContactDTO)
137
- contacts: UpdateAllContactDTO[];
138
-
139
- @IsArray({ message: (args) => getLocaleText('validation.addressesMustBeArray', args.value) })
140
- @ValidateNested({ each: true })
141
- @Type(() => UpdateAllAddressDTO)
142
- addresses: UpdateAllAddressDTO[];
143
-
144
- @IsArray({ message: (args) => getLocaleText('validation.documentsMustBeArray', args.value) })
145
- @ValidateNested({ each: true })
146
- @Type(() => UpdateAllDocumentDTO)
147
- documents: UpdateAllDocumentDTO[];
1
+ import { AddressTypeEnum } from '../../address-type.enum';
2
+ import { PersonGender } from './create.dto';
3
+ import { getLocaleText } from '@hed-hog/api-locale';
4
+ import { Type } from 'class-transformer';
5
+ import {
6
+ IsArray,
7
+ IsBoolean,
8
+ IsDateString,
9
+ IsEnum,
10
+ IsInt,
11
+ IsOptional,
12
+ IsString,
13
+ ValidateNested,
14
+ } from 'class-validator';
15
+
16
+ export class UpdateAllContactDTO {
17
+ @IsOptional()
18
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
19
+ id?: number;
20
+
21
+ @IsString({ message: (args) => getLocaleText('validation.valueMustBeString', args.value) })
22
+ value: string;
23
+
24
+ @IsBoolean({ message: (args) => getLocaleText('validation.isPrimaryMustBeBoolean', args.value) })
25
+ is_primary: boolean;
26
+
27
+ @IsInt({ message: (args) => getLocaleText('validation.contactTypeIdMustBeInteger', args.value) })
28
+ contact_type_id: number;
29
+ }
30
+
31
+ export class UpdateAllAddressDTO {
32
+ @IsOptional()
33
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
34
+ id?: number;
35
+
36
+ @IsString({ message: (args) => getLocaleText('validation.line1MustBeString', args.value) })
37
+ line1: string;
38
+
39
+ @IsOptional()
40
+ @IsString({ message: (args) => getLocaleText('validation.line2MustBeString', args.value) })
41
+ line2?: string;
42
+
43
+ @IsString({ message: (args) => getLocaleText('validation.cityMustBeString', args.value) })
44
+ city: string;
45
+
46
+ @IsString({ message: (args) => getLocaleText('validation.stateMustBeString', args.value) })
47
+ state: string;
48
+
49
+ @IsOptional()
50
+ @IsString({ message: (args) => getLocaleText('validation.countryCodeMustBeString', args.value) })
51
+ country_code?: string;
52
+
53
+ @IsOptional()
54
+ @IsString({ message: (args) => getLocaleText('validation.postalCodeMustBeString', args.value) })
55
+ postal_code?: string;
56
+
57
+ @IsBoolean({ message: (args) => getLocaleText('validation.isPrimaryMustBeBoolean', args.value) })
58
+ is_primary: boolean;
59
+
60
+ @IsEnum(AddressTypeEnum, {
61
+ message: (args) => getLocaleText('validation.addressTypeMustBeEnum', args.value),
62
+ })
63
+ address_type: AddressTypeEnum;
64
+ }
65
+
66
+ export class UpdateAllDocumentDTO {
67
+ @IsOptional()
68
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
69
+ id?: number;
70
+
71
+ @IsString({ message: (args) => getLocaleText('validation.valueMustBeString', args.value) })
72
+ value: string;
73
+
74
+ @IsInt({ message: (args) => getLocaleText('validation.documentTypeIdMustBeInteger', args.value) })
75
+ document_type_id: number;
76
+ }
77
+
78
+ export class UpdateAllPersonDTO {
79
+ @IsString({ message: (args) => getLocaleText('validation.nameMustBeString', args.value) })
80
+ name: string;
81
+
82
+ @IsString({ message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
83
+ type: string;
84
+
85
+ @IsString({ message: (args) => getLocaleText('validation.statusMustBeEnum', args.value) })
86
+ status: string;
87
+
88
+ @IsOptional()
89
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
90
+ avatar_id?: number | null;
91
+
92
+ @IsOptional()
93
+ @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
94
+ birth_date?: string | null;
95
+
96
+ @IsOptional()
97
+ @IsEnum(PersonGender, { message: (args) => getLocaleText('validation.typeMustBeEnum', args.value) })
98
+ gender?: PersonGender | null;
99
+
100
+ @IsOptional()
101
+ @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
102
+ job_title?: string | null;
103
+
104
+ @IsOptional()
105
+ @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
106
+ trade_name?: string | null;
107
+
108
+ @IsOptional()
109
+ @IsDateString({}, { message: (args) => getLocaleText('validation.dateMustBeString', args.value) })
110
+ foundation_date?: string | null;
111
+
112
+ @IsOptional()
113
+ @IsString({ message: (args) => getLocaleText('validation.stringRequired', args.value) })
114
+ legal_nature?: string | null;
115
+
116
+ @IsOptional()
117
+ @IsString({ message: (args) => getLocaleText('validation.notesMustBeString', args.value) })
118
+ notes?: string | null;
119
+
120
+ @IsOptional()
121
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
122
+ employer_company_id?: number | null;
123
+
124
+ @IsOptional()
125
+ @IsInt({ message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
126
+ headquarter_id?: number | null;
127
+
128
+ @IsOptional()
129
+ @IsArray({ message: (args) => getLocaleText('validation.contactsMustBeArray', args.value) })
130
+ @Type(() => Number)
131
+ @IsInt({ each: true, message: (args) => getLocaleText('validation.idMustBeInteger', args.value) })
132
+ branch_ids?: number[];
133
+
134
+ @IsArray({ message: (args) => getLocaleText('validation.contactsMustBeArray', args.value) })
135
+ @ValidateNested({ each: true })
136
+ @Type(() => UpdateAllContactDTO)
137
+ contacts: UpdateAllContactDTO[];
138
+
139
+ @IsArray({ message: (args) => getLocaleText('validation.addressesMustBeArray', args.value) })
140
+ @ValidateNested({ each: true })
141
+ @Type(() => UpdateAllAddressDTO)
142
+ addresses: UpdateAllAddressDTO[];
143
+
144
+ @IsArray({ message: (args) => getLocaleText('validation.documentsMustBeArray', args.value) })
145
+ @ValidateNested({ each: true })
146
+ @Type(() => UpdateAllDocumentDTO)
147
+ documents: UpdateAllDocumentDTO[];
148
148
  }
149
149