[ Index ]
 

Code source de Mantis 1.1.0rc3

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/ -> manage_config_workflow_page.php (source)

   1  <?php
   2  # Mantis - a php based bugtracking system
   3  
   4  # Copyright (C) 2000 - 2002  Kenzaburo Ito - kenito@300baud.org
   5  # Copyright (C) 2002 - 2007  Mantis Team   - mantisbt-dev@lists.sourceforge.net
   6  
   7  # Mantis is free software: you can redistribute it and/or modify
   8  # it under the terms of the GNU General Public License as published by
   9  # the Free Software Foundation, either version 2 of the License, or
  10  # (at your option) any later version.
  11  #
  12  # Mantis is distributed in the hope that it will be useful,
  13  # but WITHOUT ANY WARRANTY; without even the implied warranty of
  14  # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  15  # GNU General Public License for more details.
  16  #
  17  # You should have received a copy of the GNU General Public License
  18  # along with Mantis.  If not, see <http://www.gnu.org/licenses/>.
  19  
  20      # --------------------------------------------------------
  21      # $Id: manage_config_workflow_page.php,v 1.21.2.1 2007-10-13 22:33:25 giallu Exp $
  22      # --------------------------------------------------------
  23  
  24      require_once ( 'core.php' );
  25  
  26      $t_core_path = config_get( 'core_path' );
  27      require_once ( $t_core_path . 'email_api.php' );
  28  
  29      auth_reauthenticate();
  30  
  31      html_page_top1( lang_get( 'manage_workflow_config' ) );
  32      html_page_top2();
  33  
  34      print_manage_menu( 'adm_permissions_report.php' );
  35      print_manage_config_menu( 'manage_config_workflow_page.php' );
  36  
  37      $t_access = current_user_get_access_level();
  38      $t_project = helper_get_current_project();
  39      $t_can_change_workflow = $t_access >= config_get_access( 'status_enum_workflow' );
  40      $t_can_change_flags = $t_can_change_workflow;
  41      $t_overrides = array();
  42      
  43  	function set_overrides( $p_config ) {
  44         global $t_overrides;
  45         if ( ! in_array( $p_config, $t_overrides ) ) {
  46             $t_overrides[] = $p_config;
  47         }
  48      }
  49  
  50  	function parse_workflow( $p_enum_workflow ) {
  51          $t_status_arr  = get_enum_to_array( config_get( 'status_enum_string' ) );
  52          if ( 0 == count( $p_enum_workflow ) ) {
  53              # workflow is not set, default it to all transitions
  54              foreach ( $t_status_arr as $t_status => $t_label ) {
  55                  $t_temp_workflow = array();
  56                  foreach ( $t_status_arr as $t_next => $t_next_label ) {
  57                      if ( $t_status <> $t_next ) {
  58                         $t_temp_workflow[] = $t_next . ':' . $t_next_label;
  59                      }
  60                  }
  61                  $p_enum_workflow[$t_status] = implode( ',', $t_temp_workflow );
  62              }
  63          }
  64  
  65          $t_entry = array();
  66          $t_exit = array();
  67  
  68          # prepopulate new bug state (bugs go from nothing to here)
  69          $t_submit_status_array = config_get( 'bug_submit_status' );
  70          $t_new_label = get_enum_to_string( lang_get( 'status_enum_string' ), NEW_ );
  71          if ( is_array( $t_submit_status_array ) ) {
  72              # @@@ (thraxisp) this is not implemented in bug_api.php
  73              foreach ($t_submit_status_array as $t_access => $t_status ) {
  74                  $t_entry[$t_status][0] = $t_new_label;
  75                  $t_exit[0][$t_status] = $t_new_label;
  76              }
  77          } else {
  78              $t_status = $t_submit_status_array;
  79              $t_entry[$t_status][0] = $t_new_label;
  80              $t_exit[0][$t_status] = $t_new_label;
  81          }
  82  
  83          # add user defined arcs and implicit reopen arcs
  84          $t_reopen = config_get( 'bug_reopen_status' );
  85          $t_reopen_label = get_enum_to_string( lang_get( 'resolution_enum_string' ), REOPENED );
  86          $t_resolved_status = config_get( 'bug_resolved_status_threshold' );
  87          $t_default = array();
  88          foreach ( $t_status_arr as $t_status => $t_status_label ) {
  89              if ( isset( $p_enum_workflow[$t_status] ) ) {
  90                  $t_next_arr = get_enum_to_array( $p_enum_workflow[$t_status] );
  91                  foreach ( $t_next_arr as $t_next => $t_next_label) {
  92                      if ( ! isset( $t_default[$t_status] ) ) {
  93                          $t_default[$t_status] = $t_next;
  94                      }
  95                      $t_exit[$t_status][$t_next] = '';
  96                      $t_entry[$t_next][$t_status] = '';
  97                  }
  98              } else {
  99                  $t_exit[$t_status] = array();
 100              }
 101              if ( $t_status >= $t_resolved_status ) {
 102                  $t_exit[$t_status][$t_reopen] = $t_reopen_label;
 103                  $t_entry[$t_reopen][$t_status] = $t_reopen_label;
 104              }
 105              if ( ! isset( $t_entry[$t_status] ) ) {
 106                  $t_entry[$t_status] = array();
 107              }
 108          }
 109          return array( 'entry' => $t_entry, 'exit' => $t_exit, 'default' => $t_default );
 110      }
 111  
 112  
 113      # Get the value associated with the specific action and flag.
 114  	function show_flag( $p_from_status_id, $p_to_status_id ) {
 115          global $t_can_change_workflow, $t_overrides, $t_file_workflow, $t_global_workflow, $t_project_workflow, $t_colour_global, $t_colour_project;
 116          if ( $p_from_status_id <> $p_to_status_id ) {
 117              $t_file = isset( $t_file_workflow['exit'][$p_from_status_id][$p_to_status_id] ) ? 1 : 0 ;
 118              $t_global = isset( $t_global_workflow['exit'][$p_from_status_id][$p_to_status_id] ) ? 1 : 0 ;
 119              $t_project = isset( $t_project_workflow['exit'][$p_from_status_id][$p_to_status_id] ) ? 1 : 0;
 120  
 121              $t_colour = '';
 122              if ( $t_global != $t_file ) {
 123                  $t_colour = ' bgcolor="' . $t_colour_global . '" '; # all projects override
 124                  if ( $t_can_change_workflow ) {
 125                      set_overrides( 'status_enum_workflow' );
 126                  }
 127              }
 128              if ( $t_project != $t_global ) {
 129                  $t_colour = ' bgcolor="' . $t_colour_project . '" '; # project overrides
 130                  if ( $t_can_change_workflow ) {
 131                      set_overrides( 'status_enum_workflow' );
 132                  }
 133              }
 134              $t_value = '<td class="center"' . $t_colour . '>';
 135  
 136              $t_flag = ( 1 == $t_project );
 137              $t_label = $t_flag ? $t_project_workflow['exit'][$p_from_status_id][$p_to_status_id] : '';
 138  
 139              if ( $t_can_change_workflow ) {
 140                  $t_flag_name = $p_from_status_id . ':' . $p_to_status_id;
 141                  $t_set = $t_flag ? "CHECKED" : "";
 142                  $t_value .= "<input type=\"checkbox\" name=\"flag[]\" value=\"$t_flag_name\" $t_set />";
 143              } else {
 144                  $t_value .= $t_flag ? '<img src="images/ok.gif" width="20" height="15" title="X" alt="X" />' : '&nbsp;';
 145              }
 146  
 147              if ( $t_flag && ( '' != $t_label ) ) {
 148                  $t_value .= '<br />(' . $t_label . ')';
 149              }
 150          } else {
 151              $t_value = '<td>&nbsp;';
 152          }
 153  
 154          $t_value .= '</td>';
 155  
 156          return $t_value;
 157      }
 158  
 159  	function section_begin( $p_section_name ) {
 160          $t_enum_status = explode_enum_string( config_get( 'status_enum_string' ) );
 161          echo '<table class="width100">';
 162          echo '<tr><td class="form-title" colspan="' . ( count( $t_enum_status ) + 2 ) . '">'
 163              . strtoupper( $p_section_name ) . '</td></tr>' . "\n";
 164          echo '<tr><td class="form-title" width="30%" rowspan="2">' . lang_get( 'current_status' ) . '</td>';
 165          echo '<td class="form-title" style="text-align:center" colspan="' . ( count( $t_enum_status ) + 1 ) . '">'
 166              . lang_get( 'next_status' ) . '</td></tr>';
 167          echo "\n<tr>";
 168          foreach( $t_enum_status as $t_status ) {
 169              $t_entry_array = explode_enum_arr( $t_status );
 170              echo '<td class="form-title" style="text-align:center">&nbsp;' . string_no_break( get_enum_to_string( lang_get( 'status_enum_string' ), $t_entry_array[0] ) ) . '&nbsp;</td>';
 171          }
 172              echo '<td class="form-title" style="text-align:center">' . lang_get( 'custom_field_default_value' ) . '</td>';
 173          echo '</tr>' . "\n";
 174      }
 175  
 176  	function capability_row( $p_from_status ) {
 177          global $t_file_workflow, $t_global_workflow, $t_project_workflow, $t_colour_global, $t_colour_project, $t_can_change_workflow;
 178          $t_enum_status = get_enum_to_array( config_get( 'status_enum_string' ) );
 179          echo '<tr ' . helper_alternate_class() . '><td>' . string_no_break( get_enum_to_string( lang_get( 'status_enum_string' ), $p_from_status ) ) . '</td>';
 180          foreach ( $t_enum_status as $t_to_status_id => $t_to_status_label ) {
 181              echo show_flag( $p_from_status, $t_to_status_id );
 182          }
 183  
 184          $t_file = isset( $t_file_workflow['default'][$p_from_status] ) ? $t_file_workflow['default'][$p_from_status] : 0 ;
 185          $t_global = isset( $t_global_workflow['default'][$p_from_status] ) ? $t_global_workflow['default'][$p_from_status] : 0 ;
 186          $t_project = isset( $t_project_workflow['default'][$p_from_status] ) ? $t_project_workflow['default'][$p_from_status] : 0;
 187  
 188          $t_colour = '';
 189          if ( $t_global != $t_file ) {
 190              $t_colour = ' bgcolor="' . $t_colour_global . '" '; # all projects override
 191              if ( $t_can_change_workflow ) {
 192                  set_overrides( 'status_enum_workflow' );
 193              }
 194          }
 195          if ( $t_project != $t_global ) {
 196              $t_colour = ' bgcolor="' . $t_colour_project . '" '; # project overrides
 197              if ( $t_can_change_workflow ) {
 198                  set_overrides( 'status_enum_workflow' );
 199              }
 200          }
 201          echo '<td class="center"' . $t_colour . '>';
 202          if ( $t_can_change_workflow ) {
 203              echo '<select name="default_' . $p_from_status . '">';
 204              print_enum_string_option_list( 'status', $t_project );
 205              echo '</select>';
 206          } else {
 207              echo get_enum_to_string( lang_get( 'status_enum_string' ), $t_project );
 208          }
 209          echo ' </td>';
 210          echo '</tr>' . "\n";
 211      }
 212  
 213  	function section_end() {
 214          echo '</table><br />' . "\n";
 215      }
 216  
 217  	function threshold_begin( $p_section_name ) {
 218          echo '<table class="width100">';
 219          echo '<tr><td class="form-title" colspan="3">' . strtoupper( $p_section_name ) . '</td></tr>' . "\n";
 220          echo '<tr><td class="form-title" width="30%">' . lang_get( 'threshold' ) . '</td>';
 221          echo '<td class="form-title" >' . lang_get( 'status_level' ) . '</td>';
 222          echo '<td class="form-title" >' . lang_get( 'alter_level' ) . '</td></tr>';
 223          echo "\n";
 224      }
 225  
 226  	function threshold_row( $p_threshold ) {
 227          global $t_access, $t_can_change_flags, $t_colour_project, $t_colour_global;
 228  
 229          $t_file = config_get_global( $p_threshold );
 230          $t_global = config_get( $p_threshold, null, null, ALL_PROJECTS );
 231          $t_project = config_get( $p_threshold );
 232          $t_can_change_threshold = $t_access >= config_get_access( $p_threshold );
 233          $t_colour = '';
 234          if ( $t_global != $t_file ) {
 235              $t_colour = ' bgcolor="' . $t_colour_global . '" '; # all projects override
 236              if ( $t_can_change_threshold ) {
 237                  set_overrides( $p_threshold );
 238              }
 239          }
 240          if ( $t_project != $t_global ) {
 241              $t_colour = ' bgcolor="' . $t_colour_project . '" '; # project overrides
 242              if ( $t_can_change_threshold ) {
 243                  set_overrides( $p_threshold );
 244              }
 245          }
 246  
 247          echo '<tr ' . helper_alternate_class() . '><td>' . lang_get( 'desc_' . $p_threshold ) . '</td>';
 248          if ( $t_can_change_threshold ) {
 249              echo '<td' . $t_colour . '><select name="threshold_' . $p_threshold . '">';
 250              print_enum_string_option_list( 'status', $t_project );
 251              echo '</select> </td>';
 252              echo '<td><select name="access_' . $p_threshold . '">';
 253              print_enum_string_option_list( 'access_levels', config_get_access( $p_threshold ) );
 254              echo '</select> </td>';
 255              $t_can_change_flags = true;
 256          } else {
 257              echo '<td' . $t_colour . '>' . get_enum_to_string( lang_get( 'status_enum_string' ), $t_project ) . '&nbsp;</td>';
 258              echo '<td>' . get_enum_to_string( lang_get( 'access_levels_enum_string' ), config_get_access( $p_threshold ) ) . '&nbsp;</td>';
 259          }
 260  
 261          echo '</tr>' . "\n";
 262      }
 263  
 264  	function threshold_end() {
 265          echo '</table><br />' . "\n";
 266      }
 267  
 268  	function access_begin( $p_section_name ) {
 269          $t_enum_status = explode_enum_string( config_get( 'status_enum_string' ) );
 270          echo '<table class="width100">';
 271          echo '<tr><td class="form-title" colspan="2">'
 272              . strtoupper( $p_section_name ) . '</td></tr>' . "\n";
 273          echo '<tr><td class="form-title" colspan="2">' . lang_get( 'access_change' ) . '</td></tr>';
 274      }
 275  
 276  	function access_row( ) {
 277          global $t_access, $t_can_change_flags, $t_colour_project, $t_colour_global;
 278  
 279          $t_enum_status = get_enum_to_array( config_get( 'status_enum_string' ) );
 280  
 281          $t_file_new = config_get_global( 'report_bug_threshold' );
 282          $t_global_new = config_get( 'report_bug_threshold', null, null, ALL_PROJECTS );
 283          $t_project_new = config_get( 'report_bug_threshold' );
 284  
 285          $t_file_set = config_get_global( 'set_status_threshold' );
 286          foreach ( $t_enum_status as $t_status => $t_status_label) {
 287              if ( ! isset( $t_file_set[$t_status] ) ) {
 288                  $t_file_set[$t_status] = config_get_global('update_bug_status_threshold');
 289              }
 290          }
 291  
 292          $t_global_set = config_get( 'set_status_threshold', null, null, ALL_PROJECTS );
 293          foreach ( $t_enum_status as $t_status => $t_status_label) {
 294              if ( ! isset( $t_file_set[$t_status] ) ) {
 295                  $t_file_set[$t_status] = config_get('update_bug_status_threshold', null, null, ALL_PROJECTS );
 296              }
 297          }
 298  
 299          $t_project_set = config_get( 'set_status_threshold' );
 300          foreach ( $t_enum_status as $t_status => $t_status_label) {
 301              if ( ! isset( $t_file_set[$t_status] ) ) {
 302                  $t_file_set[$t_status] = config_get('update_bug_status_threshold' );
 303              }
 304          }
 305  
 306          foreach ( $t_enum_status as $t_status => $t_status_label) {
 307              echo '<tr ' . helper_alternate_class() . '><td width="30%">' . string_no_break( get_enum_to_string( lang_get( 'status_enum_string' ), $t_status ) ) . '</td>';
 308              if ( NEW_ == $t_status ) {
 309                  $t_level = $t_project_new;
 310                  $t_can_change = ( $t_access >= config_get_access( 'report_bug_threshold' ) );
 311                  $t_colour = '';
 312                  if ( $t_global_new != $t_file_new ) {
 313                      $t_colour = ' bgcolor="' . $t_colour_global . '" '; # all projects override
 314                      if ( $t_can_change ) {
 315                          set_overrides( 'report_bug_threshold' );
 316                      }
 317                  }
 318                  if ( $t_project_new != $t_global_new ) {
 319                      $t_colour = ' bgcolor="' . $t_colour_project . '" '; # project overrides
 320                      if ( $t_can_change ) {
 321                          set_overrides( 'report_bug_threshold' );
 322                      }
 323                  }
 324              } else {
 325                  $t_level = ( isset( $t_project_set[$t_status] ) ? $t_project_set[$t_status] : false );
 326                  $t_level_global = ( isset( $t_global_set[$t_status] ) ? $t_global_set[$t_status] : false );
 327                  $t_level_file = ( isset( $t_file_set[$t_status] ) ? $t_file_set[$t_status] : false );
 328                  $t_can_change = ( $t_access >= config_get_access( 'set_status_threshold' ) );
 329                  $t_colour = '';
 330                  if ( $t_level_global != $t_level_file ) {
 331                      $t_colour = ' bgcolor="' . $t_colour_global . '" '; # all projects override
 332                      if ( $t_can_change ) {
 333                          set_overrides( 'set_status_threshold' );
 334                      }
 335                  }
 336                  if ( $t_level != $t_level_global ) {
 337                      $t_colour = ' bgcolor="' . $t_colour_project . '" '; # project overrides
 338                      if ( $t_can_change ) {
 339                          set_overrides( 'set_status_threshold' );
 340                      }
 341                  }
 342              }
 343              if ( $t_can_change ) {
 344                  echo '<td' . $t_colour . '><select name="access_change_' . $t_status . '">';
 345                  print_enum_string_option_list( 'access_levels', $t_level );
 346                  echo '</select> </td>';
 347                  $t_can_change_flags = true;
 348              } else {
 349                  echo '<td class="center"' . $t_colour . '>' . get_enum_to_string( lang_get( 'access_levels_enum_string' ), $t_level ) . '</td>';
 350              }
 351              echo '</tr>' . "\n";
 352          }
 353      }
 354  
 355      echo '<br /><br />';
 356  
 357      # count arcs in and out of each status
 358      $t_enum_status = config_get( 'status_enum_string' );
 359      $t_status_arr  = get_enum_to_array( $t_enum_status );
 360  
 361      $t_extra_enum_status = '0:non-existent,' . $t_enum_status;
 362      $t_lang_enum_status = '0:' . lang_get( 'non_existent' ) . ',' . lang_get( 'status_enum_string' );
 363      $t_all_status = explode( ',', $t_extra_enum_status);
 364  
 365      # gather all versions of the workflow
 366      $t_file_workflow = parse_workflow( config_get_global( 'status_enum_workflow' ) );
 367      $t_global_workflow = parse_workflow( config_get( 'status_enum_workflow', null, null, ALL_PROJECTS ) );
 368      $t_project_workflow = parse_workflow( config_get( 'status_enum_workflow' ) );
 369  
 370      # validate the project workflow
 371      $t_validation_result = '';
 372      foreach ( $t_status_arr as $t_status => $t_label ) {
 373          if ( isset( $t_project_workflow['exit'][$t_status][$t_status] ) ) {
 374              $t_validation_result .= '<tr ' . helper_alternate_class() . '><td>'
 375                              . get_enum_to_string( $t_lang_enum_status, $t_status )
 376                              . '</td><td bgcolor="#FFED4F">' . lang_get( 'superfluous' ) . '</td>';
 377          }
 378      }
 379  
 380      # check for entry == 0 without exit == 0, unreachable state
 381      foreach ( $t_status_arr as $t_status => $t_status_label) {
 382          if ( ( 0 == count( $t_project_workflow['entry'][$t_status] ) ) && ( 0 < count( $t_project_workflow['exit'][$t_status] ) ) ){
 383              $t_validation_result .= '<tr ' . helper_alternate_class() . '><td>'
 384                              . get_enum_to_string( $t_lang_enum_status, $t_status )
 385                              . '</td><td bgcolor="#FF0088">' . lang_get( 'unreachable' ) . '</td>';
 386          }
 387      }
 388  
 389      # check for exit == 0 without entry == 0, unleaveable state
 390      foreach ( $t_status_arr as $t_status => $t_status_label ) {
 391          if ( ( 0 == count( $t_project_workflow['exit'][$t_status] ) ) && ( 0 < count( $t_project_workflow['entry'][$t_status] ) ) ){
 392              $t_validation_result .= '<tr ' . helper_alternate_class() . '><td>'
 393                              . get_enum_to_string( $t_lang_enum_status, $t_status )
 394                              . '</td><td bgcolor="#FF0088">' . lang_get( 'no_exit' ) . '</td>';
 395          }
 396      }
 397  
 398      # check for exit == 0 and entry == 0, isolated state
 399      foreach ( $t_status_arr as $t_status => $t_status_label ) {
 400          if ( ( 0 == count( $t_project_workflow['exit'][$t_status] ) ) && ( 0 == count( $t_project_workflow['entry'][$t_status] ) ) ){
 401              $t_validation_result .= '<tr ' . helper_alternate_class() . '><td>'
 402                              . get_enum_to_string( $t_lang_enum_status, $t_status )
 403                              . '</td><td bgcolor="#FF0088">' . lang_get( 'unreachable' ) . '<br />' . lang_get( 'no_exit' ) . '</td>';
 404          }
 405      }
 406  
 407      $t_colour_project = config_get( 'colour_project');
 408      $t_colour_global = config_get( 'colour_global');
 409  
 410      echo "<form name=\"workflow_config_action\" method=\"post\" action=\"manage_config_workflow_set.php\">\n";
 411  
 412      if ( ALL_PROJECTS == $t_project ) {
 413          $t_project_title = lang_get( 'config_all_projects' );
 414      } else {
 415          $t_project_title = sprintf( lang_get( 'config_project' ) , string_display( project_get_name( $t_project ) ) );
 416      }
 417      echo '<p class="bold">' . $t_project_title . '</p>' . "\n";
 418      echo '<p>' . lang_get( 'colour_coding' ) . '<br />';
 419      if ( ALL_PROJECTS <> $t_project ) {
 420          echo '<span style="background-color:' . $t_colour_project . '">' . lang_get( 'colour_project' ) .'</span><br />';
 421      }
 422      echo '<span style="background-color:' . $t_colour_global . '">' . lang_get( 'colour_global' ) . '</span></p>';
 423  
 424      # show the settings used to derive the table
 425      threshold_begin( lang_get( 'workflow_thresholds' ) );
 426      if ( ! is_array( config_get( 'bug_submit_status' ) ) ) {
 427          threshold_row( 'bug_submit_status' );
 428      }
 429      threshold_row( 'bug_resolved_status_threshold' );
 430      threshold_row( 'bug_reopen_status' );
 431      threshold_end();
 432      echo '<br />';
 433  
 434      if ( '' <> $t_validation_result ) {
 435          echo '<table class="width100">';
 436          echo '<tr><td class="form-title" colspan="3">' . strtoupper( lang_get( 'validation' ) ) . '</td></tr>' . "\n";
 437          echo '<tr><td class="form-title" width="30%">' . lang_get( 'status' ) . '</td>';
 438          echo '<td class="form-title" >' . lang_get( 'comment' ) . '</td></tr>';
 439          echo "\n";
 440          echo $t_validation_result;
 441          echo '</table><br /><br />';
 442      }
 443  
 444      # display the graph as a matrix
 445      section_begin( lang_get( 'workflow' ) );
 446      foreach ( $t_status_arr as $t_from_status => $t_from_label) {
 447          capability_row( $t_from_status );
 448      }
 449      section_end();
 450  
 451      if ( $t_can_change_workflow ) {
 452          echo '<p>' . lang_get( 'workflow_change_access' ) . ':';
 453          echo '<select name="workflow_access">';
 454          print_enum_string_option_list( 'access_levels', config_get_access( 'status_enum_workflow' ) );
 455          echo '</select> </p><br />';
 456      }
 457  
 458      # display the access levels required to move an issue
 459      access_begin( lang_get( 'access_levels' ) );
 460      access_row( );
 461      section_end();
 462  
 463      if ( $t_access >= config_get_access( 'set_status_threshold' ) ) {
 464          echo '<p>' . lang_get( 'access_change_access' ) . ':';
 465          echo '<select name="status_access">';
 466          print_enum_string_option_list( 'access_levels', config_get_access( 'set_status_threshold' ) );
 467          echo '</select> </p><br />';
 468      }
 469  
 470      if ( $t_can_change_flags ) {
 471          echo "<input type=\"submit\" class=\"button\" value=\"" . lang_get( 'change_configuration' ) . "\" />\n";
 472          echo "</form>\n";
 473  
 474          if ( 0 < count( $t_overrides ) ) {
 475              echo "<div class=\"right\"><form name=\"mail_config_action\" method=\"post\" action=\"manage_config_revert.php\">\n";
 476              echo "<input name=\"revert\" type=\"hidden\" value=\"" . implode( ',', $t_overrides ) . "\"></input>";
 477              echo "<input name=\"project\" type=\"hidden\" value=\"$t_project\"></input>";
 478              echo "<input name=\"return\" type=\"hidden\" value=\"" . $_SERVER['PHP_SELF'] ."\"></input>";
 479              echo "<input type=\"submit\" class=\"button\" value=\"";
 480              if ( ALL_PROJECTS == $t_project ) {
 481                  echo lang_get( 'revert_to_system' );
 482              } else {
 483                  echo lang_get( 'revert_to_all_project' );
 484              }
 485              echo "\" />\n";
 486              echo "</form></div>\n";
 487          }
 488  
 489      } else {
 490          echo "</form>\n";
 491      }
 492  
 493      html_page_bottom1( __FILE__ );
 494  ?>


Généré le : Thu Nov 29 09:42:17 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics