@silexpert/core 2.0.64 → 2.0.65

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.
Files changed (34) hide show
  1. package/dist/api/resources/Docoon.d.ts +2 -1
  2. package/dist/api/resources/Docoon.d.ts.map +1 -1
  3. package/dist/api/resources/Docoon.js +3 -0
  4. package/dist/api/resources/Docoon.js.map +1 -1
  5. package/dist/types/Enum/EInvoicingReasonType.d.ts +104 -29
  6. package/dist/types/Enum/EInvoicingReasonType.d.ts.map +1 -1
  7. package/dist/types/Enum/EInvoicingReasonType.js +482 -108
  8. package/dist/types/Enum/EInvoicingReasonType.js.map +1 -1
  9. package/dist/types/Interface/api/docoon/Create.d.ts +2 -2
  10. package/dist/types/Interface/api/docoon/Create.d.ts.map +1 -1
  11. package/dist/types/Interface/api/docoon/Create.js.map +1 -1
  12. package/dist/types/Interface/api/docoon/Read.d.ts +43 -27
  13. package/dist/types/Interface/api/docoon/Read.d.ts.map +1 -1
  14. package/dist/types/Interface/api/docoon/Read.js.map +1 -1
  15. package/dist/types/Interface/api/humanResourceLibrary/CreateHumanResourceLibrary.d.ts +1 -1
  16. package/dist/types/Interface/api/humanResourceLibrary/CreateHumanResourceLibrary.d.ts.map +1 -1
  17. package/dist/types/Interface/api/humanResourceLibrary/CreateHumanResourceLibrary.js +18 -4
  18. package/dist/types/Interface/api/humanResourceLibrary/CreateHumanResourceLibrary.js.map +1 -1
  19. package/dist/types/Interface/api/registration/DeclareRegistration.d.ts +1 -0
  20. package/dist/types/Interface/api/registration/DeclareRegistration.d.ts.map +1 -1
  21. package/dist/types/Interface/api/registration/DeclareRegistration.js +8 -0
  22. package/dist/types/Interface/api/registration/DeclareRegistration.js.map +1 -1
  23. package/dist/utils/index.d.ts +1 -0
  24. package/dist/utils/index.d.ts.map +1 -1
  25. package/dist/utils/index.js +1 -0
  26. package/dist/utils/index.js.map +1 -1
  27. package/package.json +1 -1
  28. package/ts/api/resources/Docoon.ts +5 -0
  29. package/ts/types/Enum/EInvoicingReasonType.ts +487 -110
  30. package/ts/types/Interface/api/docoon/Create.ts +2 -2
  31. package/ts/types/Interface/api/docoon/Read.ts +46 -27
  32. package/ts/types/Interface/api/humanResourceLibrary/CreateHumanResourceLibrary.ts +18 -4
  33. package/ts/types/Interface/api/registration/DeclareRegistration.ts +6 -0
  34. package/ts/utils/index.ts +1 -0
@@ -94,6 +94,51 @@ export interface ReadDirectoryLine {
94
94
  identite_etablissement?: string;
95
95
  }
96
96
 
97
+ export interface ReadClientDirectoryLine {
98
+ search: QuerySearchDirectoryLine;
99
+ totalNumberOfResults: number;
100
+ results: ReadDirectoryLineResult[];
101
+ }
102
+ export interface ReadDocoonStructure {
103
+ id: string;
104
+ code: string | null;
105
+ name: string | null;
106
+ tenantId: string;
107
+ legalId: string;
108
+ legalIdSchemeId: string;
109
+ isEnabled: boolean;
110
+ parentStructureId: string;
111
+ countryCode: string | null;
112
+ startDate: string | null;
113
+ endDate: string | null;
114
+ structureType: string | null;
115
+ address: {
116
+ name: string | null;
117
+ street: string | null;
118
+ zipCode: string | null;
119
+ postBox: string | null;
120
+ city: string | null;
121
+ additionalInfo: string | null;
122
+ country: string | null;
123
+ };
124
+ mainActivity: {
125
+ name: string | null;
126
+ code: string | null;
127
+ };
128
+ }
129
+
130
+ export interface ReadDocoonAddStructure {
131
+ data: {
132
+ addStructure: ReadDocoonStructure;
133
+ };
134
+ }
135
+
136
+ export interface ReadDocoonStructureResponse {
137
+ data: {
138
+ structureItems: ReadDocoonStructure[];
139
+ };
140
+ }
141
+
97
142
  export interface ReadDocoonLegalEntity {
98
143
  id: string;
99
144
  code: string;
@@ -111,33 +156,7 @@ export interface ReadDocoonLegalEntity {
111
156
  personType: 'PRIVATE_PERSON' | 'MORAL_PERSON_PRIVATE' | 'MORAL_PERSON_PUBLIC';
112
157
  primaryStructureId: string;
113
158
  parentStructureId: string | null;
114
- structures: {
115
- id: string;
116
- code: string | null;
117
- name: string | null;
118
- tenantId: string;
119
- legalId: string;
120
- legalIdSchemeId: string;
121
- isEnabled: boolean;
122
- parentStructureId: string;
123
- countryCode: string | null;
124
- startDate: string | null;
125
- endDate: string | null;
126
- structureType: string | null;
127
- address: {
128
- name: string | null;
129
- street: string | null;
130
- zipCode: string | null;
131
- postBox: string | null;
132
- city: string | null;
133
- additionalInfo: string | null;
134
- country: string | null;
135
- };
136
- mainActivity: {
137
- name: string | null;
138
- code: string | null;
139
- };
140
- }[];
159
+ structures: ReadDocoonStructure[];
141
160
  pdpProperties: {
142
161
  isVerified: boolean;
143
162
  isMandated: boolean;
@@ -1,4 +1,5 @@
1
- import { IsBoolean, IsInt, IsOptional, IsString } from 'class-validator';
1
+ import { IsArray, IsBoolean, IsInt, IsOptional, IsString } from 'class-validator';
2
+ import { Transform } from 'class-transformer';
2
3
  import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
3
4
  import { ToBoolean } from '../../../../utils/transforms/boolean.transform.js';
4
5
  import { DocumentForHumanResourceType } from '../../../Enum/DocumentForHumanResourceType.js';
@@ -25,10 +26,23 @@ export class CreateHumanResourceLibrary {
25
26
  @IsOptional()
26
27
  idRole?: number;
27
28
 
28
- @ApiPropertyOptional()
29
+ @ApiPropertyOptional({ type: [Number] })
29
30
  @IsOptional()
30
- @IsInt()
31
- idUser?: number;
31
+ @Transform(({ value }: { value: any }) => {
32
+ if (Array.isArray(value)) {
33
+ return value.map((v) => Number(v));
34
+ }
35
+ if (value === null || value === undefined || value === '') {
36
+ return undefined;
37
+ }
38
+ if (typeof value === 'string' && value.includes(',')) {
39
+ return value.split(',').map((v) => Number(v.trim()));
40
+ }
41
+ return [Number(value)];
42
+ })
43
+ @IsArray()
44
+ @IsInt({ each: true })
45
+ idUser?: number[];
32
46
 
33
47
  @ApiPropertyOptional()
34
48
  @IsOptional()
@@ -37,6 +37,12 @@ export class ProcessVatRegistration {
37
37
  @ToBoolean()
38
38
  isTestMode?: boolean;
39
39
 
40
+ @ApiPropertyOptional()
41
+ @IsOptional()
42
+ @IsBoolean()
43
+ @ToBoolean()
44
+ debug?: boolean;
45
+
40
46
  @ApiProperty()
41
47
  @IsNumber()
42
48
  state: CustomerVatState;
package/ts/utils/index.ts CHANGED
@@ -21,3 +21,4 @@ export * from './commercialOffer.js';
21
21
  export * from './societyApproval.js';
22
22
  export * from './commercialManagement/saleEmail.js';
23
23
  export * from './transforms/boolean.transform.js';
24
+ export * from './transforms/number.transform.js';