| <HTML> |
| <HEAD><TITLE>Test Cases</TITLE> |
| <link type="text/css" rel="stylesheet" href="http://www.eclipse.org/org/processes/dashboard/eclipse-dashboard.css"> |
| </HEAD> |
| <BODY> |
| <?php |
| |
| if (isset($_GET['project']) && strlen($_GET['project']) > 0) |
| { |
| |
| require_once "/home/data/httpd/eclipse-php-classes/system/dbconnection_dashboard_rw.class.php"; |
| |
| require_once "groups.class.php"; |
| require_once "../dashboard/utils.php"; |
| require_once "hostname.php"; |
| require_once "common_queries.php"; |
| require_once "../dashboard/constants.php"; |
| |
| $dbc_cache = new DBConnectionDashboard(); |
| $db_handle = $dbc_cache->connect(); |
| |
| $project = $_GET['project']; |
| |
| |
| $groups = new Groups(); |
| $groups->loadGroups(); // Load groups |
| |
| // Get last date available for $project in DB |
| $mysql_date = get_last_date($db_handle); |
| |
| // Get info for the project |
| $query = "SELECT * FROM ".stats_table()." WHERE project = \"".$project."\" AND stats_date = \"".$mysql_date."\""; |
| $result_7 = mysql_query($query,$db_handle); |
| $row = mysql_fetch_assoc($result_7); |
| |
| // Newsgroups stats |
| $num_posts_7 = $row['news_7_number_posts']; |
| $num_posts_30 = $row['news_30_number_posts']; |
| $avg_posts_7 = $row['news_7_average_posts']; |
| $avg_posts_30 = $row['news_30_average_posts']; |
| $avg_time_answer_7 = $row['news_7_answer_average_time']; |
| $avg_time_answer_30 = $row['news_30_answer_average_time']; |
| $unanswered_posts_7 = $row['news_7_unanswered_number']; |
| $unanswered_posts_30 = $row['news_30_unanswered_number']; |
| $insider_posts_7 = $row['news_7_insider_posts']; |
| $insider_posts_30 = $row['news_30_insider_posts']; |
| |
| // Mail stats |
| $mail_posts_7 = $row['mail_7_number_posts']; |
| $mail_posts_30 = $row['mail_30_number_posts']; |
| $mail_posts_180 = $row['mail_180_number_posts']; |
| $mail_average_posts_7 = $row['mail_7_average_posts']; |
| $mail_average_posts_30 = $row['mail_30_average_posts']; |
| $mail_average_posts_180 = $row['mail_180_average_posts']; |
| $mail_average_subscribers_7 = $row['mail_7_average_subscribers']; |
| $mail_average_subscribers_30 = $row['mail_30_average_subscribers']; |
| $mail_average_subscribers_180 = $row['mail_180_average_subscribers']; |
| |
| $result_7 = "Error!"; |
| $ligth_7= ""; |
| if($num_posts_7 < _NUM_POST_7_ANSER_NA) |
| { |
| $result_7 = "Answer N/A"; |
| $ligth_7 = "White"; |
| } |
| if($num_posts_7 == _NUM_POST_7_NA) |
| { |
| $result_7 = "N/A"; |
| $ligth_7 = "White"; |
| } |
| if($num_posts_7 == _NUM_POST_7_NO_POSTS) |
| { |
| $result_7 = "0 (No posts)"; |
| $ligth_7 = "Red"; |
| } |
| if($num_posts_7 > _NUM_POST_7_NO_POSTS) |
| { |
| $result_7 = "Number of Posts: " . $num_posts_7; |
| if($num_posts_7 >= _NUM_POST_7_GREEN) |
| $ligth_7 = "Green"; |
| else |
| $ligth_7 = "Red"; |
| } |
| |
| $result_30 = "Error!"; |
| $ligth_30 = ""; |
| if($num_posts_30 < _NUM_POST_30_ANSER_NA) |
| { |
| $result_30 = "Answer N/A"; |
| } |
| if($num_posts_30 == _NUM_POST_30_NA) |
| { |
| $result_30 = "N/A"; |
| $ligth_30 = "White"; |
| } |
| if($num_posts_30 == _NUM_POST_30_NO_POSTS) |
| { |
| $result_30 = "0 (No posts)"; |
| $ligth_30 = "Red"; |
| } |
| if($num_posts_30 > _NUM_POST_30_NO_POSTS) |
| { |
| $result_30 = "Number of Posts: " . $num_posts_30; |
| if($num_posts_30 <= 10) |
| $ligth_30 = "Red"; |
| if($num_posts_30 > _NUM_POST_30_BAD && $num_posts_30 < _NUM_POST_30_GOOD) |
| $ligth_30 = "White"; |
| if($num_posts_30 >= _NUM_POST_30_GOOD) |
| $ligth_30 = "Green"; |
| } |
| |
| // AVERAGE RESPONSE TIME |
| $avg_7 = "Error!"; |
| $avg_ligth_7= ""; |
| if($avg_time_answer_7 < _ART_7_NOANSW) |
| { |
| $avg_result_7 = "No Answer"; |
| $avg_ligth_7 = "Red"; |
| } |
| if($avg_time_answer_7 == _ART_7_NOPOST) |
| { |
| $avg_result_7 = "No Posts"; |
| $avg_ligth_7 = "Red"; |
| } |
| if($avg_time_answer_7 == _ART_7_NA) |
| { |
| $avg_result_7 = "N/A"; |
| $avg_ligth_7 = "White"; |
| } |
| if($avg_time_answer_7 > _NUM_POST_7_NO_POSTS) |
| { |
| $avg_result_7 = "Number of Posts: " . $avg_time_answer_7; |
| if($avg_time_answer_7 >= _NUM_POST_7_GREEN) |
| $avg_ligth_7 = "Green"; |
| else |
| $avg_ligth_7 = "Red"; |
| } |
| |
| $result_30 = "Error!"; |
| $ligth_30 = ""; |
| if($avg_time_answer_30 < _NUM_POST_30_ANSER_NA) |
| { |
| $avg_result_30 = "Answer N/A"; |
| } |
| if($avg_time_answer_30 == _NUM_POST_30_NA) |
| { |
| $avg_result_30 = "N/A"; |
| $avg_ligth_30 = "White"; |
| } |
| if($avg_time_answer_30 == _NUM_POST_30_NO_POSTS) |
| { |
| $avg_result_30 = "0 (No posts)"; |
| $avg_ligth_30 = "Red"; |
| } |
| if($avg_time_answer_30 > _NUM_POST_30_NO_POSTS) |
| { |
| $avg_result_30 = "Number of Posts: " . $avg_time_answer_30; |
| if($avg_time_answer_30 <= 10) |
| $avg_ligth_30 = "Red"; |
| if($avg_time_answer_30 > _NUM_POST_30_BAD && $num_posts_30 < _NUM_POST_30_GOOD) |
| $avg_ligth_30 = "White"; |
| if($avg_time_answer_30 >= _NUM_POST_30_GOOD) |
| $avg_ligth_30 = "Green"; |
| } |
| |
| |
| $img_7 = "http://www.eclipse.org/org/processes/dashboard/lights/" . strtolower($ligth_7) . ".gif"; |
| $img_30 = "http://www.eclipse.org/org/processes/dashboard/lights/" . strtolower($ligth_30) . ".gif"; |
| $avg_img_7 = "http://www.eclipse.org/org/processes/dashboard/lights/" . strtolower($avg_ligth_7) . ".gif"; |
| $avg_img_30 = "http://www.eclipse.org/org/processes/dashboard/lights/" . strtolower($avg_ligth_30) . ".gif"; |
| } |
| ?> |
| |
| <p id="header"><img src="http://www.eclipse.org/images/Idea.jpg" align="right" height="86" hspace="50" width="120"> |
| <br> |
| |
| <span class="indextop">Project Dashboards</span><br> |
| <span class="indexsub">Test Cases </span></p> |
| |
| <h1>Test Cases </h1> |
| <p><br> |
| <br> |
| </p> |
| <table width="80%" border="0" cellspacing="0" cellpadding="0"> |
| <tr> |
| <th width="47%" scope="col">Project Name</th> |
| <th width="5%" scope="col"> </th> |
| <th colspan="2" scope="col">Bugs</th> |
| <th width="5%" scope="col"> </th> |
| <th width="19%" colspan="2" scope="col">News</th> |
| <th width="6%" scope="col"> </th> |
| </tr> |
| <tr> |
| <td><?= $project ?>;</td> |
| <td> </td> |
| <td width="9%"><?php echo " This Week: ". $result_7 . " ($num_posts_7) " . "<img src=\"$img_7\" alt=\"$ligth_7\" title=\"$ligth_7\">";?></td> |
| <td width="9%"><?php echo " This Month: ". $result_30 . " ($num_posts_30) " . "<img src=\"$img_30\" alt=\"$ligth_30\" title=\"$ligth_30\">"; ?></td> |
| <td> </td> |
| <td><?php echo " This Week: ". $result_7 . " ($num_posts_7) " . "<img src=\"$img_7\" alt=\"$ligth_7\" title=\"$ligth_7\">";?></td> |
| <td><?php echo " This Month: ". $result_30 . " ($num_posts_30) " . "<img src=\"$img_30\" alt=\"$ligth_30\" title=\"$ligth_30\">"; ?></td> |
| <td> </td> |
| </tr> |
| </table> |
| <p> </p> |
| <p><br> |
| <font color="grey">Last update 15/11/2005 </font> |
| </p> |
| </BODY> |
| </HTML> |