@silexpert/core 1.3.158-1 → 1.3.158-11

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 (65) hide show
  1. package/dist/cjs/api/resources/Report.d.ts.map +1 -1
  2. package/dist/cjs/api/resources/Report.js +12 -1
  3. package/dist/cjs/api/resources/Report.js.map +1 -1
  4. package/dist/cjs/types/Enum/ReportService.js +20 -20
  5. package/dist/cjs/types/Enum/ReportService.js.map +1 -1
  6. package/dist/cjs/types/Enum/ReportSource.d.ts +2 -1
  7. package/dist/cjs/types/Enum/ReportSource.d.ts.map +1 -1
  8. package/dist/cjs/types/Enum/ReportSource.js +5 -0
  9. package/dist/cjs/types/Enum/ReportSource.js.map +1 -1
  10. package/dist/cjs/types/Enum/ReportType.d.ts +9 -1
  11. package/dist/cjs/types/Enum/ReportType.d.ts.map +1 -1
  12. package/dist/cjs/types/Enum/ReportType.js +41 -1
  13. package/dist/cjs/types/Enum/ReportType.js.map +1 -1
  14. package/dist/cjs/types/Interface/api/report/CreateReport.d.ts +2 -0
  15. package/dist/cjs/types/Interface/api/report/CreateReport.d.ts.map +1 -1
  16. package/dist/cjs/types/Interface/api/report/CreateReport.js +18 -0
  17. package/dist/cjs/types/Interface/api/report/CreateReport.js.map +1 -1
  18. package/dist/cjs/types/Interface/api/report/ExternalReport.d.ts +1 -1
  19. package/dist/cjs/types/Interface/api/report/ExternalReport.d.ts.map +1 -1
  20. package/dist/cjs/types/Interface/api/report/ExternalReport.js +5 -5
  21. package/dist/cjs/types/Interface/api/report/ExternalReport.js.map +1 -1
  22. package/dist/cjs/types/Interface/api/report/QueryReports.d.ts +4 -0
  23. package/dist/cjs/types/Interface/api/report/QueryReports.d.ts.map +1 -1
  24. package/dist/cjs/types/Interface/api/report/QueryReports.js +20 -0
  25. package/dist/cjs/types/Interface/api/report/QueryReports.js.map +1 -1
  26. package/dist/cjs/types/Interface/models/IReport.d.ts +3 -0
  27. package/dist/cjs/types/Interface/models/IReport.d.ts.map +1 -1
  28. package/dist/cjs/types/Interface/models/IReport.js.map +1 -1
  29. package/dist/mjs/api/resources/Report.d.ts.map +1 -1
  30. package/dist/mjs/api/resources/Report.js +12 -1
  31. package/dist/mjs/api/resources/Report.js.map +1 -1
  32. package/dist/mjs/types/Enum/ReportService.js +20 -20
  33. package/dist/mjs/types/Enum/ReportService.js.map +1 -1
  34. package/dist/mjs/types/Enum/ReportSource.d.ts +2 -1
  35. package/dist/mjs/types/Enum/ReportSource.d.ts.map +1 -1
  36. package/dist/mjs/types/Enum/ReportSource.js +5 -0
  37. package/dist/mjs/types/Enum/ReportSource.js.map +1 -1
  38. package/dist/mjs/types/Enum/ReportType.d.ts +9 -1
  39. package/dist/mjs/types/Enum/ReportType.d.ts.map +1 -1
  40. package/dist/mjs/types/Enum/ReportType.js +41 -1
  41. package/dist/mjs/types/Enum/ReportType.js.map +1 -1
  42. package/dist/mjs/types/Interface/api/report/CreateReport.d.ts +2 -0
  43. package/dist/mjs/types/Interface/api/report/CreateReport.d.ts.map +1 -1
  44. package/dist/mjs/types/Interface/api/report/CreateReport.js +20 -0
  45. package/dist/mjs/types/Interface/api/report/CreateReport.js.map +1 -1
  46. package/dist/mjs/types/Interface/api/report/ExternalReport.d.ts +1 -1
  47. package/dist/mjs/types/Interface/api/report/ExternalReport.d.ts.map +1 -1
  48. package/dist/mjs/types/Interface/api/report/ExternalReport.js +5 -7
  49. package/dist/mjs/types/Interface/api/report/ExternalReport.js.map +1 -1
  50. package/dist/mjs/types/Interface/api/report/QueryReports.d.ts +4 -0
  51. package/dist/mjs/types/Interface/api/report/QueryReports.d.ts.map +1 -1
  52. package/dist/mjs/types/Interface/api/report/QueryReports.js +23 -1
  53. package/dist/mjs/types/Interface/api/report/QueryReports.js.map +1 -1
  54. package/dist/mjs/types/Interface/models/IReport.d.ts +3 -0
  55. package/dist/mjs/types/Interface/models/IReport.d.ts.map +1 -1
  56. package/dist/mjs/types/Interface/models/IReport.js.map +1 -1
  57. package/package.json +1 -1
  58. package/ts/api/resources/Report.ts +11 -1
  59. package/ts/types/Enum/ReportService.ts +4 -4
  60. package/ts/types/Enum/ReportSource.ts +5 -0
  61. package/ts/types/Enum/ReportType.ts +41 -1
  62. package/ts/types/Interface/api/report/CreateReport.ts +16 -0
  63. package/ts/types/Interface/api/report/ExternalReport.ts +4 -4
  64. package/ts/types/Interface/api/report/QueryReports.ts +17 -1
  65. package/ts/types/Interface/models/IReport.ts +3 -0
@@ -22,6 +22,14 @@ export enum ReportTypeEnum {
22
22
  VOLONTARY_UNPAID = 19,
23
23
  LACK_OF_COMMUNICATION = 20,
24
24
  LACK_OF_ADVICE = 21,
25
+ LAWYER = 22,
26
+ JURIDICAL_PROTECTION = 23,
27
+ TAXES = 24,
28
+ VAT = 25,
29
+ VAT_DELAYS = 26,
30
+ BALANCE_SHEET = 27,
31
+ THREAT = 28,
32
+ LOGICIEL = 29,
25
33
  }
26
34
 
27
35
  interface ReportTypeInterface {
@@ -32,7 +40,7 @@ interface ReportTypeInterface {
32
40
  export const ReportType: { [key: string]: ReportTypeInterface } = {
33
41
  LETTER: {
34
42
  id: ReportTypeEnum.LETTER,
35
- name: 'Lettre à l\'ordre',
43
+ name: "Lettre à l'ordre",
36
44
  },
37
45
  FRAUD: {
38
46
  id: ReportTypeEnum.FRAUD,
@@ -114,6 +122,38 @@ export const ReportType: { [key: string]: ReportTypeInterface } = {
114
122
  id: ReportTypeEnum.LACK_OF_ADVICE,
115
123
  name: 'Manque de conseil',
116
124
  },
125
+ LAWYER: {
126
+ id: ReportTypeEnum.LAWYER,
127
+ name: 'Avocat',
128
+ },
129
+ JURIDICAL_PROTECTION: {
130
+ id: ReportTypeEnum.JURIDICAL_PROTECTION,
131
+ name: 'Protection juridique',
132
+ },
133
+ TAXES: {
134
+ id: ReportTypeEnum.TAXES,
135
+ name: 'Impôts',
136
+ },
137
+ VAT: {
138
+ id: ReportTypeEnum.VAT,
139
+ name: 'TVA',
140
+ },
141
+ VAT_DELAYS: {
142
+ id: ReportTypeEnum.VAT_DELAYS,
143
+ name: 'Retard de TVA',
144
+ },
145
+ BALANCE_SHEET: {
146
+ id: ReportTypeEnum.BALANCE_SHEET,
147
+ name: 'Bilan',
148
+ },
149
+ THREAT: {
150
+ id: ReportTypeEnum.THREAT,
151
+ name: 'Menace de poursuite (Ordre, Avocats, etc...)',
152
+ },
153
+ LOGICIEL: {
154
+ id: ReportTypeEnum.LOGICIEL,
155
+ name: 'Logiciel',
156
+ },
117
157
  } as const;
118
158
 
119
159
  export interface ReportExternalCategoryInterface {
@@ -2,10 +2,22 @@ import { IsInt, IsOptional, IsString } from 'class-validator';
2
2
  import { IReport } from '../../..';
3
3
  import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
4
4
  import { TFile } from '../file/TFile';
5
+ import { Transform } from 'class-transformer';
5
6
 
6
7
  export class CreateReport implements IReport {
8
+ @ApiProperty()
9
+ @IsInt()
10
+ idSource: number;
11
+
7
12
  @ApiPropertyOptional()
8
13
  @IsOptional()
14
+ @Transform(({ value }) => {
15
+ if (typeof value === 'string') {
16
+ return value.split(',').map((v) => Number(v.trim()));
17
+ }
18
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-return
19
+ return value;
20
+ })
9
21
  @IsInt({ each: true })
10
22
  idReportType?: number[];
11
23
 
@@ -68,6 +80,10 @@ export class CreateReport implements IReport {
68
80
  @IsOptional()
69
81
  letterDate?: Date;
70
82
 
83
+ @ApiPropertyOptional()
84
+ @IsOptional()
85
+ receivedAt?: Date;
86
+
71
87
  @ApiPropertyOptional()
72
88
  @IsOptional()
73
89
  receivedFile?: TFile;
@@ -1,7 +1,7 @@
1
1
  import { IsEnum, IsInt, IsNumber, IsOptional, IsString } from 'class-validator';
2
2
  import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
3
3
  import { IssueTypeEnum } from '../../../Enum/IssueType';
4
- //import { ReportTypeEnum } from '../../../Enum/ReportType';
4
+ import { ReportTypeEnum } from '../../../Enum/ReportType';
5
5
  import { TFile } from '../file/TFile';
6
6
 
7
7
  export class CreateExternalReport {
@@ -13,9 +13,9 @@ export class CreateExternalReport {
13
13
 
14
14
  @ApiPropertyOptional()
15
15
  @IsOptional()
16
- //@IsInt({ each: true })
17
- //@IsEnum(ReportTypeEnum)
18
- idReportType?: number[];
16
+ @IsInt()
17
+ @IsEnum(ReportTypeEnum)
18
+ idReportType?: number;
19
19
 
20
20
  @ApiProperty()
21
21
  @IsNumber()
@@ -1,8 +1,11 @@
1
- import { IsBoolean, IsOptional } from 'class-validator';
1
+ import { IsBoolean, IsDateString, IsOptional } from 'class-validator';
2
2
  import { ApiPropertyOptional } from '../../../../utils';
3
3
  import { ToBoolean } from '../../../../utils/transforms/boolean.transform';
4
4
 
5
5
  export class QueryReports {
6
+ @ApiPropertyOptional()
7
+ idSource?: number[];
8
+
6
9
  @ApiPropertyOptional()
7
10
  idReportType?: number[];
8
11
 
@@ -12,6 +15,9 @@ export class QueryReports {
12
15
  @ApiPropertyOptional()
13
16
  idService?: number;
14
17
 
18
+ @ApiPropertyOptional()
19
+ idUserConcerned?: number;
20
+
15
21
  @ApiPropertyOptional()
16
22
  idServiceConcerned?: number;
17
23
 
@@ -35,4 +41,14 @@ export class QueryReports {
35
41
  @IsBoolean()
36
42
  @ToBoolean()
37
43
  onlyClient?: boolean;
44
+
45
+ @ApiPropertyOptional()
46
+ @IsOptional()
47
+ @IsDateString()
48
+ declare startDate?: string;
49
+
50
+ @ApiPropertyOptional()
51
+ @IsOptional()
52
+ @IsDateString()
53
+ declare endDate?: string;
38
54
  }
@@ -20,6 +20,7 @@ export interface IReport {
20
20
  idServiceConcerned?: number | null;
21
21
  idService?: number | null;
22
22
  idFile?: number | null;
23
+ fileLink?: string;
23
24
  idLetterType?: number | null;
24
25
  declareSoupcons?: boolean | null;
25
26
  token?: string | null;
@@ -31,8 +32,10 @@ export interface IReport {
31
32
  ressenti?: number | null;
32
33
  action?: number | null;
33
34
  processed?: boolean | null;
35
+ receivedAt?: Date | null;
34
36
  createdAt?: Date | null;
35
37
  updatedAt?: Date | null;
38
+ deletedAt?: Date | null;
36
39
 
37
40
  // Associations
38
41
  society?: ISociety;