5 * Copyright 2003-2004 (c) GForge LLC
6 * http://fusionforge.org
8 * This file is part of FusionForge.
10 * FusionForge is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
15 * FusionForge is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with FusionForge; if not, write to the Free Software
22 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 require_once('../env.inc.php');
26 require_once $gfcommon.'include/pre.php';
27 require_once $gfcommon.'reporting/report_utils.php';
28 require_once $gfcommon.'reporting/Report.class.php';
30 session_require_global_perm ('forge_stats', 'read') ;
33 if ($report->isError()) {
34 exit_error($report->getErrorMessage());
37 $g_id = getIntFromRequest('g_id');
38 $area = getFilteredStringFromRequest('area', '/^[a-z]+$/');
39 $SPAN = getIntFromRequest('SPAN', 1);
40 $start = getIntFromRequest('start');
41 $end = getIntFromRequest('end');
43 if (!$start || !$end) $z =& $report->getMonthStartArr();
49 $end = $z[count($z)-1];
51 if ($end < $start) list($start, $end) = array($end, $start);
54 $error_msg .= _('Start and end dates must be different');
57 report_header(_('Project Activity'));
60 <h2><?php echo _('Project Activity'); ?></h2>
62 <form action="<?php echo getStringFromServer('PHP_SELF'); ?>" method="get">
63 <input type="hidden" name="sw" value="<?php echo $sw; ?>" />
65 <td><strong><?php echo _('Project'); ?>:</strong><br /><?php echo report_group_box('g_id',$g_id); ?></td>
66 <td><strong><?php echo _('Areas'); ?>:</strong><br /><?php echo report_area_box('area',$area); ?></td>
67 <td><strong><?php echo _('Type'); ?>:</strong><br /><?php echo report_span_box('SPAN',$SPAN); ?></td>
68 <td><strong><?php echo _('Start'); ?>:</strong><br /><?php echo report_months_box($report, 'start', $start); ?></td>
69 <td><strong><?php echo _('End'); ?>:</strong><br /><?php echo report_months_box($report, 'end', $end); ?></td>
70 <td><input type="submit" name="submit" value="<?php echo _('Refresh'); ?>" /></td>
73 <?php if ($g_id && $start != $end) { ?>
75 <img src="projectact_graph.php?<?php echo "SPAN=$SPAN&start=$start&end=$end&g_id=$g_id&area=$area"; ?>" width="640" height="480" alt="" />
85 // c-file-style: "bsd"