
Gantt Chart for Mantis
Moderators: Developer, Contributor
Re: Gantt Chart for Mantis
It's not a malfunction, it is done on purpose since we are not suppose to work on the week-end, to be the most fair as possible I exclude the week-end days in the charts. For instance, if you start an issue on friday and set for instance 1 day of duration, of course the end date will not be in the week end, but at the end of the following monday!


AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
Hello,
I've solved my problem by adjusting the working days. ($t_adjusted_days = 0;)
I know this is not the optimal way but it's working fine.
I've solved my problem by adjusting the working days. ($t_adjusted_days = 0;)
I know this is not the optimal way but it's working fine.
Code: Select all
function gantt_adjust_working_day( $p_date ){
define ( GANTT_CHART_DAY_SUNDAY, 0);
define ( GANTT_CHART_DAY_SATURDAY, 6);
$t_one_day_in_seconds = 1 * 24 * 3600;
$t_day = strftime( "%w", $p_date );
switch ( $t_day ){
case GANTT_CHART_DAY_SUNDAY:
$t_adjusted_days = 0;
break;
case GANTT_CHART_DAY_SATURDAY:
$t_adjusted_days = 0;
break;
default:
$t_adjusted_days = 0;
break;
}
return $p_date + ($t_adjusted_days * $t_one_day_in_seconds);
}
Re: Gantt Chart for Mantis
Yes, it'll do it wel. But maybe I would add in an update an option to allow or avoid such a feature, i.e. exclude the week-end days or not.
AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
By the way, have you checked how can we add a legend for the colors on the GRANTT graph?
Re: Gantt Chart for Mantis
Not yet, I don't have a lot of time this beginning of the week.
But looks possible using the jpgraph MGraph class... I'll try to do something by the end of the week if I can free some time.
source and documentation: http://jpgraph.net/doc/howto1.php
But looks possible using the jpgraph MGraph class... I'll try to do something by the end of the week if I can free some time.
source and documentation: http://jpgraph.net/doc/howto1.php
AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
Hello,
I'm wondering whether we can add the relationship (Parent Of, Child Of) between issues in the GANTT chart.
Or something like an ordinal relationship (One issue can't start before some other one has finished).
I'm wondering whether we can add the relationship (Parent Of, Child Of) between issues in the GANTT chart.
Or something like an ordinal relationship (One issue can't start before some other one has finished).
Re: Gantt Chart for Mantis
I disagree with that last one. This is not the purpose of the plugin. The plugin just displays gantt charts, it does not do the work of the manager. This is a task the manager should take care of, by using why not the help of the GanttChart plugin 
But indeed, maybe I could add something to display child bug different from the parent bugs, like it is displayed in the roadmap for instance, with an extra space before the issue.
Anyway, I tried something tricky here for the legend. Can you try it please ? (cf attachement)
(I create a fake line plot graph which I hide, but I display it's legend. Then I combine the 2 graphs by using MGraph)

But indeed, maybe I could add something to display child bug different from the parent bugs, like it is displayed in the roadmap for instance, with an extra space before the issue.
Anyway, I tried something tricky here for the legend. Can you try it please ? (cf attachement)
(I create a fake line plot graph which I hide, but I display it's legend. Then I combine the 2 graphs by using MGraph)
- Attachments
-
- gantt_api_patch_20120322_Add_Legend_To_Graph.zip
- Patch gantt_api.php in order to add a legend to the graph.
- (6.8 KiB) Downloaded 2944 times
AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
Well... at a second thought maybe it's not a bad idea after all... We could then use the grouping function of the gantt chart, and relations, etc...Elyes wrote:Hello,
I'm wondering whether we can add the relationship (Parent Of, Child Of) between issues in the GANTT chart.
Or something like an ordinal relationship (One issue can't start before some other one has finished).
Yeah we could think of something here... sorry 'bout what I said before, and thank for the idea in fact!

AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
Hello,
Thank you for the partch adding the legend to the chart.
I've tested it and it's working fine.
Thank you for the partch adding the legend to the chart.
I've tested it and it's working fine.
Re: Gantt Chart for Mantis
Hello,
Any clues about the following hint?
Any clues about the following hint?
Elyes wrote: I'm wondering whether we can add the relationship (Parent Of, Child Of) between issues in the GANTT chart.
Or something like an ordinal relationship (One issue can't start before some other one has finished).
Re: Gantt Chart for Mantis
unfortunately not yet. I'm overworking these days 

AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
Is this plugin suppose to work when using a custom field of type date as end date?
I seems to work fine when using a duration ( numeric ) in days to calculatie an end date. However when using a custom field of type date as end date , it seems it will still calculate with the duration in seconds which gives me end dates in the far future and th graph is not displaying due to MAX_GANTTIMG_SIZE.
Can anyone verify this?
I seems to work fine when using a duration ( numeric ) in days to calculatie an end date. However when using a custom field of type date as end date , it seems it will still calculate with the duration in seconds which gives me end dates in the far future and th graph is not displaying due to MAX_GANTTIMG_SIZE.
Can anyone verify this?
Re: Gantt Chart for Mantis
No, the custom field must be a duration in days, not a date.
But normally, instead of custom field, the plugin should be able to work also with mantis 'due date' if activated in the config_inc.php file.
But normally, instead of custom field, the plugin should be able to work also with mantis 'due date' if activated in the config_inc.php file.
AlainD.
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
ti lamp, ti lamp n'arivé!
Mantis: 1.2.5
PHP: 5.2.0
OS: Linux (etch)
Plugins: MantisGanttChart | Mantis Graphs | Source Control Integration | Subversion / WebSVN Integration
Re: Gantt Chart for Mantis
Hi AlainD,
First of all, thanks for developing a good plugin!
Nevertheless, I need a little help you as I couldn't get the grantt chart working.
The result I get :
Clicking on the item in Grant Chart Roadmap, I get a blank page
(mantis/plugin.php?page=MantisGanttChart/summary_gantt_chart.php&project_id=3&version_id=2&inherited=)
A few things that I have checked,
1) Custom Field
- Estimated Duration - String
- Start Date - Date
- Link to all the projects
2) Plugin Config 3) I have check the jpgraph and it's working fine 4) Update the latest grantt_api (gantt_api_patch_20120322_Add_Legend_To_Graph.zip)
Regards,
Chew
First of all, thanks for developing a good plugin!
Nevertheless, I need a little help you as I couldn't get the grantt chart working.
The result I get :
Clicking on the item in Grant Chart Roadmap, I get a blank page
(mantis/plugin.php?page=MantisGanttChart/summary_gantt_chart.php&project_id=3&version_id=2&inherited=)
A few things that I have checked,
1) Custom Field
- Estimated Duration - String
- Start Date - Date
- Link to all the projects
2) Plugin Config 3) I have check the jpgraph and it's working fine 4) Update the latest grantt_api (gantt_api_patch_20120322_Add_Legend_To_Graph.zip)
Regards,
Chew