⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 usereditor.jsp

📁 老外的在线考试
💻 JSP
字号:
<%-- * CyberTester - J2EE Web application for creating, delivering and managing tests/exams/surveys.  * Copyright (C) 2004 CyberDemia Research and Services Pty Ltd * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * See the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program (see the file COPYING); if not, write to the * Free Software Foundation, Inc., * 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA * * See the COPYING file located in the top-level-directory of * the archive of this program for complete text of license.--%><%@ page language="java"  buffer="16kb" %><%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %><%@ taglib uri="/WEB-INF/c.tld" prefix="c" %><%@ taglib uri="/WEB-INF/fmt.tld" prefix="fmt" %><%@ taglib uri="/WEB-INF/cd_core.tld" prefix="cyberdemia" %><html:html xhtml="true">	<head>		<title><fmt:message key="title.admin.usereditor" /></title>		<meta http-equiv="pragmas" content="no-cache" />		<meta http-equiv="cache-control" content="no-cache" />		<meta http-equiv="expires" content="0" />		<link rel="stylesheet" href="<%= request.getContextPath() %>/cybertester.css" type="text/css" />		<link rel="stylesheet" href="<%= request.getContextPath() %>/admin/admin.css" type="text/css" />		<script type="text/javascript" src="<%= request.getContextPath() %>/utils.js" ></script>		<script type="text/javascript" >		<!--			var cancelling = false;			function cancelClicked()			{				cancelling = true;			}			function validateForm(form )			{				if (cancelling)				{					return true;				}				<c:if test="${adminUserForm.new}" >					if (form.elements["email"].value.trim().length ==0)					{						alert("<cyberdemia:jsString><fmt:message key="jstext.admin.usereditor.userForm.error.missingEmail" /></cyberdemia:jsString>");						form.elements["email"].focus();						return false;					}				</c:if>								if (form.elements["firstName"].value.trim().length ==0)				{					alert("<cyberdemia:jsString><fmt:message key="jstext.admin.usereditor.userForm.error.missingFirstName" /></cyberdemia:jsString>");					form.elements["firstName"].focus();					return false;				}								if (form.elements["lastName"].value.trim().length ==0)				{					alert("<cyberdemia:jsString><fmt:message key="jstext.admin.usereditor.userForm.error.missingLastName" /></cyberdemia:jsString>");					form.elements["lastName"].focus();					return false;				}								<c:if test="${adminUserForm.new}" >					if (form.elements["password"].value.trim().length ==0)					{						alert("<cyberdemia:jsString><fmt:message key="jstext.admin.usereditor.userForm.error.missingPassword" /></cyberdemia:jsString>");						form.elements["password"].focus();						return false;					}				</c:if>								var password1 = form.elements["password"].value.trim();				if (password1.length > 0)				{					if (password1 != form.elements["password2"].value.trim())					{						alert("<cyberdemia:jsString><fmt:message key="jstext.admin.usereditor.userForm.error.mismatchPassword" /></cyberdemia:jsString>");						form.elements["password2"].focus();						return false;					}				}												return true;			}		// -->		</script>		<html:base/>	</head>	<body>		<%@ include file="/include/header.jsp" %>		<h1><html:img page="/images/adminusers_big.gif" alt="Users admin" /> <fmt:message key="h1.admin.usereditor" /></h1>		<html:errors/>		<html:form action="/admin/saveUser" method="post" styleId="userForm"  onsubmit="return validateForm(this);" >			<input type="hidden" name="searchTarget" value="<c:out value="${searchTarget}" />" />			<html:hidden property="id" />			<html:hidden property="mode" />			<table width="95%" class="editor" >				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.email" /></th>					<td align="left" nowrap="nowrap" >						<c:choose>							<c:when test="${adminUserForm.new}" >								<html:text property="email" size="40" maxlength="40" /> *							</c:when>							<c:otherwise>								<html:text property="email" readonly="true" size="40" maxlength="40" />							</c:otherwise>						</c:choose>					</td>				</tr>				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.title" /></th>					<td align="left">						<html:select property="title">							<html:option value="none" ><fmt:message key="label.admin.usereditor.userForm.titleOption.none" /></html:option>							<html:option value="mr" ><fmt:message key="label.admin.usereditor.userForm.titleOption.mr" /></html:option>							<html:option value="mrs" ><fmt:message key="label.admin.usereditor.userForm.titleOption.mrs" /></html:option>							<html:option value="miss" ><fmt:message key="label.admin.usereditor.userForm.titleOption.miss" /></html:option>							<html:option value="ms" ><fmt:message key="label.admin.usereditor.userForm.titleOption.ms" /></html:option>							<html:option value="doc" ><fmt:message key="label.admin.usereditor.userForm.titleOption.doc" /></html:option>						</html:select>					</td>				</tr>				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.firstName" /></th>					<td align="left" nowrap="nowrap" >						<html:text property="firstName" size="40" maxlength="40" /> *					</td>				</tr>				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.lastName" /></th>					<td align="left" nowrap="nowrap" >						<html:text property="lastName" size="40" maxlength="40" /> *					</td>				</tr>				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.roleGroup" /></th>					<td align="left">						<html:select property="roleGroup">							<html:option value="testee" ><fmt:message key="label.admin.usereditor.userForm.roleGroupOption.testee" /></html:option>							<html:option value="manager" ><fmt:message key="label.admin.usereditor.userForm.roleGroupOption.manager" /></html:option>						</html:select>					</td>				</tr>				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.password" /></th>					<td align="left" nowrap="nowrap" >						<html:password property="password" size="20" maxlength="20" />						<c:if test="${adminUserForm.new}" >*</c:if>					</td>				</tr>				<tr>					<th align="right"><fmt:message key="label.admin.usereditor.userForm.confirmPassword" /></th>					<td align="left" nowrap="nowrap" >						<html:password property="password2" size="20" maxlength="20" />						<c:if test="${adminUserForm.new}" >*</c:if>					</td>				</tr>				<c:if test="${adminUserForm.groups != null}" >					<tr>						<th align="right"><fmt:message key="label.admin.usereditor.userForm.groups" /></th>						<td align="left" nowrap="nowrap" >							<ul>								<c:forEach var="group" items="${adminUserForm.groups}" >									<li><c:out value="${group.name}" /></li>								</c:forEach>							</ul>						</td>					</tr>				</c:if>			</table>			<p class="footnotes">* required</p>						<c:if test="${adminUserForm.availableGroups != null}" >				<table width="95%" class="editor" >					<tr>						<th nowrap="nowrap" width="1%"><fmt:message key="label.admin.usereditor.userForm.availableGroupList.add" /></th>						<th nowrap="nowrap" width="99%"><fmt:message key="label.admin.usereditor.userForm.availableGroupList.available" /></th>					</tr>					<c:forEach var="availGroup" items="${adminUserForm.availableGroups}" >						<tr>							<td><input type="checkbox" name="<c:out value="${assignGroupParamPrefix}" /><c:out value="${availGroup.id}" />" value="true" /></td>							<td><c:out value="${availGroup.name}" /></td>						</tr>						</c:forEach>				</table>			</c:if>						<c:if test="${not adminUserForm.new}" >				<table width="95%" class="editor" style="margin-top:10px;">					<c:if test="${userTestList != null}" >						<tr>							<th nowrap="nowrap" width="1%"><fmt:message key="label.admin.usereditor.userForm.testList.remove" /></th>							<th nowrap="nowrap" width="98%"><fmt:message key="label.admin.usereditor.userForm.testList.assigned" /></th>							<th nowrap="nowrap" width="1%"><fmt:message key="label.admin.usereditor.userForm.testList.questions" /></th>						</tr>						<c:forEach var="assignedTest" items="${userTestList}" >							<tr>								<td><input type="checkbox" name="<c:out value="${disassocParamPrefix}" /><c:out value="${assignedTest.id}" />" value="true" /></td>								<td><c:out value="${assignedTest.name}" /></td>								<td><c:out value="${assignedTest.relatedResourcesCount}" /></td>							</tr>						</c:forEach>					</c:if>					<c:if test="${notUserTestList != null}" >						<tr>							<th nowrap="nowrap" width="1%"><fmt:message key="label.admin.usereditor.userForm.testList.add" /></th>							<th nowrap="nowrap" width="98%"><fmt:message key="label.admin.usereditor.userForm.testList.available" /></th>							<th width="1%"><fmt:message key="label.admin.usereditor.userForm.testList.questions" /></th>						</tr>						<c:forEach var="availableTest" items="${notUserTestList}" >							<tr>								<td><input type="checkbox" name="<c:out value="${assocParamPrefix}" /><c:out value="${availableTest.id}" />" value="true" /></td>								<td><c:out value="${availableTest.name}" /></td>								<td><c:out value="${availableTest.relatedResourcesCount}" /></td>							</tr>						</c:forEach>					</c:if>				</table>			</c:if>			<div>				<html:submit><fmt:message key="label.button.submit" /></html:submit>				<html:cancel onclick="cancelClicked()" ><fmt:message key="label.button.cancel" /></html:cancel>			</div>		</html:form>		<%@ include file="/include/footer.jsp" %>	</body></html:html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -