head	1.8;
access;
symbols
	TIGRIS_1_1_0RC2:1.6
	TIGRIS_1_1_0RC1:1.6
	TIGRIS_1_1:1.6.0.4
	TIGRIS_1_0_8:1.6
	TIGRIS_1_0_8RC3:1.6
	TIGRIS_1_0_8RC2:1.6
	TIGRIS_1_0_8RC1:1.6
	TIGRIS_1_0_7:1.6
	TIGRIS_1_0_7RC3:1.6
	TIGRIS_1_0_7RC2:1.6
	TIGRIS_1_0_7RC1:1.6
	TIGRIS_1_0_6:1.6
	TIGRIS_1_0_6RC5:1.6
	TIGRIS_1_0_6RC4:1.6
	TIGRIS_1_0_6RC3:1.6
	TIGRIS_1_0_6RC2:1.6
	TIGRIS_1_0_6RC1:1.6
	TIGRIS_1_0_5:1.6
	TIGRIS_1_0_5RC6:1.6
	TIGRIS_1_0_5RC5:1.6
	TIGRIS_1_0_5RC4:1.6
	TIGRIS_1_0_5RC3:1.6
	TIGRIS_1_0_5RC2:1.6
	TIGRIS_1_0_5RC1:1.6
	TIGRIS_1_0_4:1.6
	TIGRIS_1_0_3:1.6
	TIGRIS_1_0_2:1.6
	TIGRIS_1_0_1:1.6
	TIGRIS_1_0:1.6.0.6
	TIGRIS_1_0_0:1.6
	TIGRIS_1_0_0_RC1:1.6.0.2
	dlr:1.1.1
	TIGRIS_0_9_2_4:1.4
	TIGRIS_0_9_2_3:1.4
	HELM_PEER_PORT_BRANCH:1.1.1.2
	TURBINE_PEER:1.4
	TIGRIS_0_9_2_1:1.4
	TIGRIS_0_9_2:1.4.0.4
	TIGRIS_0_9_0:1.4.0.2
	TIGRIS_0_8_4:1.3.0.2
	NEWHELM:1.1.1.1
	TIGRIS_NOV_12_2000:1.1.1;
locks; strict;
comment	@# @;


1.8
date	2001.05.23.02.04.14;	author dlr;	state dead;
branches;
next	1.7;

1.7
date	2001.05.13.07.35.19;	author jrobbins;	state Exp;
branches;
next	1.6;

1.6
date	2001.03.24.09.06.03;	author jrobbins;	state Exp;
branches;
next	1.5;

1.5
date	2001.02.21.01.08.29;	author dlr;	state Exp;
branches;
next	1.4;

1.4
date	2000.12.15.22.49.51;	author elicia;	state Exp;
branches
	1.4.6.1;
next	1.3;

1.3
date	2000.11.27.19.14.35;	author susank;	state Exp;
branches;
next	1.2;

1.2
date	2000.11.15.17.19.16;	author leonardr;	state Exp;
branches;
next	1.1;

1.1
date	2000.11.12.21.18.09;	author dlr;	state Exp;
branches
	1.1.1.1;
next	;

1.1.1.1
date	2000.11.12.21.18.09;	author dlr;	state Exp;
branches;
next	1.1.1.2;

1.1.1.2
date	2001.02.21.00.36.54;	author dlr;	state Exp;
branches;
next	;

1.4.6.1
date	2001.02.12.18.05.58;	author leonardr;	state Exp;
branches;
next	1.4.6.2;

1.4.6.2
date	2001.02.12.18.06.25;	author leonardr;	state Exp;
branches;
next	1.4.6.3;

1.4.6.3
date	2001.02.12.21.57.36;	author leonardr;	state Exp;
branches;
next	;


desc
@@


1.8
log
@Removed WM templates in favor of Velocity templates.
@
text
@#parse "$BRAND_TEMPLATE_ROOT/Admin_Nav.wm"

