3 * Project Members Information
5 * Copyright 1999-2001 (c) VA Linux Systems
6 * Copyright 2002-2004 (c) GForge Team
7 * http://fusionforge.org/
9 * This file is part of FusionForge. FusionForge is free software;
10 * you can redistribute it and/or modify it under the terms of the
11 * GNU General Public License as published by the Free Software
12 * Foundation; either version 2 of the Licence, or (at your option)
15 * FusionForge is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License along
21 * with FusionForge; if not, write to the Free Software Foundation, Inc.,
22 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
25 require_once('../env.inc.php');
26 require_once $gfcommon.'include/pre.php';
28 $group_id = getIntFromGet("group_id");
29 $form_grp = getIntFromGet("form_grp");
31 if (!$group_id && $form_grp) {
32 $group_id = $form_grp;
35 site_project_header(array('title'=>_('Project Member List'),'group'=>$group_id,'toptab'=>'memberlist'));
37 echo '<p>' . _('If you would like to contribute to this project by becoming a developer, contact one of the project admins, designated in bold text below.') . '</p>';
39 // beginning of the user descripion block
40 $project =& group_get_object($group_id);
41 $project_stdzd_uri = util_make_url_g ($project->getUnixName(), $group_id);
42 $usergroup_stdzd_uri = $project_stdzd_uri.'members/';
43 print '<div about="'. $usergroup_stdzd_uri .'" typeof="sioc:UserGroup">';
44 print '<span rel="http://www.w3.org/2002/07/owl#sameAs" resource=""></span>';
45 print '<span rev="sioc:has_usergroup" resource="'. $project_stdzd_uri . '"></span>';
49 $title_arr[]=_('Member');
50 $title_arr[]=_('Username');
51 $title_arr[]=_('Role(s)/Position(s)');
52 if(forge_get_config('use_people')) {
53 $title_arr[]=_('Skills');
56 echo $GLOBALS['HTML']->listTableTop ($title_arr);
59 $members = $project->getUsers() ;
62 foreach ($members as $user) {
63 echo '<tr '.$HTML->boxGetAltRowStyle($i++).'>'."\n";
65 $member_uri = util_make_url_u ($user->getUnixName(),$user->getID());
67 print '<div about="'. $member_uri .'" typeof="sioc:UserAccount">';
68 print '<span rev="sioc:has_member" resource="'. $usergroup_stdzd_uri .'"></span>';
69 print '<span property="sioc:name" content="'. $user->getUnixName() .'"></span>';
70 if ( RBACEngine::getInstance()->isActionAllowedForUser($user,'project_admin',$project->getID())) {
71 // echo '<div rev="doap:developer" typeof="doap:Project" xmlns:doap="http://usefulinc.com/ns/doap#">';
72 echo '<strong>'.$user->getRealName().'</strong>';
75 // echo '<div rev="doap:maintainer" typeof="doap:Project" xmlns:doap="http://usefulinc.com/ns/doap#">';
76 echo $user->getRealName();
83 print '<span property ="dc:Identifier" content="'.$user->getID().'">';
85 print '<span property="foaf:accountName" content="'.$user->getUnixName().'">';
87 print '<span property="fusionforge:has_job" content="'.$role_string.'">';
90 $roles = RBACEngine::getInstance()->getAvailableRolesForUser ($user) ;
91 sortRoleList ($roles) ;
92 $role_names = array () ;
93 foreach ($roles as $role) {
94 if ($role->getHomeProject() && $role->getHomeProject()->getID() == $project->getID()) {
95 $role_names[] = $role->getName() ;
98 $role_string = implode (', ', $role_names) ;
101 echo util_display_user($user->getUnixName(),$user->getID(),$user->getUnixName(), 's');
103 echo '<td align="center">'.$role_string.'</td>';
104 if(forge_get_config('use_people')) {
105 echo '<td align="center">'.util_make_link ('/people/viewprofile.php?user_id='.$user->getID(),_('View')).'</td>';
109 // end of community member description block
110 echo $GLOBALS['HTML']->listTableBottom();
112 site_project_footer(array());