@managemint-solutions/entities 1.24.0 → 1.26.0
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/dist/audit-trail/enum/index.d.ts +1 -0
- package/dist/audit-trail/enum/index.js +1 -0
- package/dist/labels/dto/index.d.ts +18 -0
- package/dist/labels/dto/index.js +2 -0
- package/dist/labels/enum/index.d.ts +4 -0
- package/dist/labels/enum/index.js +9 -0
- package/dist/labels/index.d.ts +13 -0
- package/dist/labels/index.js +2 -0
- package/dist/tasks/dto/index.d.ts +12 -0
- package/dist/tasks/enum/index.d.ts +9 -0
- package/dist/tasks/enum/index.js +14 -0
- package/dist/tasks/index.d.ts +21 -0
- package/package.json +1 -1
- package/dist/tasks/enum.ts/index.d.ts +0 -0
- package/dist/tasks/enum.ts/index.js +0 -1
|
@@ -16,6 +16,7 @@ var AuditTrailEntityType;
|
|
|
16
16
|
AuditTrailEntityType["USER"] = "users";
|
|
17
17
|
AuditTrailEntityType["PERMISSION"] = "permissions";
|
|
18
18
|
AuditTrailEntityType["STATUS"] = "statuses";
|
|
19
|
+
AuditTrailEntityType["LABEL"] = "labels";
|
|
19
20
|
AuditTrailEntityType["ADDITIONAL_DETAILS"] = "additional_details";
|
|
20
21
|
AuditTrailEntityType["SUPPORTING_FILES"] = "supporting_files";
|
|
21
22
|
AuditTrailEntityType["NOTES"] = "notes";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { LabelEntityTypes } from "../enum";
|
|
2
|
+
export type LabelIdDto = {
|
|
3
|
+
labelId: string;
|
|
4
|
+
};
|
|
5
|
+
export type GetLabelsDto = {
|
|
6
|
+
entity: LabelEntityTypes;
|
|
7
|
+
};
|
|
8
|
+
export type AddLabelDto = {
|
|
9
|
+
name: string;
|
|
10
|
+
colour: string;
|
|
11
|
+
entity: LabelEntityTypes;
|
|
12
|
+
description?: string | null;
|
|
13
|
+
};
|
|
14
|
+
export type UpdateLabelDto = {
|
|
15
|
+
name: string;
|
|
16
|
+
colour: string;
|
|
17
|
+
description?: string | null;
|
|
18
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.LabelEntityTypes = void 0;
|
|
4
|
+
/** The entities a label catalogue exists for. Tasks only for now; a later entity adds a value. */
|
|
5
|
+
var LabelEntityTypes;
|
|
6
|
+
(function (LabelEntityTypes) {
|
|
7
|
+
LabelEntityTypes["TASK"] = "tasks";
|
|
8
|
+
})(LabelEntityTypes || (exports.LabelEntityTypes = LabelEntityTypes = {}));
|
|
9
|
+
;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { UUID } from 'crypto';
|
|
2
|
+
/**
|
|
3
|
+
* A small coloured tag an organization defines for one entity type and pins to its rows -
|
|
4
|
+
* tasks for now. Like a status, a label is the organization's own catalogue entry: the
|
|
5
|
+
* row it is pinned to only references it.
|
|
6
|
+
*/
|
|
7
|
+
export type LabelEntity = {
|
|
8
|
+
mms_id: UUID;
|
|
9
|
+
name: string;
|
|
10
|
+
colour: string;
|
|
11
|
+
/** What the label is for, shown when hovering the chip; null when none was given. */
|
|
12
|
+
description: string | null;
|
|
13
|
+
};
|
|
@@ -1,6 +1,15 @@
|
|
|
1
|
+
import { TaskLinkType } from "../enum";
|
|
1
2
|
export type TaskIdDto = {
|
|
2
3
|
taskId: string;
|
|
3
4
|
};
|
|
5
|
+
export type TaskLinkIdDto = {
|
|
6
|
+
taskId: string;
|
|
7
|
+
linkedTaskId: string;
|
|
8
|
+
};
|
|
9
|
+
export type AddTaskLinkDto = {
|
|
10
|
+
linked_task_id: string;
|
|
11
|
+
link_type: TaskLinkType;
|
|
12
|
+
};
|
|
4
13
|
export type GetTasksDto = {
|
|
5
14
|
search?: string | null;
|
|
6
15
|
page: number;
|
|
@@ -18,6 +27,7 @@ export type GetTasksDto = {
|
|
|
18
27
|
status_id_not_in?: string | null;
|
|
19
28
|
completed?: boolean | null;
|
|
20
29
|
priority_in?: string | null;
|
|
30
|
+
label_id_in?: string | null;
|
|
21
31
|
archive: boolean;
|
|
22
32
|
};
|
|
23
33
|
export type CreateTaskDto = {
|
|
@@ -30,6 +40,7 @@ export type CreateTaskDto = {
|
|
|
30
40
|
assigned_to_id?: string | null;
|
|
31
41
|
project_id?: string | null;
|
|
32
42
|
client_id?: string | null;
|
|
43
|
+
label_ids?: string[] | null;
|
|
33
44
|
};
|
|
34
45
|
export type UpdateTaskDto = {
|
|
35
46
|
name: string;
|
|
@@ -41,4 +52,5 @@ export type UpdateTaskDto = {
|
|
|
41
52
|
assigned_to_id?: string | null;
|
|
42
53
|
project_id?: string | null;
|
|
43
54
|
client_id?: string | null;
|
|
55
|
+
label_ids?: string[] | null;
|
|
44
56
|
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* How one task is linked to another. A `child` link makes the linked task a subtask of the
|
|
3
|
+
* task it hangs off (a task has one parent at most); a `related` link has no direction and
|
|
4
|
+
* shows on both tasks.
|
|
5
|
+
*/
|
|
6
|
+
export declare enum TaskLinkType {
|
|
7
|
+
CHILD = "child",
|
|
8
|
+
RELATED = "related"
|
|
9
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TaskLinkType = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* How one task is linked to another. A `child` link makes the linked task a subtask of the
|
|
6
|
+
* task it hangs off (a task has one parent at most); a `related` link has no direction and
|
|
7
|
+
* shows on both tasks.
|
|
8
|
+
*/
|
|
9
|
+
var TaskLinkType;
|
|
10
|
+
(function (TaskLinkType) {
|
|
11
|
+
TaskLinkType["CHILD"] = "child";
|
|
12
|
+
TaskLinkType["RELATED"] = "related";
|
|
13
|
+
})(TaskLinkType || (exports.TaskLinkType = TaskLinkType = {}));
|
|
14
|
+
;
|
package/dist/tasks/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ClientIdentity } from "../clients";
|
|
2
|
+
import { LabelEntity } from "../labels";
|
|
2
3
|
import { ProjectIdentity } from "../projects";
|
|
3
4
|
import { StatusEntity } from "../status";
|
|
4
5
|
import { UserIdentity } from "../users";
|
|
@@ -6,6 +7,17 @@ export type TaskIdentity = {
|
|
|
6
7
|
mms_id: string;
|
|
7
8
|
name: string;
|
|
8
9
|
};
|
|
10
|
+
/**
|
|
11
|
+
* A task as another task's link shows it: enough for a row with its reference, name, priority
|
|
12
|
+
* and status, and a click through to it.
|
|
13
|
+
*/
|
|
14
|
+
export type LinkedTask = {
|
|
15
|
+
mms_id: string;
|
|
16
|
+
task_number: number;
|
|
17
|
+
name: string;
|
|
18
|
+
status: StatusEntity | null;
|
|
19
|
+
priority: number;
|
|
20
|
+
};
|
|
9
21
|
export type TaskSummary = {
|
|
10
22
|
mms_id: string;
|
|
11
23
|
/** Sequential per organization, starting at 1; the human and integration-facing reference. */
|
|
@@ -14,6 +26,8 @@ export type TaskSummary = {
|
|
|
14
26
|
start_date: Date;
|
|
15
27
|
end_date: Date | null;
|
|
16
28
|
status: StatusEntity | null;
|
|
29
|
+
/** The task's labels; empty when it has none. */
|
|
30
|
+
labels: LabelEntity[];
|
|
17
31
|
priority: number;
|
|
18
32
|
assigned_to: UserIdentity | null;
|
|
19
33
|
project: ProjectIdentity | null;
|
|
@@ -31,10 +45,17 @@ export type TaskEntity = {
|
|
|
31
45
|
start_date: Date;
|
|
32
46
|
end_date: Date | null;
|
|
33
47
|
status: StatusEntity | null;
|
|
48
|
+
labels: LabelEntity[];
|
|
34
49
|
priority: number;
|
|
35
50
|
assigned_to: UserIdentity | null;
|
|
36
51
|
project: ProjectIdentity | null;
|
|
37
52
|
client: ClientIdentity | null;
|
|
53
|
+
/** The task this one is a subtask of; null when it has none. */
|
|
54
|
+
parent: LinkedTask | null;
|
|
55
|
+
/** The tasks linked to this one as its subtasks. */
|
|
56
|
+
subtasks: LinkedTask[];
|
|
57
|
+
/** The tasks linked to this one as related, whichever task the link was made from. */
|
|
58
|
+
related: LinkedTask[];
|
|
38
59
|
archived: boolean;
|
|
39
60
|
archived_at: Date | null;
|
|
40
61
|
archived_by: UserIdentity | null;
|
package/package.json
CHANGED
|
File without changes
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";
|