@memberjunction/ng-tasks 6.2.0-edge.0 → 6.2.0-edge.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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +99 -0
- package/dist/lib/components/gantt-task-viewer.component.d.ts +61 -7
- package/dist/lib/components/gantt-task-viewer.component.d.ts.map +1 -1
- package/dist/lib/components/gantt-task-viewer.component.js +127 -37
- package/dist/lib/components/gantt-task-viewer.component.js.map +1 -1
- package/dist/lib/components/simple-task-viewer.component.d.ts +55 -5
- package/dist/lib/components/simple-task-viewer.component.d.ts.map +1 -1
- package/dist/lib/components/simple-task-viewer.component.js +98 -18
- package/dist/lib/components/simple-task-viewer.component.js.map +1 -1
- package/dist/lib/components/task-detail-panel.component.d.ts +36 -3
- package/dist/lib/components/task-detail-panel.component.d.ts.map +1 -1
- package/dist/lib/components/task-detail-panel.component.js +66 -16
- package/dist/lib/components/task-detail-panel.component.js.map +1 -1
- package/dist/lib/components/task.component.d.ts +82 -10
- package/dist/lib/components/task.component.d.ts.map +1 -1
- package/dist/lib/components/task.component.js +150 -18
- package/dist/lib/components/task.component.js.map +1 -1
- package/package.json +8 -8
- package/src/lib/components/gantt-task-viewer.component.ts +125 -33
- package/src/lib/components/simple-task-viewer.component.ts +100 -16
- package/src/lib/components/task-detail-panel.component.ts +65 -14
- package/src/lib/components/task.component.ts +140 -17
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,104 @@
|
|
|
1
1
|
# @memberjunction/ng-tasks
|
|
2
2
|
|
|
3
|
+
## 6.2.0-edge.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [f555162]
|
|
8
|
+
- Updated dependencies [043f418]
|
|
9
|
+
- Updated dependencies [e97d95c]
|
|
10
|
+
- Updated dependencies [2552b1e]
|
|
11
|
+
- Updated dependencies [21f9e15]
|
|
12
|
+
- Updated dependencies [28fdf22]
|
|
13
|
+
- Updated dependencies [4248fb3]
|
|
14
|
+
- Updated dependencies [f3c6161]
|
|
15
|
+
- Updated dependencies [0adaf76]
|
|
16
|
+
- Updated dependencies [ef43cf3]
|
|
17
|
+
- Updated dependencies [b44c7cf]
|
|
18
|
+
- Updated dependencies [26c0178]
|
|
19
|
+
- Updated dependencies [594f2e0]
|
|
20
|
+
- Updated dependencies [705ab4e]
|
|
21
|
+
- Updated dependencies [96daca8]
|
|
22
|
+
- Updated dependencies [aa912ca]
|
|
23
|
+
- Updated dependencies [7e57b48]
|
|
24
|
+
- Updated dependencies [7e57b48]
|
|
25
|
+
- Updated dependencies [5986939]
|
|
26
|
+
- Updated dependencies [4d647e6]
|
|
27
|
+
- Updated dependencies [c35f7e5]
|
|
28
|
+
- Updated dependencies [bb33c77]
|
|
29
|
+
- Updated dependencies [369e229]
|
|
30
|
+
- Updated dependencies [d13cf6b]
|
|
31
|
+
- Updated dependencies [2854a2e]
|
|
32
|
+
- @memberjunction/ai-core-plus@6.2.0-edge.2
|
|
33
|
+
- @memberjunction/core@6.2.0-edge.2
|
|
34
|
+
- @memberjunction/core-entities@6.2.0-edge.2
|
|
35
|
+
- @memberjunction/global@6.2.0-edge.2
|
|
36
|
+
- @memberjunction/ai-engine-base@6.2.0-edge.2
|
|
37
|
+
- @memberjunction/ng-shared-generic@6.2.0-edge.2
|
|
38
|
+
|
|
39
|
+
## 6.2.0-edge.1
|
|
40
|
+
|
|
41
|
+
### Patch Changes
|
|
42
|
+
|
|
43
|
+
- 80905a1: Rename public class members and exported functions to PascalCase, per MJ's naming convention,
|
|
44
|
+
**without breaking a single consumer**.
|
|
45
|
+
|
|
46
|
+
Every renamed symbol keeps its old name beside the new one as a `@deprecated` stub that forwards to
|
|
47
|
+
it — a delegating method or function, a getter/setter pair for a property, and for Angular a
|
|
48
|
+
readable accessor pair for an `@Input` and a second `@Output` sharing the same `EventEmitter`, so a
|
|
49
|
+
template still binding the old name keeps receiving events. Old names still compile, still resolve,
|
|
50
|
+
and still behave identically; the deprecation tag rides through to the published `.d.ts`, so editors
|
|
51
|
+
point callers at the replacement. Where a package re-exports through an explicit `export { … }`
|
|
52
|
+
list, the new name is added alongside the old, so the correct name is actually on the public surface
|
|
53
|
+
rather than merely declared.
|
|
54
|
+
|
|
55
|
+
The rename is deliberately refused wherever a mechanical stub would not be equivalent, because
|
|
56
|
+
several of those shapes change a type contract while still compiling in the package that declares
|
|
57
|
+
them:
|
|
58
|
+
- an **optional** property or parameter property — TypeScript has no optional accessor, so a stub
|
|
59
|
+
would promote `foo?` to a required member and break every object literal that omits it;
|
|
60
|
+
- a class that is a **data shape** (no methods, or `@ObjectType`/`@InputType`) — object literals are
|
|
61
|
+
assigned to it, and an accessor stub changes what they must supply;
|
|
62
|
+
- a property whose **subclass redeclares it**, since TypeScript forbids a property overriding an
|
|
63
|
+
accessor (TS2610);
|
|
64
|
+
- a name whose PascalCase form is **already bound** in that file or class;
|
|
65
|
+
- decorated members, `get`/`set` pairs behind a decorator, generators, destructured parameters,
|
|
66
|
+
overload sets and abstract members.
|
|
67
|
+
|
|
68
|
+
**One wire-visible consequence, for version skew only.** `BaseInfo.toJSON` walks `_`-prefixed
|
|
69
|
+
backing fields and emits them through their public getter, preferring the PascalCase one. Renaming
|
|
70
|
+
the 23 field aliases in `MJCore/src/generic` therefore changes what `AllMetadata` carries:
|
|
71
|
+
`EntityInfo.spCreate` and friends now serialize as `SpCreate`. A same-version client is unaffected —
|
|
72
|
+
`copyInitData` accepts a value through a settable accessor, so either spelling lands on the right
|
|
73
|
+
field. An OLDER client against a newer server has no such path in its `copyInitData` and drops those
|
|
74
|
+
fields silently. Same-version deployments, which is the supported configuration, see no change.
|
|
75
|
+
|
|
76
|
+
Each package was verified against its own pre-change baseline rather than against zero, because
|
|
77
|
+
several packages in this repo do not typecheck cleanly to begin with. Angular packages were verified
|
|
78
|
+
with `ngc`, not `tsc`: a plain typecheck does not compile templates, and an earlier write-only
|
|
79
|
+
`@Input` alias passed `tsc` while breaking six template reads.
|
|
80
|
+
|
|
81
|
+
- Updated dependencies [a50948e]
|
|
82
|
+
- Updated dependencies [0eeb89d]
|
|
83
|
+
- Updated dependencies [a3539d2]
|
|
84
|
+
- Updated dependencies [41274aa]
|
|
85
|
+
- Updated dependencies [67f6c85]
|
|
86
|
+
- Updated dependencies [eb3a8d3]
|
|
87
|
+
- Updated dependencies [e1dd673]
|
|
88
|
+
- Updated dependencies [307da67]
|
|
89
|
+
- Updated dependencies [a7da50b]
|
|
90
|
+
- Updated dependencies [1d43161]
|
|
91
|
+
- Updated dependencies [7110019]
|
|
92
|
+
- Updated dependencies [17cc774]
|
|
93
|
+
- Updated dependencies [80905a1]
|
|
94
|
+
- Updated dependencies [6b08ebf]
|
|
95
|
+
- @memberjunction/core-entities@6.2.0-edge.1
|
|
96
|
+
- @memberjunction/ai-core-plus@6.2.0-edge.1
|
|
97
|
+
- @memberjunction/core@6.2.0-edge.1
|
|
98
|
+
- @memberjunction/global@6.2.0-edge.1
|
|
99
|
+
- @memberjunction/ng-shared-generic@6.2.0-edge.1
|
|
100
|
+
- @memberjunction/ai-engine-base@6.2.0-edge.1
|
|
101
|
+
|
|
3
102
|
## 6.2.0-edge.0
|
|
4
103
|
|
|
5
104
|
### Patch Changes
|
|
@@ -5,17 +5,60 @@ import * as i0 from "@angular/core";
|
|
|
5
5
|
* Gantt chart view for tasks using DHTMLX Gantt
|
|
6
6
|
*/
|
|
7
7
|
export declare class GanttTaskViewerComponent implements OnChanges, AfterViewInit, OnDestroy {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
Tasks: MJTaskEntity[];
|
|
9
|
+
/** @deprecated Use {@link Tasks}. */
|
|
10
|
+
set tasks(value: MJTaskEntity[]);
|
|
11
|
+
/** @deprecated Use {@link Tasks}. */
|
|
12
|
+
get tasks(): MJTaskEntity[];
|
|
13
|
+
TaskDependencies: MJTaskDependencyEntity[];
|
|
14
|
+
/** @deprecated Use {@link TaskDependencies}. */
|
|
15
|
+
set taskDependencies(value: MJTaskDependencyEntity[]);
|
|
16
|
+
/** @deprecated Use {@link TaskDependencies}. */
|
|
17
|
+
get taskDependencies(): MJTaskDependencyEntity[];
|
|
18
|
+
AgentRunMap?: Map<string, string>;
|
|
19
|
+
/** @deprecated Use {@link AgentRunMap}. */
|
|
20
|
+
set agentRunMap(value: Map<string, string> | undefined);
|
|
21
|
+
/** @deprecated Use {@link AgentRunMap}. */
|
|
22
|
+
get agentRunMap(): Map<string, string> | undefined;
|
|
23
|
+
TaskClicked: EventEmitter<MJTaskEntity>;
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated Use {@link TaskClicked}.
|
|
26
|
+
*
|
|
27
|
+
* The same emitter under the old binding name, so a template still binding
|
|
28
|
+
* (taskClicked) keeps working. Must stay AFTER TaskClicked: class fields
|
|
29
|
+
* initialise in order, and the other way round this captures undefined.
|
|
30
|
+
*/
|
|
11
31
|
taskClicked: EventEmitter<MJTaskEntity>;
|
|
32
|
+
OpenEntityRecord: EventEmitter<{
|
|
33
|
+
entityName: string;
|
|
34
|
+
recordId: string;
|
|
35
|
+
}>;
|
|
36
|
+
/**
|
|
37
|
+
* @deprecated Use {@link OpenEntityRecord}.
|
|
38
|
+
*
|
|
39
|
+
* The same emitter under the old binding name, so a template still binding
|
|
40
|
+
* (openEntityRecord) keeps working. Must stay AFTER OpenEntityRecord: class fields
|
|
41
|
+
* initialise in order, and the other way round this captures undefined.
|
|
42
|
+
*/
|
|
12
43
|
openEntityRecord: EventEmitter<{
|
|
13
44
|
entityName: string;
|
|
14
45
|
recordId: string;
|
|
15
46
|
}>;
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
47
|
+
GanttContainer: ElementRef<HTMLDivElement>;
|
|
48
|
+
/** @deprecated Use {@link GanttContainer}. */
|
|
49
|
+
get ganttContainer(): ElementRef<HTMLDivElement>;
|
|
50
|
+
/** @deprecated Use {@link GanttContainer}. */
|
|
51
|
+
set ganttContainer(value: ElementRef<HTMLDivElement>);
|
|
52
|
+
SelectedTask: MJTaskEntity | null;
|
|
53
|
+
/** @deprecated Use {@link SelectedTask}. */
|
|
54
|
+
get selectedTask(): MJTaskEntity | null;
|
|
55
|
+
/** @deprecated Use {@link SelectedTask}. */
|
|
56
|
+
set selectedTask(value: MJTaskEntity | null);
|
|
57
|
+
DetailPanelWidth: number;
|
|
58
|
+
/** @deprecated Use {@link DetailPanelWidth}. */
|
|
59
|
+
get detailPanelWidth(): number;
|
|
60
|
+
/** @deprecated Use {@link DetailPanelWidth}. */
|
|
61
|
+
set detailPanelWidth(value: number);
|
|
19
62
|
IsGanttLoading: boolean;
|
|
20
63
|
private ganttLib;
|
|
21
64
|
private ganttInitialized;
|
|
@@ -30,17 +73,28 @@ export declare class GanttTaskViewerComponent implements OnChanges, AfterViewIni
|
|
|
30
73
|
private convertToGanttFormat;
|
|
31
74
|
private calculateDuration;
|
|
32
75
|
private formatDateForDHTMLX;
|
|
76
|
+
GetAgentRunId(task: MJTaskEntity): string | null;
|
|
77
|
+
/** @deprecated Use {@link GetAgentRunId}. */
|
|
33
78
|
getAgentRunId(task: MJTaskEntity): string | null;
|
|
79
|
+
CloseDetailPanel(): void;
|
|
80
|
+
/** @deprecated Use {@link CloseDetailPanel}. */
|
|
34
81
|
closeDetailPanel(): void;
|
|
82
|
+
OnOpenEntityRecord(event: {
|
|
83
|
+
entityName: string;
|
|
84
|
+
recordId: string;
|
|
85
|
+
}): void;
|
|
86
|
+
/** @deprecated Use {@link OnOpenEntityRecord}. */
|
|
35
87
|
onOpenEntityRecord(event: {
|
|
36
88
|
entityName: string;
|
|
37
89
|
recordId: string;
|
|
38
90
|
}): void;
|
|
91
|
+
StartResize(event: MouseEvent): void;
|
|
92
|
+
/** @deprecated Use {@link StartResize}. */
|
|
39
93
|
startResize(event: MouseEvent): void;
|
|
40
94
|
handleResize(event: MouseEvent): void;
|
|
41
95
|
stopResize(): void;
|
|
42
96
|
private expandAllAndSelectRoot;
|
|
43
97
|
static ɵfac: i0.ɵɵFactoryDeclaration<GanttTaskViewerComponent, never>;
|
|
44
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<GanttTaskViewerComponent, "mj-gantt-task-viewer", never, { "tasks": { "alias": "tasks"; "required": false; }; "taskDependencies": { "alias": "taskDependencies"; "required": false; }; "agentRunMap": { "alias": "agentRunMap"; "required": false; }; }, { "taskClicked": "taskClicked"; "openEntityRecord": "openEntityRecord"; }, never, never, true, never>;
|
|
98
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<GanttTaskViewerComponent, "mj-gantt-task-viewer", never, { "Tasks": { "alias": "Tasks"; "required": false; }; "tasks": { "alias": "tasks"; "required": false; }; "TaskDependencies": { "alias": "TaskDependencies"; "required": false; }; "taskDependencies": { "alias": "taskDependencies"; "required": false; }; "AgentRunMap": { "alias": "AgentRunMap"; "required": false; }; "agentRunMap": { "alias": "agentRunMap"; "required": false; }; }, { "TaskClicked": "TaskClicked"; "taskClicked": "taskClicked"; "OpenEntityRecord": "OpenEntityRecord"; "openEntityRecord": "openEntityRecord"; }, never, never, true, never>;
|
|
45
99
|
}
|
|
46
100
|
//# sourceMappingURL=gantt-task-viewer.component.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gantt-task-viewer.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/gantt-task-viewer.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAAE,SAAS,EAAE,aAAa,EAAE,UAAU,EAAa,SAAS,EAAgB,MAAM,eAAe,CAAC;AAEjJ,OAAO,EAAE,YAAY,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;;AAMrF;;GAEG;AACH,qBA6Ha,wBAAyB,YAAW,SAAS,EAAE,aAAa,EAAE,SAAS;IACzE,KAAK,EAAE,YAAY,EAAE,CAAM;
|
|
1
|
+
{"version":3,"file":"gantt-task-viewer.component.d.ts","sourceRoot":"","sources":["../../../src/lib/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IACpC,WAAW,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI;IAK3C,YAAY,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI;IAWrC,UAAU,IAAI,IAAI;IAYlB,OAAO,CAAC,sBAAsB;yCAvenB,wBAAwB;2CAAxB,wBAAwB;CAwgBpC"}
|
|
@@ -60,14 +60,78 @@ function GanttTaskViewerComponent_Conditional_2_Template(rf, ctx) { if (rf & 1)
|
|
|
60
60
|
* Gantt chart view for tasks using DHTMLX Gantt
|
|
61
61
|
*/
|
|
62
62
|
export class GanttTaskViewerComponent {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
63
|
+
Tasks = [];
|
|
64
|
+
/** @deprecated Use {@link Tasks}. */
|
|
65
|
+
set tasks(value) {
|
|
66
|
+
this.Tasks = value;
|
|
67
|
+
}
|
|
68
|
+
/** @deprecated Use {@link Tasks}. */
|
|
69
|
+
get tasks() {
|
|
70
|
+
return this.Tasks;
|
|
71
|
+
}
|
|
72
|
+
TaskDependencies = [];
|
|
73
|
+
/** @deprecated Use {@link TaskDependencies}. */
|
|
74
|
+
set taskDependencies(value) {
|
|
75
|
+
this.TaskDependencies = value;
|
|
76
|
+
}
|
|
77
|
+
/** @deprecated Use {@link TaskDependencies}. */
|
|
78
|
+
get taskDependencies() {
|
|
79
|
+
return this.TaskDependencies;
|
|
80
|
+
}
|
|
81
|
+
AgentRunMap;
|
|
82
|
+
/** @deprecated Use {@link AgentRunMap}. */
|
|
83
|
+
set agentRunMap(value) {
|
|
84
|
+
this.AgentRunMap = value;
|
|
85
|
+
}
|
|
86
|
+
/** @deprecated Use {@link AgentRunMap}. */
|
|
87
|
+
get agentRunMap() {
|
|
88
|
+
return this.AgentRunMap;
|
|
89
|
+
} // Maps TaskID -> AgentRunID
|
|
90
|
+
TaskClicked = new EventEmitter();
|
|
91
|
+
/**
|
|
92
|
+
* @deprecated Use {@link TaskClicked}.
|
|
93
|
+
*
|
|
94
|
+
* The same emitter under the old binding name, so a template still binding
|
|
95
|
+
* (taskClicked) keeps working. Must stay AFTER TaskClicked: class fields
|
|
96
|
+
* initialise in order, and the other way round this captures undefined.
|
|
97
|
+
*/
|
|
98
|
+
taskClicked = this.TaskClicked;
|
|
99
|
+
OpenEntityRecord = new EventEmitter();
|
|
100
|
+
/**
|
|
101
|
+
* @deprecated Use {@link OpenEntityRecord}.
|
|
102
|
+
*
|
|
103
|
+
* The same emitter under the old binding name, so a template still binding
|
|
104
|
+
* (openEntityRecord) keeps working. Must stay AFTER OpenEntityRecord: class fields
|
|
105
|
+
* initialise in order, and the other way round this captures undefined.
|
|
106
|
+
*/
|
|
107
|
+
openEntityRecord = this.OpenEntityRecord;
|
|
108
|
+
GanttContainer;
|
|
109
|
+
/** @deprecated Use {@link GanttContainer}. */
|
|
110
|
+
get ganttContainer() {
|
|
111
|
+
return this.GanttContainer;
|
|
112
|
+
}
|
|
113
|
+
/** @deprecated Use {@link GanttContainer}. */
|
|
114
|
+
set ganttContainer(value) {
|
|
115
|
+
this.GanttContainer = value;
|
|
116
|
+
}
|
|
117
|
+
SelectedTask = null;
|
|
118
|
+
/** @deprecated Use {@link SelectedTask}. */
|
|
119
|
+
get selectedTask() {
|
|
120
|
+
return this.SelectedTask;
|
|
121
|
+
}
|
|
122
|
+
/** @deprecated Use {@link SelectedTask}. */
|
|
123
|
+
set selectedTask(value) {
|
|
124
|
+
this.SelectedTask = value;
|
|
125
|
+
}
|
|
126
|
+
DetailPanelWidth = 400;
|
|
127
|
+
/** @deprecated Use {@link DetailPanelWidth}. */
|
|
128
|
+
get detailPanelWidth() {
|
|
129
|
+
return this.DetailPanelWidth;
|
|
130
|
+
}
|
|
131
|
+
/** @deprecated Use {@link DetailPanelWidth}. */
|
|
132
|
+
set detailPanelWidth(value) {
|
|
133
|
+
this.DetailPanelWidth = value;
|
|
134
|
+
}
|
|
71
135
|
IsGanttLoading = true;
|
|
72
136
|
ganttLib = null;
|
|
73
137
|
ganttInitialized = false;
|
|
@@ -76,14 +140,14 @@ export class GanttTaskViewerComponent {
|
|
|
76
140
|
resizeStartWidth = 0;
|
|
77
141
|
async ngAfterViewInit() {
|
|
78
142
|
console.log('🔧 ngAfterViewInit called', {
|
|
79
|
-
taskCount: this.
|
|
80
|
-
hasContainer: !!this.
|
|
143
|
+
taskCount: this.Tasks?.length || 0,
|
|
144
|
+
hasContainer: !!this.GanttContainer
|
|
81
145
|
});
|
|
82
146
|
try {
|
|
83
147
|
const module = await import('dhtmlx-gantt');
|
|
84
148
|
this.ganttLib = module.gantt;
|
|
85
149
|
this.IsGanttLoading = false;
|
|
86
|
-
if (this.
|
|
150
|
+
if (this.Tasks && this.Tasks.length > 0 && this.GanttContainer) {
|
|
87
151
|
this.initGantt();
|
|
88
152
|
}
|
|
89
153
|
}
|
|
@@ -95,15 +159,15 @@ export class GanttTaskViewerComponent {
|
|
|
95
159
|
ngOnChanges() {
|
|
96
160
|
console.log('🔄 ngOnChanges called', {
|
|
97
161
|
initialized: this.ganttInitialized,
|
|
98
|
-
hasContainer: !!this.
|
|
99
|
-
taskCount: this.
|
|
162
|
+
hasContainer: !!this.GanttContainer,
|
|
163
|
+
taskCount: this.Tasks?.length || 0
|
|
100
164
|
});
|
|
101
165
|
if (!this.ganttLib)
|
|
102
166
|
return; // Library not yet loaded
|
|
103
|
-
if (this.ganttInitialized && this.
|
|
167
|
+
if (this.ganttInitialized && this.GanttContainer) {
|
|
104
168
|
this.updateGanttData();
|
|
105
169
|
}
|
|
106
|
-
else if (!this.ganttInitialized && this.
|
|
170
|
+
else if (!this.ganttInitialized && this.GanttContainer && this.Tasks && this.Tasks.length > 0) {
|
|
107
171
|
// Initialize if we have container and tasks but haven't initialized yet
|
|
108
172
|
console.log('🎨 Late initialization - gantt not initialized but container and tasks available');
|
|
109
173
|
this.initGantt();
|
|
@@ -157,14 +221,14 @@ export class GanttTaskViewerComponent {
|
|
|
157
221
|
{ name: 'text', label: 'Task name', tree: true, width: '*' }
|
|
158
222
|
];
|
|
159
223
|
// Initialize Gantt in the container
|
|
160
|
-
g.init(this.
|
|
224
|
+
g.init(this.GanttContainer.nativeElement);
|
|
161
225
|
this.ganttInitialized = true;
|
|
162
226
|
// Attach click event
|
|
163
227
|
g.attachEvent('onTaskClick', (id) => {
|
|
164
|
-
const originalTask = this.
|
|
228
|
+
const originalTask = this.Tasks.find(t => UUIDsEqual(t.ID, id));
|
|
165
229
|
if (originalTask) {
|
|
166
|
-
this.
|
|
167
|
-
this.
|
|
230
|
+
this.SelectedTask = originalTask;
|
|
231
|
+
this.TaskClicked.emit(originalTask);
|
|
168
232
|
}
|
|
169
233
|
return true;
|
|
170
234
|
});
|
|
@@ -188,9 +252,9 @@ export class GanttTaskViewerComponent {
|
|
|
188
252
|
if (!this.ganttInitialized)
|
|
189
253
|
return;
|
|
190
254
|
try {
|
|
191
|
-
console.log('📊 Updating Gantt data with', this.
|
|
255
|
+
console.log('📊 Updating Gantt data with', this.Tasks.length, 'tasks');
|
|
192
256
|
const g = this.ganttLib;
|
|
193
|
-
const ganttData = this.convertToGanttFormat(this.
|
|
257
|
+
const ganttData = this.convertToGanttFormat(this.Tasks);
|
|
194
258
|
g.clearAll();
|
|
195
259
|
g.parse(ganttData);
|
|
196
260
|
// Log final parsed data for debugging
|
|
@@ -216,13 +280,13 @@ export class GanttTaskViewerComponent {
|
|
|
216
280
|
const data = [];
|
|
217
281
|
const links = [];
|
|
218
282
|
console.log('🔍 Converting tasks:', tasks);
|
|
219
|
-
console.log('🔗 Task dependencies:', this.
|
|
283
|
+
console.log('🔗 Task dependencies:', this.TaskDependencies);
|
|
220
284
|
// Build a map of task ID to task for quick lookup
|
|
221
285
|
const taskMap = new Map();
|
|
222
286
|
tasks.forEach(t => taskMap.set(t.ID, t));
|
|
223
287
|
// Build dependency map: taskId -> array of tasks it depends on
|
|
224
288
|
const dependencyMap = new Map();
|
|
225
|
-
this.
|
|
289
|
+
this.TaskDependencies.forEach(dep => {
|
|
226
290
|
if (!dependencyMap.has(dep.TaskID)) {
|
|
227
291
|
dependencyMap.set(dep.TaskID, []);
|
|
228
292
|
}
|
|
@@ -334,7 +398,7 @@ export class GanttTaskViewerComponent {
|
|
|
334
398
|
data.push(ganttTask);
|
|
335
399
|
});
|
|
336
400
|
// Create links from MJTaskDependencyEntity records
|
|
337
|
-
this.
|
|
401
|
+
this.TaskDependencies.forEach((dep, index) => {
|
|
338
402
|
links.push({
|
|
339
403
|
id: dep.ID || `link_${index}`,
|
|
340
404
|
source: dep.DependsOnTaskID, // The task being depended on
|
|
@@ -360,28 +424,44 @@ export class GanttTaskViewerComponent {
|
|
|
360
424
|
const day = String(date.getDate()).padStart(2, '0');
|
|
361
425
|
return `${year}-${month}-${day} 00:00`;
|
|
362
426
|
}
|
|
427
|
+
GetAgentRunId(task) {
|
|
428
|
+
return this.AgentRunMap?.get(task.ID) || null;
|
|
429
|
+
}
|
|
430
|
+
/** @deprecated Use {@link GetAgentRunId}. */
|
|
363
431
|
getAgentRunId(task) {
|
|
364
|
-
return this.
|
|
432
|
+
return this.GetAgentRunId(task);
|
|
433
|
+
}
|
|
434
|
+
CloseDetailPanel() {
|
|
435
|
+
this.SelectedTask = null;
|
|
365
436
|
}
|
|
437
|
+
/** @deprecated Use {@link CloseDetailPanel}. */
|
|
366
438
|
closeDetailPanel() {
|
|
367
|
-
this.
|
|
439
|
+
return this.CloseDetailPanel();
|
|
440
|
+
}
|
|
441
|
+
OnOpenEntityRecord(event) {
|
|
442
|
+
this.OpenEntityRecord.emit(event);
|
|
368
443
|
}
|
|
444
|
+
/** @deprecated Use {@link OnOpenEntityRecord}. */
|
|
369
445
|
onOpenEntityRecord(event) {
|
|
370
|
-
this.
|
|
446
|
+
return this.OnOpenEntityRecord(event);
|
|
371
447
|
}
|
|
372
|
-
|
|
448
|
+
StartResize(event) {
|
|
373
449
|
this.isResizing = true;
|
|
374
450
|
this.resizeStartX = event.clientX;
|
|
375
|
-
this.resizeStartWidth = this.
|
|
451
|
+
this.resizeStartWidth = this.DetailPanelWidth;
|
|
376
452
|
event.preventDefault();
|
|
377
453
|
}
|
|
454
|
+
/** @deprecated Use {@link StartResize}. */
|
|
455
|
+
startResize(event) {
|
|
456
|
+
return this.StartResize(event);
|
|
457
|
+
}
|
|
378
458
|
handleResize(event) {
|
|
379
459
|
if (!this.isResizing)
|
|
380
460
|
return;
|
|
381
461
|
const delta = this.resizeStartX - event.clientX;
|
|
382
462
|
const newWidth = this.resizeStartWidth + delta;
|
|
383
463
|
// Constrain width between min and max
|
|
384
|
-
this.
|
|
464
|
+
this.DetailPanelWidth = Math.max(300, Math.min(600, newWidth));
|
|
385
465
|
}
|
|
386
466
|
stopResize() {
|
|
387
467
|
if (this.isResizing) {
|
|
@@ -412,10 +492,10 @@ export class GanttTaskViewerComponent {
|
|
|
412
492
|
if (rootTaskId != null) {
|
|
413
493
|
g.selectTask(rootTaskId);
|
|
414
494
|
// Trigger task click event to open detail panel
|
|
415
|
-
const originalTask = this.
|
|
495
|
+
const originalTask = this.Tasks.find(t => UUIDsEqual(t.ID, String(rootTaskId)));
|
|
416
496
|
if (originalTask) {
|
|
417
|
-
this.
|
|
418
|
-
this.
|
|
497
|
+
this.SelectedTask = originalTask;
|
|
498
|
+
this.TaskClicked.emit(originalTask);
|
|
419
499
|
}
|
|
420
500
|
}
|
|
421
501
|
console.log('✅ Expanded all tasks and selected root:', rootTaskId);
|
|
@@ -429,10 +509,10 @@ export class GanttTaskViewerComponent {
|
|
|
429
509
|
i0.ɵɵviewQuery(_c0, 5);
|
|
430
510
|
} if (rf & 2) {
|
|
431
511
|
let _t;
|
|
432
|
-
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.
|
|
512
|
+
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.GanttContainer = _t.first);
|
|
433
513
|
} }, hostBindings: function GanttTaskViewerComponent_HostBindings(rf, ctx) { if (rf & 1) {
|
|
434
514
|
i0.ɵɵlistener("mousemove", function GanttTaskViewerComponent_mousemove_HostBindingHandler($event) { return ctx.handleResize($event); }, i0.ɵɵresolveDocument)("mouseup", function GanttTaskViewerComponent_mouseup_HostBindingHandler() { return ctx.stopResize(); }, i0.ɵɵresolveDocument);
|
|
435
|
-
} }, inputs: { tasks: "tasks", taskDependencies: "taskDependencies", agentRunMap: "agentRunMap" }, outputs: { taskClicked: "taskClicked", openEntityRecord: "openEntityRecord" }, features: [i0.ɵɵNgOnChangesFeature], decls: 3, vars: 2, consts: [["ganttContainer", ""], [1, "gantt-task-viewer"], [1, "loading-container"], ["text", "Loading Gantt chart..."], [1, "no-tasks"], [1, "gantt-layout"], [1, "fas", "fa-chart-gantt"], [1, "gantt-container"], [1, "gantt-resizer"], [1, "task-detail-panel", 3, "width"], [1, "gantt-resizer", 3, "mousedown"], [1, "task-detail-panel"], [3, "closePanel", "openEntityRecord", "task", "agentRunId"]], template: function GanttTaskViewerComponent_Template(rf, ctx) { if (rf & 1) {
|
|
515
|
+
} }, inputs: { Tasks: "Tasks", tasks: "tasks", TaskDependencies: "TaskDependencies", taskDependencies: "taskDependencies", AgentRunMap: "AgentRunMap", agentRunMap: "agentRunMap" }, outputs: { TaskClicked: "TaskClicked", taskClicked: "taskClicked", OpenEntityRecord: "OpenEntityRecord", openEntityRecord: "openEntityRecord" }, features: [i0.ɵɵNgOnChangesFeature], decls: 3, vars: 2, consts: [["ganttContainer", ""], [1, "gantt-task-viewer"], [1, "loading-container"], ["text", "Loading Gantt chart..."], [1, "no-tasks"], [1, "gantt-layout"], [1, "fas", "fa-chart-gantt"], [1, "gantt-container"], [1, "gantt-resizer"], [1, "task-detail-panel", 3, "width"], [1, "gantt-resizer", 3, "mousedown"], [1, "task-detail-panel"], [3, "closePanel", "openEntityRecord", "task", "agentRunId"]], template: function GanttTaskViewerComponent_Template(rf, ctx) { if (rf & 1) {
|
|
436
516
|
i0.ɵɵelementStart(0, "div", 1);
|
|
437
517
|
i0.ɵɵconditionalCreate(1, GanttTaskViewerComponent_Conditional_1_Template, 2, 0, "div", 2);
|
|
438
518
|
i0.ɵɵconditionalCreate(2, GanttTaskViewerComponent_Conditional_2_Template, 2, 2);
|
|
@@ -484,17 +564,27 @@ export class GanttTaskViewerComponent {
|
|
|
484
564
|
}
|
|
485
565
|
</div>
|
|
486
566
|
`, styles: ["\n .gantt-task-viewer {\n height: 100%;\n background: var(--mj-bg-surface);\n overflow: hidden;\n display: flex;\n flex-direction: column;\n }\n\n .gantt-layout {\n display: flex;\n height: 600px;\n position: relative;\n }\n\n .gantt-container {\n flex: 1;\n min-width: 400px;\n height: 100%;\n position: relative;\n }\n\n .gantt-resizer {\n width: 4px;\n background: var(--mj-border-default);\n cursor: col-resize;\n flex-shrink: 0;\n transition: background 0.2s;\n }\n\n .gantt-resizer:hover {\n background: var(--mj-brand-primary);\n }\n\n .task-detail-panel {\n min-width: 300px;\n max-width: 600px;\n height: 100%;\n border-left: 1px solid var(--mj-border-default);\n flex-shrink: 0;\n }\n\n /* Override DHTMLX Gantt default styles */\n :host ::ng-deep .gantt_container {\n font-family: inherit;\n font-size: 13px;\n }\n\n :host ::ng-deep .gantt_grid_scale,\n :host ::ng-deep .gantt_task_scale {\n background: var(--mj-bg-surface-sunken);\n border-bottom: 2px solid var(--mj-border-default);\n }\n\n :host ::ng-deep .gantt_task .gantt_task_content {\n font-weight: 500;\n }\n\n .loading-container {\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 80px 20px;\n }\n\n .no-tasks {\n text-align: center;\n padding: 80px 20px;\n color: var(--mj-text-disabled);\n }\n\n .no-tasks i {\n font-size: 64px;\n opacity: 0.3;\n margin-bottom: 16px;\n }\n\n .no-tasks p {\n margin: 0;\n font-size: 14px;\n }\n "] }]
|
|
487
|
-
}], null, {
|
|
567
|
+
}], null, { Tasks: [{
|
|
568
|
+
type: Input
|
|
569
|
+
}], tasks: [{
|
|
570
|
+
type: Input
|
|
571
|
+
}], TaskDependencies: [{
|
|
488
572
|
type: Input
|
|
489
573
|
}], taskDependencies: [{
|
|
490
574
|
type: Input
|
|
575
|
+
}], AgentRunMap: [{
|
|
576
|
+
type: Input
|
|
491
577
|
}], agentRunMap: [{
|
|
492
578
|
type: Input
|
|
579
|
+
}], TaskClicked: [{
|
|
580
|
+
type: Output
|
|
493
581
|
}], taskClicked: [{
|
|
494
582
|
type: Output
|
|
583
|
+
}], OpenEntityRecord: [{
|
|
584
|
+
type: Output
|
|
495
585
|
}], openEntityRecord: [{
|
|
496
586
|
type: Output
|
|
497
|
-
}],
|
|
587
|
+
}], GanttContainer: [{
|
|
498
588
|
type: ViewChild,
|
|
499
589
|
args: ['ganttContainer', { static: false }]
|
|
500
590
|
}], handleResize: [{
|