1<?php 2# --------------------------------------------------------------------- 3# rth is a requirement, test, and bugtracking system 4# Copyright (C) 2005 George Holbrook - rth@lists.sourceforge.net 5# This program is distributed under the terms and conditions of the GPL 6# See the README and LICENSE files for details 7#---------------------------------------------------------------------- 8# --------------------------------------------------------------------- 9# Results Page 10# 11# $RCSfile: results_page.php,v $ $Revision: 1.12 $ 12# --------------------------------------------------------------------- 13 14if( isset($_POST['mass_update']) ) { 15 16 require_once("results_group_action_page.php"); 17 exit; 18} 19 20include"./api/include_api.php"; 21auth_authenticate_user(); 22 23session_validate_form_reset(); 24 25$project_properties = session_get_project_properties(); 26$project_name = $project_properties['project_name']; 27$project_id = $project_properties['project_id']; 28 29$s_user_properties = session_get_user_properties(); 30$user_id = $s_user_properties['user_id']; 31 32if( user_has_rights( $project_id, $user_id, MANAGER ) ) { 33 $user_is_manager = true; 34} 35else{ 36 $user_is_manager = false; 37} 38 39# Links to pages 40$page = basename(__FILE__); 41$test_page = "test_manual_test.php"; 42$results_test_run_page = "results_test_run_page.php"; 43$results_add_run_page = "results_run_manual_test_page.php"; 44$result_update_page = "results_update_test_result_page.php"; 45$results_group_action = "showresults_action_group.php"; 46$testset_status_page = "testset_current_status.php"; 47$testset_signoff_page = "testset_signoff_page.php"; 48$testset_lock_page = "testset_lock_page.php"; 49 50# Initialize vars 51$i = 0; 52$num = 0; 53$row_style = ''; 54 55html_window_title(); 56html_print_body(); 57html_page_title($project_name ." - ". lang_get('test_results_page') ); 58html_page_header( $db, $project_name ); 59 60# -------------------------------------------------- 61# Maybe make a get_session_test_results_option function with each of the functions below 62# It would then set the release_id, build_id, and testset_id each time the page is called 63#---------------------------------------------------- 64# set the filter session variables if the user submits the filter form 65 66$table_options = session_set_display_options("results", $_POST); 67$s_properties = session_set_properties("results", $_GET); 68 69 70html_print_menu(); 71html_test_results_menu( $db, $page, $project_id, $s_properties, $table_options ); 72 73print"<br>". NEWLINE; 74 75if( !empty( $s_properties['testset_id'] ) && $s_properties['testset_id'] != 'all') 76{ 77 78 $testset_id = $s_properties['testset_id']; 79 // ------------------------------------------------------------ 80 // run query to make sure there are tests in the testset. 81 // if not, dont show all the forms and filters below 82 //-------------------------------------------------------------- 83 $locked = testset_get_lock_status($testset_id); 84 85 print"<table class='hide100'>". NEWLINE; 86 87 print"<tr>". NEWLINE; 88 print"<td width='50%'> </td>". NEWLINE; 89 print"<td width='25%' align='right'><a href='results_run_autopass.php?testset_id=$testset_id' target='_blank'>". lang_get('run_autopass') ."</td>". NEWLINE; 90 print"<td width='25%' align='right'><a href='results_display_est_test_time.php?testset_id=$testset_id' target='_blank'>". lang_get('est_time') ."</td>". NEWLINE; 91 print"</tr>". NEWLINE; 92 93 print"</table>". NEWLINE; 94 95 # -------------- NOTE ------------------------------ 96 # May need to update the queries for the filters so that they pull back only those values that apply 97 # to the tests in the testset. Requires and INNER JOIN and may require a new list_box function 98 # that employs inner joins 99 # ---------------------------------------------- 100 print"<div align=center>". NEWLINE; 101 print"<table class=width100>". NEWLINE; 102 print"<tr>". NEWLINE; 103 print"<td>". NEWLINE; 104 print"<form method=post action='$page'>". NEWLINE; 105 print"<table class=inner rules=none border=0>". NEWLINE; 106 107 # TITLES FOR HEADER DIALOG 108 print"<tr align=left>". NEWLINE; 109 print"<td class='form-header-c'>". lang_get('man_auto') ."</td>". NEWLINE; 110 print"<td class='form-header-c'>". lang_get('ba_owner') ."</td>". NEWLINE; 111 print"<td class='form-header-c'>". lang_get('qa_owner') ."</td>". NEWLINE; 112 print"<td class='form-header-c'>". lang_get('testtype') ."</td>". NEWLINE; 113 print"<td class='form-header-c'>". lang_get('area_tested') ."</td>". NEWLINE; 114 print"<td class='form-header-c'>". lang_get('test_status') ."</td>". NEWLINE; 115 print"<td class='form-header-c'>". lang_get('show') ."</td>". NEWLINE; 116 print"<td> </td>". NEWLINE; 117 print"</tr>". NEWLINE; 118 119 print"<tr>". NEWLINE; 120 121 //$s_TestFormFilterOptions = session_getTestFormFilterOptions(); 122 //$s_TestTableDisplayOptions = session_getTestTableDisplayOptions(); 123 124 # MANUAL/AUTOMATED 125 print"<td align='center'>". NEWLINE; 126 print"<select name='manual_auto'>". NEWLINE; 127 $man_auto = test_get_man_auto_values(); 128 html_print_list_box_from_array( $man_auto, $selected=$table_options['filter']['manual_auto'] ); 129 print"</select>". NEWLINE; 130 print"</td>". NEWLINE; 131 132 # BA OWNER 133 print"<td align='center'>". NEWLINE; 134 print"<select name='ba_owner'>". NEWLINE; 135 $ba_owners = testset_get_test_testset_value($project_id, $testset_id, TEST_BA_OWNER, $blank=true); 136 html_print_list_box_from_array( $ba_owners, $selected=$table_options['filter']['ba_owner'] ); 137 print"</select>". NEWLINE; 138 print"</td>". NEWLINE; 139 140 # QA OWNER 141 print"<td align='center'>". NEWLINE; 142 print"<select name='qa_owner'>". NEWLINE; 143 $qa_owners = testset_get_test_testset_value($project_id, $testset_id, TEST_QA_OWNER, $blank=true); 144 html_print_list_box_from_array( $qa_owners, $selected=$table_options['filter']['qa_owner'] ); 145 print"</select>". NEWLINE; 146 print"</td>". NEWLINE; 147 148 # TEST TYPE 149 print"<td align='center'>". NEWLINE; 150 print"<select name='test_type'>". NEWLINE; 151 $test_type = testset_get_test_testset_value($project_id, $testset_id, TEST_TESTTYPE, $blank=true); 152 html_print_list_box_from_array( $test_type, $selected=$table_options['filter']['test_type'] ); 153 print"</select>". NEWLINE; 154 print"</td>". NEWLINE; 155 156 # AREA TESTED 157 print"<td align='center'>". NEWLINE; 158 print"<select name='area_tested'>". NEWLINE; 159 $area_tested = testset_get_test_testset_value($project_id, $testset_id, TEST_AREA_TESTED, $blank=true); 160 html_print_list_box_from_array( $area_tested, $selected=$table_options['filter']['area_tested'] ); 161 print"</select>". NEWLINE; 162 print"</td>". NEWLINE; 163 164 # TEST STATUS 165 print"<td align='center'>". NEWLINE; 166 print"<select name='test_status'>". NEWLINE; 167 $test_status = testset_get_test_testset_value($project_id, $testset_id, TEST_TS_ASSOC_STATUS, $blank=true); 168 html_print_list_box_from_array( $test_status, $selected=$table_options['filter']['test_status'] ); 169 print"</select>". NEWLINE; 170 print"</td>". NEWLINE; 171 172 # PER PAGE 173 print"<td align='center'>". NEWLINE; 174 print"<input type='text' size='3' maxlength='3' name='per_page' value='" . $table_options['filter']['per_page'] . "'>". NEWLINE; 175 print"</td>". NEWLINE; 176 177 print"<td align='center'><input type='submit' value='Filter'></td>". NEWLINE; 178 179 print"</tr>". NEWLINE; 180 print"</table>". NEWLINE; 181 182 # --------------------------------------------------------------------- 183 # May need to hide release_id, build_id, and testset_id and pass them over as hidden vars 184 # --------------------------------------------------------------------- 185 print"<input type=hidden name=results_form_filter_value value=true>". NEWLINE; 186 print"<input type=hidden name=page_number value=" . $table_options['page_number'] . ">". NEWLINE; 187 print"<input type=hidden name=order_by value=" . $table_options['order_by'] . ">". NEWLINE; 188 print"<input type=hidden name=order_dir value=" . $table_options['order_dir'] . ">". NEWLINE; 189 print"<input type=hidden name=release_id value=" . $s_properties['release_id'] . ">". NEWLINE; 190 print"<input type=hidden name=build_id value=" . $s_properties['build_id'] . ">". NEWLINE; 191 print"<input type=hidden name=testset_id value=" . $s_properties['testset_id'] . ">". NEWLINE; 192 print"</form>". NEWLINE; 193 print"</td>". NEWLINE; 194 print"</tr>". NEWLINE; 195 print"</table>". NEWLINE; 196 print"</div>". NEWLINE; 197 print"<br>". NEWLINE; 198 199 print"<form method='post' action='$page' name='results_form' id='form_order'>". NEWLINE; 200 201 $row = results_filter_rows( $project_id, 202 $table_options['filter']['manual_auto'], 203 $table_options['filter']['ba_owner'], 204 $table_options['filter']['qa_owner'], 205 $table_options['filter']['test_type'], 206 $table_options['filter']['area_tested'], 207 $table_options['filter']['test_status'], 208 $table_options['filter']['per_page'], 209 $table_options['order_by'], 210 $table_options['order_dir'], 211 $table_options['page_number'], 212 $s_properties['release_id'], 213 $s_properties['build_id'], 214 $s_properties['testset_id'] ); 215 216 $page_count = ceil($num / $table_options['filter']['per_page'] ); 217 218 $order_by = $table_options['order_by']; 219 $order_dir = $table_options['order_dir']; 220 221 if( $row ) { 222 if($locked){ 223 print"<h3 class='hint'> <img src='images/locked.png' alt='locked'> Testset locked</h3>". NEWLINE; 224 } 225 print"<table class='sortable' rules=cols>". NEWLINE; 226 print"<thead>".NEWLINE; 227 print"<tr>". NEWLINE; 228 229 #this column is only diplayed, if user is manager 230 if( $user_is_manager && !$locked){ 231 print"<th class='unsortable'></th>". NEWLINE; 232 } 233 234 #html_tbl_print_header( lang_get('id'), TEST_ID, $order_by, $order_dir ); 235 html_tbl_print_sortable_header( lang_get('id'),TEST_ID, $order_by, $order_dir ); 236 print"<th class='unsortable'></th>". NEWLINE; 237 html_tbl_print_sortable_header( lang_get('test_name'), TEST_NAME, $order_by, $order_dir ); 238 html_tbl_print_sortable_header( lang_get('ba_owner'), TEST_BA_OWNER, $order_by, $order_dir ); 239 html_tbl_print_sortable_header( lang_get('qa_owner'), TEST_QA_OWNER, $order_by, $order_dir ); 240 html_tbl_print_sortable_header( lang_get('testtype'), TEST_TESTTYPE, $order_by, $order_dir ); 241 html_tbl_print_sortable_header( lang_get('area_tested'), TEST_AREA_TESTED, $order_by, $order_dir ); 242 html_tbl_print_sortable_header( lang_get('test_run') ); 243 html_tbl_print_sortable_header( lang_get('tester'), TEST_TS_ASSOC_TBL.".".TEST_TS_ASSOC_ASSIGNED_TO,$order_by, $order_dir); 244 html_tbl_print_sortable_header( lang_get('info') ); 245 print"<th class='unsortable'></th>". NEWLINE; 246 #html_tbl_print_header( lang_get('bug') ); 247 html_tbl_print_sortable_header( lang_get('test_status'), TEST_TS_ASSOC_STATUS, $order_by, $order_dir ); 248 if(!$locked){ 249 html_tbl_print_header_not_sortable( lang_get('run_test') ); 250 html_tbl_print_header_not_sortable( lang_get('update') ); 251 } 252 print"</tr>". NEWLINE; 253 print"</thead>".NEWLINE; 254 print"<tbody>".NEWLINE; 255 256 #html_tbl_print_header( lang_get('test_name') ); 257 #html_tbl_print_header( lang_get('ba_owner') ); 258 #html_tbl_print_header( lang_get('qa_owner') ); 259 #html_tbl_print_header( lang_get('testtype') ); 260 #html_tbl_print_header( lang_get('area_tested') ); 261 #html_tbl_print_header( lang_get('test_doc') ); 262 #html_tbl_print_header( lang_get('priority') ); 263 #if($s_show_priority == 'Y') 264 #html_tbl_print_header( lang_get('priority') ); 265 //print_r($row); 266 //foreach( $row as $key => $value ) { 267 //print"key = $key & value = $value<br>". NEWLINE; 268 //} 269 foreach( $row as $row_detail ) { 270 271 $test_id = $row_detail[TEST_ID]; 272 $test_name = $row_detail[TEST_NAME]; 273 $manual = $row_detail[TEST_MANUAL]; 274 $automated = $row_detail[TEST_AUTOMATED]; 275 $auto_pass = $row_detail[TEST_AUTO_PASS]; 276 $ba_owner = $row_detail[TEST_BA_OWNER]; 277 $qa_owner = $row_detail[TEST_QA_OWNER]; 278 $test_type = $row_detail[TEST_TESTTYPE]; 279 $area_tested = $row_detail[TEST_AREA_TESTED]; 280 $priority = $row_detail[TEST_PRIORITY]; 281 $test_ts_assoc_id = $row_detail[TEST_TS_ASSOC_ID]; 282 $assigned_to = $row_detail[TEST_TS_ASSOC_ASSIGNED_TO]; 283 $comments = $row_detail[TEST_TS_ASSOC_COMMENTS]; 284 $testset_status = $row_detail[TEST_TS_ASSOC_STATUS]; 285 286 $row_style = html_tbl_alternate_bgcolor( $row_style ); 287 print"<tr class='$row_style'>". NEWLINE; 288 289 #Testoutput, not needed 290 #print"<p>Userid:$user_id Projektid:$project_name userismanager:$manager</p>".NEWLINE; 291 292 #print"<tr>".NEWLINE; 293 294 # this column is only displayed if user is manager 295 if( $user_is_manager && !$locked){ 296 print"<td><input type='checkbox' name='row_results_arr[{$test_id}]'></td>". NEWLINE; 297 } 298 print"<td class='tbl-l'>$test_id</td>". NEWLINE; 299 print"<td class='tbl-l' nowrap>".html_print_testtype_icon( $manual, $automated)."</td>". NEWLINE; 300 print"<td class='tbl-l' >$test_name</td>". NEWLINE; 301 #print"<td class='left'>$auto_pass</td>". NEWLINE; 302 print"<td class='tbl-l'>$ba_owner</td>". NEWLINE; 303 print"<td class='tbl-l'>$qa_owner</td>". NEWLINE; 304 print"<td class='tbl-l' nowrap>$test_type</td>". NEWLINE; 305 print"<td class='tbl-l' nowrap>$area_tested</td>". NEWLINE; 306 #print"<td class='tbl-c'><a href='$test_page?test_id=$test_id' target='_blank'>". lang_get('docs_link') ."</a></td>". NEWLINE; 307 #if($s_show_priority == 'Y') 308 #print"<td class='left'>$priority</td>". NEWLINE; 309 print"<td class='tbl-c'><a href='$results_test_run_page?test_id=$test_id&testset_id=$s_properties[testset_id]'>". lang_get('results_link') ."</a></td>". NEWLINE; 310 print"<td class='tbl-l'>$assigned_to</td>". NEWLINE; 311 # -------- Comment Icon ---------- 312 if( !empty($comments) ) { 313 print"<td class='tbl-c'><img src='images/info.gif' title='$comments'></td>". NEWLINE; 314 } 315 else { 316 print"<td> </td>". NEWLINE; 317 } 318 # ------- Test Status Icon --------- 319 print"<td class='tbl-c'>".html_teststatus_icon($testset_status)."</td>". NEWLINE; 320 321 print"<td class='tbl-l' nowrap>$testset_status</td>". NEWLINE; 322 # -------- Manual Test Run link ----------- 323 if(!$locked){ 324 if($manual == 'YES' ) { 325 print"<td class='tbl-c'><a href='$results_add_run_page?test_id=$test_id&testset_id=$s_properties[testset_id]'>". lang_get('run_test') ."</a></td>". NEWLINE; // &testsetname=$testsetname 326 } 327 else { 328 print"<td class='tbl-c'> </td>". NEWLINE; 329 } 330 print"<td class='tbl-c'><a href='$result_update_page?test_id=$test_id&testset_id=$s_properties[testset_id]'>". lang_get('update') ."</a></td>". NEWLINE; // &testsetname=$testsetname 331 } 332 print"</tr>". NEWLINE; 333 334 } 335 print"</tbody>".NEWLINE; 336 print"</table>". NEWLINE; 337 338 #option is displayed,if user is manager 339 if( $user_is_manager && !$locked){ 340 print"<table>". NEWLINE; 341 print"<tr>". NEWLINE; 342 print"<td align='left'>". NEWLINE; 343 if( session_use_javascript() ) { 344 print"<input id=select_all type=checkbox name=thispage onClick='checkAll( this )'>\n". NEWLINE; 345 print"<label for=select_all>".lang_get("select_all")."</label>\n". NEWLINE; 346 } 347 print"<select name='action'>\n". NEWLINE; 348 $selected_value = ''; 349 $test_run_status = results_get_teststatus_by_project( $project_id ); 350 html_print_list_box_from_array( $test_run_status, $selected_value); 351 print"</select>\n". NEWLINE; 352 print"</td>\n". NEWLINE; 353 print"<td><input type='hidden' name='testset_id' value='$testset_id'></td>\n". NEWLINE; 354 print"<td><input type='submit' name=mass_update value='OK'></td>\n". NEWLINE; 355 print"</table>\n". NEWLINE; 356 } 357 358 } else { 359 360 print html_no_records_found_message( lang_get("no_tests_testset") ); 361 } 362 363 print"</form>\n". NEWLINE; 364 365} 366 367 368# display all test sets if the user has selected a build id 369elseif( !empty( $s_properties['build_id'] ) && $s_properties['build_id'] != 'all') { 370 371 # Move this above the if loop so it can be used by all queries on the page 372 $testset_tbl = TS_TBL; 373 $db_testset_id = TS_TBL .".". TS_ID; 374 $db_testset_name = TS_TBL .".". TS_NAME; 375 $db_testset_date_created = TS_TBL .".". TS_DATE_CREATED; 376 $db_testset_desc = TS_TBL .".". TS_DESCRIPTION; 377 $db_testset_status = TS_TBL .".". TS_STATUS; 378 $db_testset_signoff_by = TS_TBL .".". TS_SIGNOFF_BY; 379 $db_testset_signoff_date = TS_TBL .".". TS_SIGNOFF_DATE; 380 $db_testset_comments = TS_TBL .".". TS_SIGNOFF_COMMENTS; 381 $db_testset_orderby = TS_TBL .".". TS_ORDERBY; 382 $db_testset_build_id = TS_TBL .".". TS_BUILD_ID; 383 $db_testset_lock_date = TS_TBL .".". TS_LOCKCHANGE_DATE; 384 $db_testset_lock_by = TS_TBL .".". TS_LOCK_BY; 385 $db_testset_lock_comment = TS_TBL .".". TS_LOCK_COMMENT; 386 387 388 $q = "SELECT $db_testset_id, $db_testset_build_id, $db_testset_name, $db_testset_date_created, $db_testset_desc, $db_testset_status, $db_testset_signoff_by, $db_testset_signoff_date, $db_testset_comments, $db_testset_orderby, $db_testset_lock_by, $db_testset_lock_date, $db_testset_lock_comment FROM $testset_tbl WHERE $db_testset_build_id = '$s_properties[build_id]' ORDER BY $db_testset_orderby ASC". NEWLINE; 389 $rs = db_query( $db, $q ); 390 $num = db_num_rows( $db, $rs ); 391 //print"$q". NEWLINE; 392 393 # QUERY FOR THE MAX TestSetOrderBy. USED IN TABLE FORMATTING 394 $q_orderby = "SELECT MAX($db_testset_orderby) FROM $testset_tbl WHERE $db_testset_build_id = '$s_properties[build_id]'". NEWLINE; 395 $max_orderby = db_get_one($db, $q_orderby); //->GetOne($q_orderby); 396 //print"$q_orderby<br>". NEWLINE; 397 398 if( $num > 0 ) { 399 400 //print"<H3 align=center>Test Plan for Release: <B> $row_build[ReleaseName] </B> and Build: <B> $row_build[BuildName] </B> </H3>". NEWLINE; 401 print"<p> The following Test Plan lists the different types/ stages of testing that are required in order to ensure that the application is adequately tested. Each stage of testing should be signed off to provide assurance and traceability that the application is ready to be released.</p>". NEWLINE; 402 403 # simplify the url used later on the page for href 404 $query_string = "release_id=". $s_properties['release_id'] ."&build_id=". $s_properties['build_id']; 405 406 print"<br>". NEWLINE; 407 print"<div align='center'>". NEWLINE; 408 print"<table class='width100' rules='cols'>". NEWLINE; 409 print"<tr class='tbl_header'>". NEWLINE; 410 html_tbl_print_header( lang_get('id') ); 411 if( $max_orderby > 1 ) { 412 html_tbl_print_header( lang_get('up') ); 413 html_tbl_print_header( lang_get('down') ); 414 } 415 html_tbl_print_header( lang_get('testset_name') ); 416 html_tbl_print_header( lang_get('date_created') ); 417 html_tbl_print_header( lang_get('description') ); 418 html_tbl_print_header( lang_get('status') ); 419 # page not implemented yet, column disabled! 420 #html_tbl_print_header( lang_get('detail') ); 421 html_tbl_print_header( lang_get('locked_by')); 422 html_tbl_print_header( lang_get('lock_date')); 423 html_tbl_print_header( lang_get('lock_comment')); 424 if($user_is_manager){ 425 html_tbl_print_header( lang_get('lock')); 426 } 427 html_tbl_print_header( lang_get('signed_off_by') ); 428 html_tbl_print_header( lang_get('sign_off_date') ); 429 html_tbl_print_header( lang_get('comments') ); 430 html_tbl_print_header( lang_get('sign_off') ); 431 print"</tr>". NEWLINE; 432 433 434 435 while( $row = db_fetch_row( $db, $rs ) ) { 436 437 $testset_id = $row[TS_ID]; 438 $testset_name = $row[TS_NAME]; 439 $testset_date_created = $row[TS_DATE_CREATED]; 440 $testset_description = $row[TS_DESCRIPTION]; 441 $testset_status = $row[TS_STATUS]; 442 $testset_signoff_date = $row[TS_SIGNOFF_DATE]; 443 $testset_signoff_by = $row[TS_SIGNOFF_BY]; 444 $testset_comments = $row[TS_SIGNOFF_COMMENTS]; 445 $testset_orderby = $row[TS_ORDERBY]; 446 $testset_lockcomment = $row[TS_LOCK_COMMENT]; 447 $testset_lock_by = $row[TS_LOCK_BY]; 448 $testset_lock_date = $row[TS_LOCKCHANGE_DATE]; 449 $locked = testset_get_lock_status($testset_id); 450 451 if($locked){ 452 $lock_link = 'unlock'; 453 $lockdatetext = 'locked_on'; 454 }else{ 455 $lock_link = 'lock'; 456 $lockdatetext = 'unlocked_on'; 457 } 458 459 # Format testset_id and date. Alternate bg_color 460 $formatted_testset_id = sprintf("%05s",trim( $testset_id ) ); 461 $formatted_date_created = substr($testset_date_created, 0, 10); 462 $formatted_signoff_date = substr($testset_signoff_date, 0, 10); 463 $formatted_lock_date = substr($testset_lock_date, 0, 10); 464 $row_style = html_tbl_alternate_bgcolor( $row_style ); 465 466 467 # Display table data 468 print"<tr class='$row_style'>". NEWLINE; 469 $number_of_tests = admin_count_tests_in_testset($testset_id); 470 if ($number_of_tests > 0) { 471 print"<td align='center'><a href='$page?$query_string&testset_id=$testset_id'>$formatted_testset_id</a></td>". NEWLINE; 472 } 473 else { print"<td align='center'>$formatted_testset_id</td>". NEWLINE; 474 } 475 # Remove up arrow from the first record and down arrow from the last record if there is more than one testset 476 if( $max_orderby > 1 ) { 477 478 if( $testset_orderby != 1 ) { 479 #print"<td align='center'><a href='testset_reorder.php?$query_string&testset_id=$testset_id&row=$testset_orderby&move=up'><img src='./images/up_arrow.gif' width=10 height=10 border=0></a></td>". NEWLINE; 480 print"<td align='center'><img src='./images/up_arrow.gif' width=10 height=10 border=0></td>". NEWLINE; 481 } 482 else { 483 print"<td align='center'></td>". NEWLINE; 484 } 485 if( $testset_orderby != $max_orderby ) { 486 #print"<td align='center'><a href='testset_reorder.php?$query_string&testset_id=$testset_id&row=$testset_orderby&move=down'><img src='./images/down_arrow.gif' width=10 height=10 border=0></a></td>". NEWLINE; 487 print"<td align='center'><img src='./images/down_arrow.gif' width=10 height=10 border=0></td>". NEWLINE; 488 } 489 else { 490 print"<td align='center'></td>". NEWLINE; 491 } 492 } 493 print"<td align='center' nowrap>$testset_name</td>". NEWLINE; 494 print"<td align='center' nowrap>$formatted_date_created</td>". NEWLINE; 495 print"<td class='left'>$testset_description</td>". NEWLINE; 496 if ($number_of_tests > 0) { 497 print"<td align='center' nowrap>$testset_status</td>". NEWLINE; 498 } 499 else { print"<td align='center' nowrap>Empty</td>". NEWLINE; 500 } 501 # page not implemented yet, column disabled! 502 #print"<td align='center'><a href='$testset_status_page?$query_string&testset_id=$testset_id'>". lang_get('report') ."</a></td>". NEWLINE; 503 print"<td align='center'>$testset_lock_by</td>". NEWLINE; 504 if(!empty($testset_lock_date)){ 505 print"<td align='center'nowrap>". lang_get($lockdatetext) ." $formatted_lock_date</td>". NEWLINE; 506 } else { 507 print"<td align='center'nowrap></td>". NEWLINE; 508 } 509 print"<td align='center'>$testset_lockcomment</td>". NEWLINE; 510 if($user_is_manager){ 511 print"<td align='center'><a href='$testset_lock_page?$query_string&testset_id=$testset_id'>". lang_get($lock_link) ."</a></td>". NEWLINE; 512 } 513 print"<td align='center'>$testset_signoff_by</td>". NEWLINE; 514 print"<td align='center'nowrap>$formatted_signoff_date</td>". NEWLINE; 515 print"<td align='center'>$testset_comments</td>". NEWLINE; 516 print"<td align='center'><a href='$testset_signoff_page?$query_string&testset_id=$testset_id'>". lang_get('sign_off') ."</a></td>". NEWLINE; 517 print"</tr>". NEWLINE; 518 519 } # end while( $row = db_fetch_row( $db, $rs ) ) { 520 521 print"</table>". NEWLINE; 522 print"</div>". NEWLINE; 523 524 } # end if( $num > 0 ) { 525 else { 526 print"<br>". NEWLINE; 527 echo"<p class='error'>". lang_get( 'no_testsets' ) ."</p>". NEWLINE; 528 } 529 530 # DO WE WANT TO ADD A GRAPH FOR ALL TEST SETS IN THE BUILD? 531 # I'M THINKING THE DETAIL LINK WILL GIVE A GRAPH FOR THE INDIVIDUAL RUN 532 533 //} # if( isset( $s_properties['testset_id'] ) && $_GET['testset_id'] != 'all') { 534 535 536 # --------------------------------------------------------------------- 537 # --------------------------------------------------------------------- 538 539} # end elseif( isset( $s_properties['build_id'] ) && $_GET['build_id'] != 'all') 540 541 542html_print_footer(); 543 544# --------------------------------------------------------------------- 545# $Log: results_page.php,v $ 546# Revision 1.12 2008/08/04 06:54:58 peter_thal 547# added sorting function to several tables 548# 549# Revision 1.11 2008/07/25 09:50:02 peter_thal 550# added lock testset feature 551# disabled detail column in test result, because functionality is not implemented yet 552# 553# Revision 1.10 2008/07/02 12:01:25 peter_thal 554# test result mass update only for manager 555# 556# Revision 1.9 2008/01/22 09:57:38 cryobean 557# made the table sortable 558# removed possibility to reorder testsets because this functionality doesn't behave as expected - bug 559# 560# Revision 1.8 2007/02/03 10:25:53 gth2 561# no message 562# 563# Revision 1.7 2006/08/05 22:08:51 gth2 564# adding NEWLINE constant to support multiple OS newline chars - gth 565# 566# Revision 1.6 2006/05/08 15:37:33 gth2 567# Changing formatting - gth 568# 569# Revision 1.5 2006/04/09 15:54:31 gth2 570# removing some hard-coded field names 571# 572# Revision 1.4 2006/02/27 17:24:13 gth2 573# added autopass and testset duration functionality - gth 574# 575# Revision 1.3 2006/02/24 11:35:34 gth2 576# update to div - class=div-c not working in firefox - gth 577# 578# Revision 1.2 2006/02/09 12:34:27 gth2 579# changing db field names for consistency - gth 580# 581# Revision 1.1.1.1 2005/11/30 23:00:58 gth2 582# importing initial version - gth 583# 584# --------------------------------------------------------------------- 585 586?> 587