/
iteration_List.php
121 lines (111 loc) · 4.37 KB
/
iteration_List.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
<?php
/*
* Practical Agile Scrum tool
*
* Copyright 2013-2017, P.P. Labuschagne
* Released under the MIT license.
* https://github.com/paul-lab/practical-agile/blob/master/_Licence.txt
*
* Homepage:
* http://practicalagile.co.uk
* http://practicalagile.uk
*
*/
include 'include/header.inc.php';
if (empty($_REQUEST['PID'])) header("Location:project_List.php");
echo '<div class="hidden" id="phpbread"><a href="project_List.php">My Projects</a>->';
echo '<a href="project_Summary.php?PID='.$_REQUEST['PID'].'">';
echo Get_Project_Name($_REQUEST['PID']);
echo '</a>';
echo '</div>';
?>
<script>
$(function() {
document.title = 'Practical Agile: '+$("#phpbread").text().substring(13);
$("#breadcrumbs").html($("#phpbread").html());
if ($("#phpnavicons")){
$("#navicons").html($("#phpnavicons").html());
}
});
</script>
<!--[if lt IE 9]><script language="javascript" type="text/javascript" src="jqplot/excanvas.js"></script><![endif]-->
<script type="text/javascript" src="jqplot/jquery.jqplot.min.js"></script>
<script type="text/javascript" src="jqplot/plugins/jqplot.categoryAxisRenderer.min.js"></script>
<script type="text/javascript" src="jqplot/plugins/jqplot.highlighter.min.js"></script>
<script type="text/javascript" src="jqplot/plugins/jqplot.canvasTextRenderer.min.js"></script>
<script type="text/javascript" src="jqplot/plugins/jqplot.canvasAxisTickRenderer.min.js"></script>
<script type="text/javascript" src="jqplot/plugins/jqplot.enhancedLegendRenderer.min.js"></script>
<link class="include" rel="stylesheet" type="text/css" href="jqplot/jquery.jqplot.min.css" />
<?php
echo
'<div align="center">';
if ($isProjectAdmin ) echo '<br><a class="btnlink" href="iteration_Edit.php?PID='.$_REQUEST['PID'].'">add a new Sprint</a>';
echo '</div>'.
'<table align="center" cellpadding="6" cellspacing="0">'.
'<tr>'.
'<td> </td>'.
'<td><B>Name</td>'.
'<td>Objective</B></td>'.
'<td> </td>'.
'<td> </td>'.
'</tr>';
$sql = 'select *, (select count(*) from story where Project_ID='.$_REQUEST['PID'].' and story.Iteration_ID = iteration.id) as nums FROM iteration where iteration.Project_ID='.$_REQUEST['PID'].' order by iteration.End_Date desc';
$iteration_Row = $DBConn->directsql($sql);
$Toggle=1;
if (count($iteration_Row) > 0 ) {
$rowcnt=0;
do
{
$Toggle = ($Toggle + 1) % 2;
echo
'<tr valign="center" class="alternate'.$Toggle.'">';
if ($iteration_Row[$rowcnt]['ID']!=$Project['Backlog_ID'])
{
if ($isProjectAdmin) {
echo '<td>'.'<a href="iteration_Edit.php?IID='.$iteration_Row[$rowcnt]['ID'].'&PID='.$_REQUEST['PID'].'"><img src="images/edit.png"></a> '.'</td>';
} else {
echo '<td> </td>';
}
}else{
echo '<td> </td>';
}
echo '<td>'.'<a href="story_List.php?PID='.$_REQUEST['PID'].'&IID='.$iteration_Row[$rowcnt]['ID'].'"'.
' title="'.$iteration_Row[$rowcnt]['Start_Date'].' -> '.$iteration_Row[$rowcnt]['End_Date'].'">'.
substr($iteration_Row[$rowcnt]['Name'], 0, 32).'</a>';
if ($iteration_Row[$rowcnt]['ID']!=$Project['Backlog_ID'])
{
echo '<br><center>'.$iteration_Row[$rowcnt]['Start_Date'].
'<br>to<br> '.$iteration_Row[$rowcnt]['End_Date'];
}
if ($iteration_Row[$rowcnt]['Locked']==1) {
echo '<p><b>Locked</b>';
}
echo '</center></td>'.
'<td>'.substr($iteration_Row[$rowcnt]['Objective'], 0, 64).'</td>'.
'<td>'.
'<table><tr><td>';
if ($iteration_Row[$rowcnt]['ID']!=$Project['Backlog_ID']){
print_summary($iteration_Row[$rowcnt]['ID'], False); // without velocity
}else{
print_summary($iteration_Row[$rowcnt]['ID'], True); // without velocity
}
echo '</td><td> ';
print_Graphx($iteration_Row[$rowcnt]['Points_Object_ID'], True); // Not Small
echo '</td></tr></table></td>'.
'<td>';
if ($iteration_Row[$rowcnt]['Name']!='Backlog' ) {
if ($isProjectAdmin and $iteration_Row[$rowcnt]['nums']==0) {
echo '<a href="iteration_Delete.php?IID='.$iteration_Row[$rowcnt]['ID'].'&PID='.$_REQUEST['PID'].'&POID='.$iteration_Row[$rowcnt]['Points_Object_ID'].'&COID='.$iteration_Row[$rowcnt]['Comment_Object_ID'].'"><img src="images/delete.png"></a>';
}else{
echo ' ';
}
}
echo ' </td>'.
'</tr>';
$rowcnt += 1;
}
while ($rowcnt < count($iteration_Row));
}
echo '</table>';
include 'include/footer.inc.php';
?>