Main Page | Directories | File List | File Members

include/project/admin.php File Reference

Go to the source code of this file.

Functions

 show_grouphistory ($group_id)
 project_admin_registration_info ($row_grp)


Function Documentation

project_admin_registration_info row_grp  ) 
 

Definition at line 80 of file include/project/admin.php.

References db_fetch_array(), db_query(), group_id, and print.

00081 {
00082   $res_admin = db_query("SELECT user.user_id AS user_id,user.user_name AS user_name, user.realname AS realname, user.email AS email "
00083                         . "FROM user,user_group "
00084                         . "WHERE user_group.user_id=user.user_id AND user_group.group_id=".$row_grp['group_id']." AND "
00085                         . "user_group.admin_flags = 'A'");
00086 
00087 
00088   print '<p><span class="preinput">'._("Project Admins").':</span><br /> ';
00089   while ($row_admin = db_fetch_array($res_admin)) {
00090     print "<a href=\"".$GLOBALS['sys_home']."users/$row_admin[user_name]/\">$row_admin[realname] &lt;$row_admin[email]&gt;</a> ; ";
00091   }
00092 
00093   print '<p><span class="preinput">'._("Registration Date").':</span><br /> '.format_date($sys_datefmt,$row_grp[register_time]);
00094 
00095   print '<p><span class="preinput">'._("System Group Name:").'</span><br /> '.$row_grp[unix_group_name];
00096 
00097   print '<p><span class="preinput">'._("Submitted Description:").'</span><br /> '.utils_rich_markup($row_grp[register_purpose]);
00098 
00099   print '<p><span class="preinput">'._("Required software:").'</span><br /> '.utils_rich_markup($row_grp[required_software]);
00100 
00101   print '<p><span class="preinput">'._("Other comments:").'</span><br /> '.utils_rich_markup($row_grp[other_comments]);
00102 
00103   print '<p>';
00104   print utils_registration_history($row_grp[unix_group_name]);
00105 
00106 }

show_grouphistory group_id  ) 
 

Definition at line 32 of file include/project/admin.php.

References $field, $result, $rows, $title_arr, db_numrows(), db_result, and group_id.

00033 {
00034                 # show the group_history rows that are relevant to
00035                 # this group_id
00036   global $sys_datefmt;
00037   $result=group_get_history($group_id);
00038   $rows=db_numrows($result);
00039 
00040   if ($rows > 0) {
00041 
00042     echo '
00043                 <h3>'
00044       ._("Group Change History").'</h3>
00045                 <p>';
00046     $title_arr=array();
00047     $title_arr[]=_("Field");
00048     $title_arr[]=_("Value");
00049     $title_arr[]=_("Date");
00050     $title_arr[]=_("By");
00051 
00052     echo html_build_list_table_top ($title_arr);
00053 
00054     for ($i=0; $i < $rows; $i++) {
00055       $field=db_result($result, $i, 'field_name');
00056       echo '
00057                         <tr class="'. html_get_alt_row_color($i) .'"><td>'.$field.'</td><td>';
00058 
00059       if ($field=='removed user') {
00060         echo user_getname(db_result($result, $i, 'old_value'));
00061       } else {
00062         echo db_result($result, $i, 'old_value');
00063       }
00064       echo '</td>'.
00065         '<td>'.format_date($sys_datefmt,db_result($result, $i, 'date')).'</td>'.
00066         '<td>'.db_result($result, $i, 'user_name').'</td></tr>';
00067     }
00068 
00069     echo '
00070                 </table>';
00071 
00072   } else {
00073     echo '
00074                 <h3>'
00075       ._("No Changes Have Been Made to This Group").'</h3>';
00076   }
00077 }


Generated on Sun Feb 26 13:23:04 2006 for Savane PHP Frontend Developer Reference by  doxygen 1.4.4