= [];
+ @Input() splitterSettings: object;
+ @ViewChild('ganttObjectSum')
+ public ganttDefault!: GanttComponent;
+ public data: any[] = [];
+ public resources: any[] = [];
+ public userSupportGroup: string;
+ public taskSettings: object = {};
+ public labelSettings: object = {};
+ public projectStartDate: Date;
+ public projectEndDate: Date;
+ public resourceFields: object ={};
+ public editSettings: object = {};
+ public tooltipSettings: object ={};
+ public columns: object[] = [];
+ public toolbar: any[] = [];
+ public timelineSettings: object = {};
+
+ constructor() { }
+
+ ngOnInit(): void {
+ this.splitterSettings = this.inputData[0];
+ this.projectStartDate = this.inputData[1];
+ this.projectEndDate = this.inputData[2];
+ this.labelSettings = {
+ taskLabel: '${taskData.planzeit} H'
+ }
+
+ this.resources = [{resourceId: 1, resourceName: 'Planzeit Summen pro Woche'}];
+
+ this.data.push(
+ {
+ TaskID: '01', TaskName: "Woche 1", StartDate: new Date ('01.02.2023'), Duration: 7, planzeit: 1,
+ resources: [{resourceId: this.resources[0].resourceId},], Progress: 0, work: 0, isRes: false
+ });
+
+ this.data.push(
+ {
+ TaskID: '02', TaskName: "Woche 2", StartDate: new Date ('01.10.2023'), Duration: 7, planzeit: 4,
+ resources: [{resourceId: this.resources[0].resourceId},], Progress: 0, work: 0, isRes: false
+ });
+ this.data.push(
+ {
+ TaskID: '03', TaskName: "Woche 3", StartDate: new Date ('01.18.2023'), Duration: 7, planzeit: 7,
+ resources: [{resourceId: this.resources[0].resourceId},], Progress: 0, work: 0, isRes: false
+ });
+
+ this.data.push(
+ {
+ TaskID: '04', TaskName: "Woche 4", StartDate: new Date ('01.26.2023'), Duration: 7, planzeit: 11,
+ resources: [{resourceId: this.resources[0].resourceId},], Progress: 0, work: 0, isRes: false
+ });
+
+
+
+ this.timelineSettings = {
+ bottomTier: {
+ format: 'WW',
+ unit: 'Week',
+ count: 1
+ }
+ };
+ this.taskSettings = {
+ id: 'TaskID',
+ name: 'TaskName',
+ startDate: 'StartDate',
+ endDate: 'EndDate',
+ duration: 'Duration',
+ progress: 'Progress',
+ dependency: 'Predecessor',
+ resourceInfo: 'resources',
+ work: 'work',
+ expandState: 'isExpand',
+ child: 'subtasks',
+ planzeit: 'planzeit'
+ };
+ this.resourceFields = {
+ id: 'resourceId',
+ name: 'resourceName',
+ };
+ }
+
+}
diff --git a/frontend/src/ntt-gantt/ntt-gantt.component.html b/frontend/src/ntt-gantt/ntt-gantt.component.html
index 29038bd..51f13d7 100644
--- a/frontend/src/ntt-gantt/ntt-gantt.component.html
+++ b/frontend/src/ntt-gantt/ntt-gantt.component.html
@@ -63,7 +63,7 @@
-
+
Die Suche lieferte keine Ergebnisse
The search did not return any results
diff --git a/frontend/src/ntt-gantt/ntt-gantt.component.ts b/frontend/src/ntt-gantt/ntt-gantt.component.ts
index 266ea39..f166ac9 100644
--- a/frontend/src/ntt-gantt/ntt-gantt.component.ts
+++ b/frontend/src/ntt-gantt/ntt-gantt.component.ts
@@ -77,6 +77,7 @@ export class NttGanttComponent implements OnInit {
public language: string = 'DE';
public horizontalPosition: MatSnackBarHorizontalPosition = 'end';
public verticalPosition: MatSnackBarVerticalPosition = 'bottom';
+ public inputForTimeline = [];
public deMap : Map = new Map()
public enMap : Map = new Map()
@@ -359,14 +360,20 @@ public logg(args){
this.tooltipSettings = {
showTooltip: true,
}
- this.splitterSettings = {
- columnIndex:3
- };
-
this.projectStartDate = this.range.controls.start.value;
this.projectEndDate = this.range.controls.end.value;
+ this.splitterSettings = {
+ columnIndex:3
+ };
+
+ this.splitterSettings = {
+ position: 647+'px'
+ };
+
+ this.inputForTimeline = [this.splitterSettings, this.projectStartDate, this.projectEndDate];
+
}
@@ -527,8 +534,8 @@ public logg(args){
this.data.push(task);
}
}
- console.log(this.resources[this.resources.length-1]);
- this.resources.push({resourceId: 'Timeline', resourceName: 'Planzeit Summen pro Woche'})
+ // console.log(this.resources[this.resources.length-1]);
+ // this.resources.push({resourceId: 'Timeline', resourceName: 'Planzeit Summen pro Woche'})
}
/**
@@ -600,29 +607,29 @@ public logg(args){
this.projectEndDate = new Date(this.range.controls.end.value);
}
}
- public rowSelecting(args: any){
- console.log(args)
- if(args.data.length){
- // if((args.data.length == this.resources.length+1)){
- // console.log("all")
- // }else{
- // if(args.data[args.data.length-1].TaskID == 'Timeline'){
- // args.cancel = true;
- // }
- // }
- if(args.data[args.data.length-1].TaskID == 'Timeline'){
- let data = args.data;
- data.pop();
- args.data = data;
- }
+ // public rowSelecting(args: any){
+ // console.log(args)
+ // if(args.data.length){
+ // // if((args.data.length == this.resources.length+1)){
+ // // console.log("all")
+ // // }else{
+ // // if(args.data[args.data.length-1].TaskID == 'Timeline'){
+ // // args.cancel = true;
+ // // }
+ // // }
+ // if(args.data[args.data.length-1].TaskID == 'Timeline'){
+ // let data = args.data;
+ // data.pop();
+ // args.data = data;
+ // }
- }else{
- if(args.data.TaskID == 'Timeline'){
- args.cancel = true;
- }
- }
+ // }else{
+ // if(args.data.TaskID == 'Timeline'){
+ // args.cancel = true;
+ // }
+ // }
- }
+ // }
/**
* The function rowSelected catches the corresponding syncfsuions event and checks if all selected resources (changes) have the same status, then it displays the corresponding buttons
@@ -1160,6 +1167,7 @@ private oldFilters:{};
this.refreshData();
}
public onResizing(args){
+
let width ='' + args.paneSize[0]+'px';
this.splitterSettings = {
position: width