hi
In this article, dhtmlx.com/blog/using-dhtmlx … p-net-mvc/ it shows making an MVC application for a gantt chart.
But the example doesnt quite work, there are missing steps, many folks who wrote on that page said they (like me) followed each step perfectly, 100% and it doesnt work.
the example shows a full but empty gantt by the end of step 1. but that does not show up. only the top part of the gantt, with only 2 words, Mar Apr .
the goal in my case, to construct the frame and manually build up the json array. I only display gantt data, have no need to save it.
[code](function () {
// add month scale
gantt.config.scale_unit = “week”;
gantt.config.step = 1;
gantt.templates.date_scale = function (date) {
var dateToStr = gantt.date.date_to_str("%d %M");
var endDate = gantt.date.add(gantt.date.add(date, 1, “week”), -1, “day”);
return dateToStr(date) + " - " + dateToStr(endDate);
};
gantt.config.subscales = [
{ unit: “day”, step: 1, date: “%D” }
];
gantt.config.scale_height = 50;
// configure milestone description
gantt.templates.rightside_text = function (start, end, task) {
if (task.type == gantt.config.types.milestone) {
return task.text;
}
return "";
};
// add section to type selection: task, project or milestone
gantt.config.lightbox.sections = [
{ name: "description", height: 70, map_to: "text", type: "textarea", focus: true },
{ name: "type", type: "typeselect", map_to: "type" },
{ name: "time", height: 72, type: "duration", map_to: "auto" }
];
gantt.config.xml_date = "%Y-%m-%d %H:%i:%s"; // format of dates in XML
gantt.init("ganttContainer"); // initialize gantt
})();[/code]
Now I realized, i used Nuget to install dhtmlx gantt, which by the way seems to be missing the hdhmlx.css file ?
will try the download version also…