@dative-gpi/foundation-core-domain 1.0.139-editablerefacto → 1.0.139-editablerefacto-2
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.
package/models/index.ts
CHANGED
|
@@ -38,7 +38,6 @@ export * from "./models";
|
|
|
38
38
|
export * from "./modelStatuses"; // No service
|
|
39
39
|
export * from "./organisations";
|
|
40
40
|
export * from "./permissionCategories";
|
|
41
|
-
export * from "./reports";
|
|
42
41
|
export * from "./roleOrganisations";
|
|
43
42
|
export * from "./roleOrganisationTypes";
|
|
44
43
|
export * from "./routes";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dative-gpi/foundation-core-domain",
|
|
3
3
|
"sideEffects": false,
|
|
4
|
-
"version": "1.0.139-editablerefacto",
|
|
4
|
+
"version": "1.0.139-editablerefacto-2",
|
|
5
5
|
"description": "",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"author": "",
|
|
11
11
|
"license": "ISC",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@dative-gpi/foundation-shared-domain": "1.0.139-editablerefacto",
|
|
14
|
-
"@dative-gpi/foundation-shared-services": "1.0.139-editablerefacto"
|
|
13
|
+
"@dative-gpi/foundation-shared-domain": "1.0.139-editablerefacto-2",
|
|
14
|
+
"@dative-gpi/foundation-shared-services": "1.0.139-editablerefacto-2"
|
|
15
15
|
},
|
|
16
|
-
"gitHead": "
|
|
16
|
+
"gitHead": "859192750b559e49be440f30226c3c7f02d8eed4"
|
|
17
17
|
}
|
package/models/reports/index.ts
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import type { DashboardType } from "@dative-gpi/foundation-shared-domain/enums";
|
|
2
|
-
import { ReportInfos, type ReportInfosDTO } from "./reportInfos";
|
|
3
|
-
import type { TranslationReportDTO } from "./translationReport";
|
|
4
|
-
|
|
5
|
-
export class ReportDetails extends ReportInfos {
|
|
6
|
-
|
|
7
|
-
constructor(params: ReportDetailsDTO) {
|
|
8
|
-
super(params);
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export interface ReportDetailsDTO extends ReportInfosDTO {
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export interface CreateReportDTO {
|
|
16
|
-
labelDefault: string;
|
|
17
|
-
bodyDefault: string;
|
|
18
|
-
dashboardId: string;
|
|
19
|
-
startDate: string;
|
|
20
|
-
endDate: string;
|
|
21
|
-
dashboardScope: DashboardType;
|
|
22
|
-
icon: string;
|
|
23
|
-
cron: string;
|
|
24
|
-
userIds: string[];
|
|
25
|
-
translations: TranslationReportDTO[];
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export interface UpdateReportDTO {
|
|
29
|
-
labelDefault: string;
|
|
30
|
-
bodyDefault: string;
|
|
31
|
-
dashboardId: string;
|
|
32
|
-
startDate: string;
|
|
33
|
-
endDate: string;
|
|
34
|
-
dashboardScope: DashboardType;
|
|
35
|
-
icon: string;
|
|
36
|
-
cron: string;
|
|
37
|
-
userIds: string[];
|
|
38
|
-
translations: TranslationReportDTO[];
|
|
39
|
-
}
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import type { DashboardType, JobState } from "@dative-gpi/foundation-shared-domain/enums";
|
|
2
|
-
import { isoToEpoch } from "@dative-gpi/foundation-shared-domain/tools";
|
|
3
|
-
|
|
4
|
-
import { useDateFormat } from "@dative-gpi/foundation-shared-services/composables";
|
|
5
|
-
|
|
6
|
-
const { epochToLongDateFormat } = useDateFormat();
|
|
7
|
-
|
|
8
|
-
export class ReportExecution {
|
|
9
|
-
id: string | null;
|
|
10
|
-
reportId: string;
|
|
11
|
-
jobId: string;
|
|
12
|
-
fileId: string | null;
|
|
13
|
-
fileLabel: string | null;
|
|
14
|
-
reportLabel: string | null;
|
|
15
|
-
mailBody: string | null;
|
|
16
|
-
state: JobState;
|
|
17
|
-
startDate: string;
|
|
18
|
-
endDate: string;
|
|
19
|
-
users: string[];
|
|
20
|
-
dashboardLabel: string;
|
|
21
|
-
dashboardId: string;
|
|
22
|
-
dashboardScope: DashboardType;
|
|
23
|
-
executedAt: number;
|
|
24
|
-
error: string;
|
|
25
|
-
cron: string;
|
|
26
|
-
|
|
27
|
-
get executedAtGroup(): string {
|
|
28
|
-
return epochToLongDateFormat(this.executedAt);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
constructor(params: ReportExecutionDTO) {
|
|
33
|
-
this.id = params.id;
|
|
34
|
-
this.reportId = params.reportId;
|
|
35
|
-
this.jobId = params.jobId;
|
|
36
|
-
this.fileId = params.fileId;
|
|
37
|
-
this.fileLabel = params.fileLabel;
|
|
38
|
-
this.reportLabel = params.reportLabel;
|
|
39
|
-
this.mailBody = params.mailBody
|
|
40
|
-
this.state = params.state;
|
|
41
|
-
this.startDate = params.startDate;
|
|
42
|
-
this.endDate = params.endDate;
|
|
43
|
-
this.users = params.users;
|
|
44
|
-
this.dashboardLabel = params.dashboardLabel;
|
|
45
|
-
this.dashboardId = params.dashboardId;
|
|
46
|
-
this.dashboardScope = params.dashboardScope;
|
|
47
|
-
this.executedAt = isoToEpoch(params.executedAt);
|
|
48
|
-
this.error = params.error;
|
|
49
|
-
this.cron = params.cron;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
export interface ReportExecutionDTO {
|
|
55
|
-
id: string | null;
|
|
56
|
-
reportId: string;
|
|
57
|
-
jobId: string;
|
|
58
|
-
fileId: string | null;
|
|
59
|
-
fileLabel: string | null;
|
|
60
|
-
reportLabel: string | null;
|
|
61
|
-
mailBody: string | null;
|
|
62
|
-
state: JobState;
|
|
63
|
-
success: boolean;
|
|
64
|
-
startDate: string;
|
|
65
|
-
endDate: string;
|
|
66
|
-
users: string[];
|
|
67
|
-
dashboardLabel: string;
|
|
68
|
-
dashboardId: string;
|
|
69
|
-
dashboardScope: DashboardType;
|
|
70
|
-
executedAt: string;
|
|
71
|
-
error: string;
|
|
72
|
-
cron: string;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
export interface ReportExecutionFilters {
|
|
76
|
-
reportId?: string | null;
|
|
77
|
-
startDate?: string | null;
|
|
78
|
-
endDate?: string | null;
|
|
79
|
-
}
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import type { DashboardType } from "@dative-gpi/foundation-shared-domain/enums";
|
|
2
|
-
import { isoToEpoch } from "@dative-gpi/foundation-shared-domain/tools";
|
|
3
|
-
import { TranslationReport } from "./translationReport";
|
|
4
|
-
|
|
5
|
-
export class ReportInfos {
|
|
6
|
-
|
|
7
|
-
id: string;
|
|
8
|
-
labelDefault: string;
|
|
9
|
-
bodyDefault: string;
|
|
10
|
-
label: string;
|
|
11
|
-
body: string;
|
|
12
|
-
cron: string;
|
|
13
|
-
icon: string;
|
|
14
|
-
userIds: string[];
|
|
15
|
-
dashboardId: string;
|
|
16
|
-
dashboardScope: DashboardType;
|
|
17
|
-
dashboardLabel: string;
|
|
18
|
-
startDate: string;
|
|
19
|
-
endDate: string;
|
|
20
|
-
createdAt: number | null;
|
|
21
|
-
nextExecution: number | null;
|
|
22
|
-
lastExecution: number | null;
|
|
23
|
-
translations: TranslationReport[];
|
|
24
|
-
|
|
25
|
-
constructor(params: ReportInfosDTO) {
|
|
26
|
-
this.id = params.id;
|
|
27
|
-
this.labelDefault = params.labelDefault;
|
|
28
|
-
this.bodyDefault = params.bodyDefault;
|
|
29
|
-
this.label = params.label;
|
|
30
|
-
this.body = params.body;
|
|
31
|
-
this.cron = params.cron;
|
|
32
|
-
this.icon = params.icon;
|
|
33
|
-
this.dashboardId = params.dashboardId;
|
|
34
|
-
this.dashboardScope = params.dashboardScope;
|
|
35
|
-
this.dashboardLabel = params.dashboardLabel;
|
|
36
|
-
this.startDate = params.startDate;
|
|
37
|
-
this.endDate = params.endDate;
|
|
38
|
-
this.userIds = params.userIds;
|
|
39
|
-
this.createdAt = params.createdAt ? isoToEpoch(params.createdAt) : null;
|
|
40
|
-
this.nextExecution = params.nextExecution ? isoToEpoch(params.nextExecution) : null;
|
|
41
|
-
this.lastExecution = params.lastExecution ? isoToEpoch(params.lastExecution) : null;
|
|
42
|
-
this.translations = params.translations.map((translation) => new TranslationReport(translation));
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
export interface ReportInfosDTO {
|
|
48
|
-
id: string;
|
|
49
|
-
labelDefault: string;
|
|
50
|
-
bodyDefault: string;
|
|
51
|
-
label: string;
|
|
52
|
-
body: string;
|
|
53
|
-
cron: string;
|
|
54
|
-
icon: string;
|
|
55
|
-
dashboardId: string;
|
|
56
|
-
dashboardScope: DashboardType;
|
|
57
|
-
dashboardLabel: string;
|
|
58
|
-
startDate: string;
|
|
59
|
-
endDate: string;
|
|
60
|
-
userIds: string[];
|
|
61
|
-
createdAt: string | null;
|
|
62
|
-
nextExecution: string | null;
|
|
63
|
-
lastExecution: string | null;
|
|
64
|
-
translations: TranslationReport[];
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export interface ReportFilters {
|
|
68
|
-
search?: string | null;
|
|
69
|
-
startDate?: string | null;
|
|
70
|
-
endDate?: string | null;
|
|
71
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export class TranslationReport {
|
|
2
|
-
languageCode: string;
|
|
3
|
-
label: string;
|
|
4
|
-
body: string;
|
|
5
|
-
|
|
6
|
-
constructor(params: TranslationReportDTO) {
|
|
7
|
-
this.languageCode = params.languageCode;
|
|
8
|
-
this.label = params.label;
|
|
9
|
-
this.body = params.body;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export interface TranslationReportDTO {
|
|
14
|
-
languageCode: string;
|
|
15
|
-
label: string;
|
|
16
|
-
body: string;
|
|
17
|
-
}
|