<FORM NAME="UserRoleAddForm" METHOD="post" ACTION="UserRoleAdd">
<INPUT TYPE="hidden" NAME="userID" VALUE="$currentUser.getID()">
<TABLE BORDER="0" CELLSPACING="1" CELLPADDING="3" BORDER="0" WIDTH="100%">
  <TR>
    <TD class="Header" nowrap>Add User Role: <SPAN CLASS="ProjectNameHeader">$currentDomain.getName()</SPAN></TD>  
  </TR>
</TABLE>

<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="2" BORDER="0" width="100%">
  <TR>
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginName() on the following projects:</TD>
  </TR>
  <TR>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Add</TD>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Project</TD>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Description</TD>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Current Roles</TD>
  </TR> 

#set $projects=$currentDomain.getProjects($acl)
#if ($projects.isEmpty())
{
 <tr><td colspan="3">
  <span class="Warning">No matching projects found.</span>
 </td></tr> 
} #else {
 #foreach $project in $currentDomain.getProjects($acl)
 {
   <TR> 
     <TD><INPUT TYPE="CHECKBOX" NAME="Grant $project.getID()" VALUE="CheckBox"></TD> 
     <TD class="PlainText" VALIGN="top">
      #if ($acl.hasPermission("Project - Edit", $project))
      {
       <A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A>
      } #else {
       $project.getName()
      }
     </TD> 
     <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
     #set $roles = $currentUser.getRolesInProject($project)
     <TD class="PlainText" VALIGN="top">
     #set $first=true
     #foreach $role in $roles
     {
      #if (!$first)
      {
,
      }
      $role.getName()
      #set $first=false
     }
     </TD>
    </TR> 
 }

 <TR>
  <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant these roles on all selected projects:</TD>
 </TR>
 <TR>
  <TD COLSPAN="3" class="PlainText">
   <select name="roles" multiple>
    #foreach $role in $host.getProjectRoles()
    {
     <option value="$role.getID()"
     #if ($rolesSelect == $role.getName())
     {
       selected
     }
     >$role.getName()</option> 
    }
   </select>
   </TD> 
  </TR>
  <TR>
   <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Roles on all Selected Projects"></TD>
  </TR>
}
  <TR>
   <TD COLSPAN="4"><HR SIZE="1" NOSHADE></TD>
  </TR>
</TABLE>

<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="2" BORDER="0" width="100%">
  <TR>
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginName() on the following projects:</TD>
  </TR>
  <TR>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Role</TD>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Project</TD>
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Description</TD>
  </TR>     

#set $projects=$currentDomain.getProjects($acl)
#if ($projects.isEmpty())
{
 <tr><td colspan="4">
  <span class="Warning">No matching projects found.</span>
 </td></tr>
} #else {
 #foreach $project in $projects
 {
  <TR> 
   <TD class="PlainText"> 
    <select name="RoleSelect $project.getID()"> 
     <option value="">None</option> 
     #foreach $role in $host.getProjectRoles() 
     { 
      <option value="$role.getID()" 
      #if ($rolesSelect==$role.getName()) 
      { 
       selected 
      } 
      >$role.getName()</option>  
     }
    </select> 
   </TD>  

   <TD class="PlainText" VALIGN="top">
    #if ($acl.hasPermission("Project - Edit", $project))
    {
     <A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A>
    } #else {
     $project.getName()
    }
   </TD>
   <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
  </TR> 
 }  
 <TR>
  <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Selected Roles"></TD>
 </TR>
}
</table>

</FORM>
@


1.7
log
@added style, regularized arguments to navigationBar, removed an unneeded link
@
text
@@


1.6
log
@added much needed admin nav element
@
text
@d26 1
a26 1
  <font color="red">No matching projects found.</font>
d99 1
a99 1
  <font color="red">No matching projects found.</font>
@


1.5
log
@This is the highest revision from the HELM_PEER_PORT_BRANCH.  The previous import caused too many conflicts to resolve manually
@
text
@d1 2
@


1.4
log
@links work with vhosting or non vhosting
@
text
@a0 9
## <!-- webmacro variables -->
## <!-- $currentUser.getLoginID(), $currentUser.getProjectList() -->
## <!-- $project: $project.getName(), $project.getShortDescription -->
## <!-- $project.getName()Check: checkbox form widget -->
## <!-- $rolesSelect: select form widget -->
## <!-- $currentDomain: $currentDomain.getRoles() -->
## <!-- $role: $role.getName() -->
## <!-- $grantRoles: submit button form widget -->

d2 1
a2 1
<INPUT TYPE="hidden" NAME="userID" VALUE="$currentUser.getUserID()">
d11 1
a11 1
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginID() on the following projects:</TD>
d20 2
a21 1
#foreach $project in $currentDomain.getProjects($acl)
d23 21
a43 10
  <TR> 
    <TD><INPUT TYPE="CHECKBOX" NAME="Grant $project.getID()" VALUE="CheckBox"></TD> 
    <TD class="PlainText" VALIGN="top"><A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A></TD> 
    <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
#set $roles = $currentUser.getRolesInProject($project.getID())
    <TD class="PlainText" VALIGN="top">
    #set $first=true
    #foreach $role in $roles
    {
     #if (!$first)
d45 2
d48 3
d52 11
a62 25
     $role.getName()
     #set $first=false
    }
    </TD>

  </TR> 
}

  <TR>
    <TD COLSPAN="3" class="PlainText" VALIGN="top"><A HREF="/servlets/UserRoleAdd.html">prev</A> | <B>1</B> <A HREF="/servlets/UserRoleAdd.html">2</A> <A HREF="/servlets/UserRoleAdd.html">3</A> <A HREF="/servlets/UserRoleAdd.html">4</A> | <A HREF="/servlets/UserRoleAdd.html">next</A></TD>
  </TR>
  <TR>
    <TD COLSPAN="3">&nbsp;</TD>
  </TR>
  <TR>
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant these roles on all selected projects:</TD>
  </TR>
  <TR>
    <TD COLSPAN="3" class="PlainText">
      <select name="roles" multiple>

#foreach $role in $currentDomain.getProjectRoles()
  {
        <option value="$role.getID()"
  #if ($rolesSelect == $role.getName())
d64 6
a69 1
      selected
d71 2
a72 4
                                       >$role.getName()</option> 
  }
      </select>
    </TD> 
d75 1
a75 1
    <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Roles on all Selected Projects"></TD>
d77 1
d79 1
a79 1
    <TD COLSPAN="3"><HR SIZE="1" NOSHADE></TD>
d85 1
a85 1
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginID() on the following projects:</TD>
d93 2
a94 1
#foreach $project in $currentDomain.getProjects($acl)
d96 6
d103 21
a123 11
    <TD class="PlainText"> 
      <select name="RoleSelect $project.getID()"> 
        <option value="">None</option> 
  #foreach $role in $currentDomain.getProjectRoles() 
    { 
        <option value="$role.getID()" 
        #if ($rolesSelect==$role.getName()) 
        { 
            selected 
        } 
        >$role.getName()</option>  
d125 2
a126 4
      </select> 
    </TD>  
    <TD class="PlainText" VALIGN="top"><A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A></TD> 
    <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
d128 5
a132 4
}  
  <TR>
    <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Selected Roles"></TD>
  </TR>
@


1.4.6.1
log
@Changed calls to getUserID to calls to getID
@
text
@d11 1
a11 1
<INPUT TYPE="hidden" NAME="userID" VALUE="$currentUser.getID()">
@


1.4.6.2
log
@Changed calls to getLoginID to calls to getLoginName
@
text
@d2 1
a2 1
## <!-- $currentUser.getLoginName(), $currentUser.getProjectList() -->
d20 1
a20 1
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginName() on the following projects:</TD>
d87 1
a87 1
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginName() on the following projects:</TD>
@


1.4.6.3
log
@Ported UserRoleAdd servlet.
@
text
@d1 9
d29 1
a29 2
#set $projects=$currentDomain.getProjects($acl)
#if ($projects.isEmpty())
d31 10
a40 21
 <tr><td colspan="3">
  <font color="red">No matching projects found.</font>
 </td></tr> 
} #else {
 #foreach $project in $currentDomain.getProjects($acl)
 {
   <TR> 
     <TD><INPUT TYPE="CHECKBOX" NAME="Grant $project.getID()" VALUE="CheckBox"></TD> 
     <TD class="PlainText" VALIGN="top">
      #if ($acl.hasPermission("Project - Edit", $project))
      {
       <A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A>
      } #else {
       $project.getName()
      }
     </TD> 
     <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
     #set $roles = $currentUser.getRolesInProject($project)
     <TD class="PlainText" VALIGN="top">
     #set $first=true
     #foreach $role in $roles
a41 2
      #if (!$first)
      {
a42 3
      }
      $role.getName()
      #set $first=false
d44 25
a68 11
     </TD>
    </TR> 
 }

 <TR>
  <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant these roles on all selected projects:</TD>
 </TR>
 <TR>
  <TD COLSPAN="3" class="PlainText">
   <select name="roles" multiple>
    #foreach $role in $host.getProjectRoles()
d70 1
a70 6
     <option value="$role.getID()"
     #if ($rolesSelect == $role.getName())
     {
       selected
     }
     >$role.getName()</option> 
d72 4
a75 2
   </select>
   </TD> 
d78 1
a78 1
   <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Roles on all Selected Projects"></TD>
a79 1
}
d81 1
a81 1
   <TD COLSPAN="4"><HR SIZE="1" NOSHADE></TD>
d95 1
a95 2
#set $projects=$currentDomain.getProjects($acl)
#if ($projects.isEmpty())
a96 6
 <tr><td colspan="4">
  <font color="red">No matching projects found.</font>
 </td></tr>
} #else {
 #foreach $project in $projects
 {
d98 11
a108 21
   <TD class="PlainText"> 
    <select name="RoleSelect $project.getID()"> 
     <option value="">None</option> 
     #foreach $role in $host.getProjectRoles() 
     { 
      <option value="$role.getID()" 
      #if ($rolesSelect==$role.getName()) 
      { 
       selected 
      } 
      >$role.getName()</option>  
     }
    </select> 
   </TD>  

   <TD class="PlainText" VALIGN="top">
    #if ($acl.hasPermission("Project - Edit", $project))
    {
     <A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A>
    } #else {
     $project.getName()
d110 4
a113 2
   </TD>
   <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
d115 4
a118 5
 }  
 <TR>
  <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Selected Roles"></TD>
 </TR>
}
@


1.3
log
@added domain name to page header
PR:
Obtained from:
Submitted by:
Reviewed by:
@
text
@d33 1
a33 1
    <TD class="PlainText" VALIGN="top"><A HREF="/servlets/ProjectEdit.html?projectID=$project.getID()">$project.getName()</A></TD> 
d112 1
a112 1
    <TD class="PlainText" VALIGN="top"><A HREF="/servlets/ProjectEdit?projectID=$project.getID()">$project.getName()</A></TD> 
a115 3
<!--  <TR>
    <TD COLSPAN="3" class="PlainText" VALIGN="top"><A HREF="/servlets/ProjectMemberAdd.html">prev</A> | <B>1</B> <A HREF="/servlets/ProjectMemberAdd.html">2</A> <A HREF="/servlets/ProjectMemberAdd.html">3</A> <A HREF="/servlets/ProjectMemberAdd.html">4</A> | <A HREF="/servlets/ProjectMemberAdd.html">next</A></TD>
  </TR>-->
@


1.2
log
@Cleaned up UserRoleAdd; added column to display in servlet.
@
text
@d14 1
a14 1
    <TD class="Header" nowrap>User Role Add</TD>  
@


1.1
log
@Initial revision
@
text
@d11 1
a11 1
<INPUT TYPE="hidden" NAME="currentUser" VALUE="$currentUser.getUserID()">
d26 1
d35 14
a49 1
  
d65 1
a65 1
#foreach $role in $currentDomain.getRoles()
d101 1
a101 1
  #foreach $role in $currentDomain.getRoles() 
@


1.1.1.1
log
@Merging newhelm tree into helm, as per IZ issue #557.  Previous major version of helm is tagged TIGRIS_NOV_11_2000.
@
text
@@


1.1.1.2
log
@Replacing the HEAD with the HELM_PEER_PORT_BRANCH.
@
text
@d1 9
d11 1
a11 1
<INPUT TYPE="hidden" NAME="userID" VALUE="$currentUser.getID()">
d14 1
a14 1
    <TD class="Header" nowrap>Add User Role: <SPAN CLASS="ProjectNameHeader">$currentDomain.getName()</SPAN></TD>  
d20 1
a20 1
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginName() on the following projects:</TD>
a25 1
    <TD class="ProjectDownloadHeader" bgcolor="#efefef">Current Roles</TD>
d28 1
a28 2
#set $projects=$currentDomain.getProjects($acl)
#if ($projects.isEmpty())
d30 25
a54 40
 <tr><td colspan="3">
  <font color="red">No matching projects found.</font>
 </td></tr> 
} #else {
 #foreach $project in $currentDomain.getProjects($acl)
 {
   <TR> 
     <TD><INPUT TYPE="CHECKBOX" NAME="Grant $project.getID()" VALUE="CheckBox"></TD> 
     <TD class="PlainText" VALIGN="top">
      #if ($acl.hasPermission("Project - Edit", $project))
      {
       <A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A>
      } #else {
       $project.getName()
      }
     </TD> 
     <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
     #set $roles = $currentUser.getRolesInProject($project)
     <TD class="PlainText" VALIGN="top">
     #set $first=true
     #foreach $role in $roles
     {
      #if (!$first)
      {
,
      }
      $role.getName()
      #set $first=false
     }
     </TD>
    </TR> 
 }

 <TR>
  <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant these roles on all selected projects:</TD>
 </TR>
 <TR>
  <TD COLSPAN="3" class="PlainText">
   <select name="roles" multiple>
    #foreach $role in $host.getProjectRoles()
d56 1
a56 6
     <option value="$role.getID()"
     #if ($rolesSelect == $role.getName())
     {
       selected
     }
     >$role.getName()</option> 
d58 4
a61 2
   </select>
   </TD> 
d64 1
a64 1
   <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Roles on all Selected Projects"></TD>
a65 1
}
d67 1
a67 1
   <TD COLSPAN="4"><HR SIZE="1" NOSHADE></TD>
d73 1
a73 1
    <TD class="InputHeader" VALIGN="top" NOWRAP COLSPAN="3">Grant permissions to user $currentUser.getLoginName() on the following projects:</TD>
d81 1
a81 2
#set $projects=$currentDomain.getProjects($acl)
#if ($projects.isEmpty())
a82 6
 <tr><td colspan="4">
  <font color="red">No matching projects found.</font>
 </td></tr>
} #else {
 #foreach $project in $projects
 {
d84 11
a94 21
   <TD class="PlainText"> 
    <select name="RoleSelect $project.getID()"> 
     <option value="">None</option> 
     #foreach $role in $host.getProjectRoles() 
     { 
      <option value="$role.getID()" 
      #if ($rolesSelect==$role.getName()) 
      { 
       selected 
      } 
      >$role.getName()</option>  
     }
    </select> 
   </TD>  

   <TD class="PlainText" VALIGN="top">
    #if ($acl.hasPermission("Project - Edit", $project))
    {
     <A HREF="$project.getProjectPageURL("ProjectEdit")">$project.getName()</A>
    } #else {
     $project.getName()
d96 4
a99 2
   </TD>
   <TD class="PlainText" VALIGN="top">$project.getShortDescription()</TD> 
d101 7
a107 5
 }  
 <TR>
  <TD COLSPAN="3" class="PlainText" VALIGN="top"><INPUT TYPE="submit" NAME="Button" VALUE="Grant Selected Roles"></TD>
 </TR>
}
@

