📄 prepareuser.jsp
字号:
<%@ page contentType="text/html; charset=GBK" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic" prefix="logic"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="Cache-Control" content="no-cache, must-revalidate" />
<meta http-equiv="expires" content="Wed, 26 Feb 1970 08:21:57 GMT" />
<link href="${pageContext.request.contextPath}/image/main.css" rel="stylesheet" type="text/css">
<title>集团客户列表</title>
<script language="javascript">
function selectchick(obj){
var array = document.getElementsByName("all");
for (i = 0;i<array.length;i++){
if (array[i].all[0].type=="checkbox"){
array[i].all[0].checked = obj.checked;
}
}
}
function selectparent(obj){
var array = document.getElementsByName("all");
var fag = 1;
var j = 0;
for (i = 0;i<array.length;i++){
if (array[i].all[0].type=="checkbox"){
if(array[i].all[0].checked==false)
{
fag=2;
}else
{
j=j+1;
}
}
}
var parentid = document.getElementById("parent");
if(fag==1)
{
parentid.checked=true;
}else if(j==0)
{
parentid.checked=false;
}
}
function checkservicemanager(){
var grpbox = document.getElementById("grpbox");
if(form1.servicemanager.value.length==""){
alert("请选择要分配的客户经理!");
}
else if(grpbox.checked==false){
alert("请选择集团客户!");
}
else {
form1.submit();
}
}
</script>
<style type="text/css">
<!--
.STYLE1 {
font-size: 14px;
font-weight: bold;
font-family: "宋体";
}
.STYLE2 {
color: #FFFFFF;
font-weight: bold;
}
-->
</style>
</head>
<body>
<html:form action="/allotCompany?tag=allotSave" method="post" styleId="form1">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td align="center" valign="middle"><table width="80%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td height="20" colspan="3" align="center" valign="middle"><span class="STYLE1">集 团 客 户 列 表 </span></td>
</tr>
<tr>
<td height="20" colspan="3" align="center" valign="middle"> </td>
</tr>
<tr>
<td width="63" height="36" align="right" valign="bottom">客户经理:</td>
<td align="left" valign="bottom">
<select name="servicemanager" id="servicemanager">
<option value="">----请选择-----</option>
<c:forEach var="userValue" items="${requestScope.userlist}">
<option value="${userValue.loginname}">
${userValue.loginname}
</option>
</c:forEach>
</select>
<input type="button" name="Submit" value="重新分配" onClick="checkservicemanager();" >
<input type="button" name="back" value="返 回" onClick="window.history.back();">
</td>
<td width="164" align="left" valign="bottom"> </td>
</tr>
</table>
<table width="80%" border="1" cellpadding="0" cellspacing="0" bordercolor="#D71920">
<tr>
<td align="center" valign="middle"><table width="100%" border="1" cellspacing="0" cellpadding="0" >
<tr>
<td width="4%" height="28" align="center" background="${pageContext.request.contextPath}/image/newTop_02.jpg">
<input name="checkbox" type="checkbox" id="parent" onClick="selectchick(this);">
</td>
<td width="23%" align="center" nowrap background="${pageContext.request.contextPath}/image/newTop_02.jpg"><span class="STYLE2">集团编号</span></td>
<td width="23%" align="center" nowrap background="${pageContext.request.contextPath}/image/newTop_02.jpg">
<span class="STYLE2">集团名称</span></td>
<td width="23%" align="center" nowrap background="${pageContext.request.contextPath}/image/newTop_02.jpg">
<span class="STYLE2">状态</span> </td>
<td width="27%" align="center" nowrap background="${pageContext.request.contextPath}/image/newTop_02.jpg">
<span class="STYLE2">客户经理ID</span> </td>
</tr>
<logic:iterate id="list" name="grouplist" scope="request">
<tr>
<td height="20" align="center" valign="middle" nowrap id="all" class="ttc">
<input name="grpbox" type="checkbox" id="grpbox" value="${list.nid}" onClick="selectparent(this);">
</td>
<td height="20" align="center" valign="middle" nowrap id="ttc"> ${list.companyid}</td>
<td align="center" valign="middle" nowrap id="ttc"> ${list.companyname}</td>
<td align="center" valign="middle" nowrap id="ttc"> ${list.companystate}</td>
<c:choose>
<c:when test="${list.servicemanager=='0'}">
<td align="center" valign="middle" nowrap id="ttc"> 未分配</td>
</c:when>
<c:otherwise>
<td align="center" valign="middle" nowrap id="ttc"> ${list.servicemanager}</td>
</c:otherwise>
</c:choose>
</tr>
</logic:iterate>
</table></td>
</tr>
</table>
<p>${requestScope.pageTool}</p></td>
</tr>
</table>
</html:form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -