Merge branch 'syncfusion-upgrade' of https://dev.azure.com/asfinag/Tech-Supporting.ITSM/_git/Tech-Supporting.ITSM.ChangeKalender into syncfusion-upgrade
commit
fb7ee4f319
|
|
@ -474,13 +474,14 @@ export class NttGanttComponent implements OnInit {
|
||||||
this.resources = this.allResources;
|
this.resources = this.allResources;
|
||||||
for (const resource of this.resources) {
|
for (const resource of this.resources) {
|
||||||
for (const task of resource.tasks) {
|
for (const task of resource.tasks) {
|
||||||
if (this.showDetails == false) {
|
this.data.push(task);
|
||||||
if (task.TaskID.includes("D2")) {
|
// if (this.showDetails == false) {
|
||||||
this.data.push(task);
|
// if (task.TaskID.includes("D2")) {
|
||||||
}
|
// this.data.push(task);
|
||||||
} else {
|
// }
|
||||||
this.data.push(task);
|
// } else {
|
||||||
}
|
// this.data.push(task);
|
||||||
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -904,13 +905,59 @@ export class NttGanttComponent implements OnInit {
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public queryTaskbarInfo(args: any) {
|
public queryTaskbarInfo(args: any) {
|
||||||
console.log(args.milestoneColor);
|
// console.log(args.data.taskData);
|
||||||
|
|
||||||
|
// console.log(args.data.taskData.resources[0]);
|
||||||
|
// if (args.data.taskData.resources[0].state == 0) {
|
||||||
|
// args.milestoneColor = "rgb(248, 50, 0)"; //red
|
||||||
|
// console.log("red");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 1) {
|
||||||
|
// args.milestoneColor = "#f98700"; //orange
|
||||||
|
// // console.log("orange");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 3) {
|
||||||
|
// args.milestoneColor = "#ffc006"; //light orange
|
||||||
|
// // console.log("light orange");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 6) {
|
||||||
|
// args.milestoneColor = "#f4fa00"; //yellow
|
||||||
|
// // console.log("yellow");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 7) {
|
||||||
|
// args.milestoneColor = "#ffff00"; //yellow
|
||||||
|
// // // console.log("yellow");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 9) {
|
||||||
|
// args.milestoneColor = "#d3d3d3"; //yellow
|
||||||
|
// // // console.log("yellow");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 91) {
|
||||||
|
// args.milestoneColor = "grey"; //yellow
|
||||||
|
// // // console.log("yellow");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 101) {
|
||||||
|
// args.milestoneColor = "#008B45"; //lightgreen
|
||||||
|
// // console.log("lightgreen");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 10) {
|
||||||
|
// args.milestoneColor = "#32CD32"; //lightgreen
|
||||||
|
// // console.log("lightgreen");
|
||||||
|
// }
|
||||||
|
// if (args.data.taskData.resources[0].state == 11) {
|
||||||
|
// args.milestoneColor = "#ffffff"; //white
|
||||||
|
// // console.log("white");
|
||||||
|
// }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (args.taskbarType == 'Milestone' && args.data.taskData.TaskID.includes("D2")) {
|
if (args.taskbarType == 'Milestone' && args.data.taskData.TaskID.includes("D2")) {
|
||||||
if (args.data.taskData.isFixed == false) {
|
if (args.data.taskData.isFixed == false) {
|
||||||
args.taskbarElement.children[1].classList.add('e-gantt-milestone-border1');
|
args.taskbarElement.children[1].classList.add('e-gantt-milestone-borderMoveable');
|
||||||
} else {
|
} else {
|
||||||
args.taskbarElement.children[1].classList.remove('e-gantt-milestone-border1');
|
// args.taskbarElement.children[1].classList.remove('e-gantt-milestone-borderMoveable');
|
||||||
args.taskbarElement.children[1].classList.add('e-gantt-milestone-border2');
|
args.taskbarElement.children[1].classList.add('e-gantt-milestone-borderFixed');
|
||||||
}
|
}
|
||||||
if (args.data.taskData.TaskID.includes("D2")) {
|
if (args.data.taskData.TaskID.includes("D2")) {
|
||||||
// console.log(args.data.taskData.resources[0]);
|
// console.log(args.data.taskData.resources[0]);
|
||||||
|
|
@ -926,8 +973,8 @@ export class NttGanttComponent implements OnInit {
|
||||||
args.milestoneColor = "#ffc006"; //light orange
|
args.milestoneColor = "#ffc006"; //light orange
|
||||||
// console.log("light orange");
|
// console.log("light orange");
|
||||||
}
|
}
|
||||||
if (args.data.taskData.resources[0].state >= 6) {
|
if (args.data.taskData.resources[0].state == 6) {
|
||||||
args.milestoneColor = "#000000"; //yellow
|
args.milestoneColor = "#f4fa00"; //yellow
|
||||||
// console.log("yellow");
|
// console.log("yellow");
|
||||||
}
|
}
|
||||||
if (args.data.taskData.resources[0].state == 7) {
|
if (args.data.taskData.resources[0].state == 7) {
|
||||||
|
|
@ -961,12 +1008,12 @@ export class NttGanttComponent implements OnInit {
|
||||||
// console.log("\nisRes: ", args.data.taskData.isRes);
|
// console.log("\nisRes: ", args.data.taskData.isRes);
|
||||||
// console.log("\nisD2", args.data.taskData.TaskID.includes("D2"));
|
// console.log("\nisD2", args.data.taskData.TaskID.includes("D2"));
|
||||||
// console.log("\nMilestone Color ready:",args.milestoneColor);
|
// console.log("\nMilestone Color ready:",args.milestoneColor);
|
||||||
console.log(args.milestoneColor);
|
// console.log(args.milestoneColor);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (args.taskbarType == 'Milestone' && !args.data.taskData.TaskID.includes("D2")) {
|
if (args.taskbarType == 'Milestone' && !args.data.taskData.TaskID.includes("D2")) {
|
||||||
args.taskbarElement.children[1].classList.add('e-gantt-milestone-border3');
|
args.taskbarElement.children[1].classList.add('e-gantt-milestone-borderDetails');
|
||||||
if (this.showDetails == true) {
|
if (this.showDetails == true) {
|
||||||
if (args.data.taskData.TaskID.includes("D1") || args.data.taskData.TaskID.includes("D4") || args.data.taskData.TaskID.includes("D3")) {
|
if (args.data.taskData.TaskID.includes("D1") || args.data.taskData.TaskID.includes("D4") || args.data.taskData.TaskID.includes("D3")) {
|
||||||
if (args.data.taskData.TaskID.includes("D1")) {
|
if (args.data.taskData.TaskID.includes("D1")) {
|
||||||
|
|
@ -980,9 +1027,11 @@ export class NttGanttComponent implements OnInit {
|
||||||
args.milestoneColor = "#bababa";
|
args.milestoneColor = "#bababa";
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// console.log(args);
|
console.log(args);
|
||||||
args.taskbarElement.innerHTML = null;
|
args.taskbarElement.innerHTML = null;
|
||||||
args.taskbarElement.classlist = null;
|
args.taskbarElement.classlist = null;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,47 +14,38 @@
|
||||||
</html>
|
</html>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
/* .e-selectionbackground {
|
.e-selectionbackground {
|
||||||
background-color: #E0E0E0 !important;
|
background-color: #E0E0E0 !important;
|
||||||
}
|
}
|
||||||
.e-gantt .e-gantt-chart .e-active {
|
.e-gantt .e-gantt-chart .e-active {
|
||||||
background-color: #E0E0E0 !important;
|
background-color: #E0E0E0 !important;
|
||||||
} */
|
|
||||||
|
|
||||||
|
|
||||||
/* .e-gantt-milestone-border {
|
|
||||||
border-radius: 50%;
|
|
||||||
color: red;
|
|
||||||
background-color: transparent !important;
|
|
||||||
cursor: not-allowed;
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
.e-gantt-milestone-border1 {
|
|
||||||
border-radius: 30%;
|
|
||||||
color: red;
|
|
||||||
background-color: #9e9e9b !important;
|
|
||||||
cursor: grab;
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.e-gantt-milestone-border2 {
|
.e-gantt-milestone-border {
|
||||||
border-radius: 30%;
|
|
||||||
color: red;
|
|
||||||
background-color: #9e9e9b !important;
|
|
||||||
cursor: not-allowed !important;
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
.e-gantt-milestone-border3 {
|
|
||||||
|
|
||||||
background-color: transparent !important;
|
.e-gantt-milestone-borderMoveable {
|
||||||
cursor: not-allowed !important;
|
border: 1.5px solid red !important;
|
||||||
|
/* border-style: solid;
|
||||||
|
color: red; */
|
||||||
|
cursor: grab;
|
||||||
|
}
|
||||||
|
|
||||||
|
.e-gantt-milestone-borderFixed {
|
||||||
|
border: 1.5px solid red !important;
|
||||||
|
/* color: red; */
|
||||||
|
cursor: not-allowed !important;
|
||||||
|
}
|
||||||
|
.e-gantt-milestone-borderDetails {
|
||||||
|
border-radius: 35%;
|
||||||
|
cursor: not-allowed !important;
|
||||||
|
|
||||||
|
|
||||||
} */
|
}
|
||||||
|
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue