userlist.jsp
<%@ include file="../../public/include/page.jsp"%>
<%@ page pageEncoding="GBK"%>
<html:html>
<head>
</head>
<script language="JavaScript">
function movetogroup(){
with(document.forms[0]){
var codeStr = all['username'];
if(codeStr == null){
alert('未选择任何的记录!');
return false;
}else if(codeStr.length == null){
if(username.checked == false){
alert('请选择要添加的记录!');
return false;
}
}else if(codeStr.length !== null){
var flagStr = true;
for(i=0;i<codeStr.length;i++){
if(username[i].checked == true){
flagStr = false;
break;
}
}
if(flagStr){
alert('请选择要添加的记录');
return false;
}
}
action = "<%=root%>/manage/policeUserAction.do?method=moveToGroup";
submit();
}
}
function toDel(){
with(document.forms[0]){
var codeStr = all['username'];
if(codeStr == null){
alert('未选择任何的记录!');
return false;
}else if(codeStr.length == null){
if(username.checked == false){
alert('请选择要删除的记录!');
return false;
}
}else if(codeStr.length !== null){
var flagStr = true;
for(i=0;i<codeStr.length;i++){
if(username[i].checked == true){
flagStr = false;
break;
}
}
if(flagStr){
alert('请选择要删除的记录');
return false;
}
}
question = confirm('是否真的删除所选的记录');
if (question != "0"){
var str = "<%=root%>/manage/policeUserAction.do?method=deletePoliceUser";
action=str;
submit();
}
}
return true;
}
function checkboxes(flag){
with(document.forms[0]){
var codeStr = all['username'];
if(flag == "allTrue"){
//全选
if( codeStr != null && codeStr.length != null ){
for(i=0;i<codeStr.length;i++){
username[i].checked=true;
}
}else if( codeStr != null && codeStr.length == null ){
username.checked=true;;
}
}else if(flag == "allFalse"){
//全不选
if( codeStr != null && codeStr.length != null ){
for(i=0;i<codeStr.length;i++){
username[i].checked=false;
}
}else if( codeStr != null && codeStr.length == null ){
username.checked=false;
}
}else{
//反选
if( codeStr != null && codeStr.length != null ){
for(i=0;i<codeStr.length;i++){
if(username[i].checked == true){
username[i].checked=false;
}else{
username[i].checked=true;
}
}
}else if( codeStr != null && codeStr.length == null ){
if(username.checked == true){
username.checked=false;
}else{
username.checked=true;
}
}
}
}
return true;
}
function toModify(username1){
with(document.forms[0]){
action = "<%=root%>/manage/policeUserAction.do?method=toModifyPoliceUser&username="+username1;
submit();
}
}
function clean(){
with(document.forms[0]){
turename.value = "";
policeid.value = "3205";
isuse.value = "";
isonline.value = "";
turename.focus();
}
}
function showAdd(){
url = "<%=root%>/manage/policeUserAction.do?method=toAddPoliceUser";
var fram = document.getElementById("newFrame");
fram.src = url;
}
//点击修改按钮时,弹出修改页面
function showEdit()
{
// 获取所选信息的编号
var username = getChecked(document.all.item("username"));
// 如果没有选择记录
if(username == null)
{
alert("请选择一条记录!");
return false;
}
var url = "<%=root%>/manage/policeUserAction.do?method=toModifyPoliceUser&username="+username.value;
var fram = document.getElementById("newFrame");
fram.src = url;
return true;
}
function detailtoAdd()
{
document.forms[0].action = "<%= request.getContextPath()%>/manage/policeUserAction.do?method=queryPoliceUser";
document.forms[0].submit();
}
</script>
<body ondragstart="return false">
<html:form action="/manage/policeUserAction.do?method=queryPoliceUser" method="post">
<table width="100%" border="0" cellspacing="0" cellpadding="0"
class="table_border02" onClick="showHiddenColumn(1);">
<tr style="CURSOR: hand">
<td>
<img src="<%=request.getContextPath()%>/images/pic/title_left.gif"
width="3" height="25">
</td>
<td width="100%" class="column_title">
<nobr>
公安局用户列表
</nobr>
</td>
<td class="column_title" style="padding-right:6px;">
<img
src="<%=request.getContextPath()%>/images/pic/icon_column_opened.gif"
width="17" height="17" border="0" id="columnIcon1">
</td>
<td class="column_title" style="padding-right:6px;">
</td>
<td>
<img src="<%=request.getContextPath()%>/images/pic/title_right.gif"
width="3" height="25">
</td>
</tr>
</table>
<div id="columnDiv1" style="display:block;padding-bottom:6px;">
<table class="table-form">
<tr>
<th>
用户姓名
</th>
<td>
<html:text name="policeUserActionForm" property="policeUserQO.turename" styleId="turename" styleClass="box"/>
</td>
<th>
所属部门
</th>
<td>
<hpmis:orgtree name ="policeUserActionForm" property="policeUserQO.policeid" orgInfoName="orgInfo" styleId="policeid"/>
<%--<param:select type="policeDepa" name="policeUserActionForm" property="policeUserQO.policeid" nullStr="--请选择--" styleId="policeid" />--%>
</td>
</tr>
<tr>
<th>
帐户是否可用
</th>
<td>
<param:select type="isuse" name="policeUserActionForm" nullStr="全部" property="policeUserQO.isuse" styleId="isuse" />
</td>
<th>
是否在线
</th>
<td>
<param:select type="hasPay" name="policeUserActionForm" nullStr="全部" property="policeUserQO.isonline" styleId="isonline" />
</td>
</tr>
</table>
<table width="100%" height="4px" border="0" cellpadding="0" cellspacing="0">
<tr>
<td></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="cursor:pointer;">
<tr>
<td align="center">
<input id="add" name="add" type="submit" class="button_fix" value="查 询" onMouseOver="this.className='button_fix_over'" onMouseOut="this.className='button_fix'" onMouseDown="this.className='button_fix_down'"
onMouseUp="this.className='button_fix_over'" onFocus="this.blur();"/>
<input id="edit" name="edit" type="button" class="button_fix" value="重 置" onMouseOver="this.className='button_fix_over'" onMouseOut="this.className='button_fix'" onMouseDown="this.className='button_fix_down'"
onMouseUp="this.className='button_fix_over'" onFocus="this.blur();" onClick="clean()" />
</td>
</tr>
</table>
<display:table htmlId="singleCheckHtmlId" name="pageInfo" defaultorder="descending" export="false" id="node" pagesize="10" requestURI="" class="grid">
<display:column title="选择框" sortable="false">
<INPUT type="radio" name="username" id="username" value="<bean:write name="node" property="username"/>" onclick="showEdit()">
</display:column>
<display:column property="username" title="用户帐号"/>
<display:column property="turename" title="用户姓名"/>
<display:column title="所属部门">
<param:display type="police" name="node" property="policeid"/>
</display:column>
<display:column title="是否绑定IP">
<param:display type="isip" name="node" property="isip"/>
</display:column>
<display:column property="ip" title="IP地址"/>
<display:column title="帐号是否可用">
<param:display type="isuse" name="node" property="isuse"/>
</display:column>
<display:column title="是否在线">
<param:display type="hasPay" name="node" property="isonline"/>
</display:column>
</display:table>
<table width="100%" height="4px" border="0" cellpadding="0" cellspacing="0">
<tr>
<td></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="cursor:pointer;">
<tr>
<td align="center">
<input id="add" name="add" type="button" class="button_fix" value="增 加" onMouseOver="this.className='button_fix_over'" onMouseOut="this.className='button_fix'" onMouseDown="this.className='button_fix_down'"
onMouseUp="this.className='button_fix_over'" onFocus="this.blur();" onClick="showAdd();" />
<input id="edit" name="edit" type="button" class="button_fix" value="修 改" onMouseOver="this.className='button_fix_over'" onMouseOut="this.className='button_fix'" onMouseDown="this.className='button_fix_down'"
onMouseUp="this.className='button_fix_over'" onFocus="this.blur();" onClick="showEdit();" />
</td>
</tr>
</table>
</div>
</html:form>
<table width="100%" height="4px" border="0" cellpadding="0" cellspacing="0">
<tr>
<td></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0"
onClick="showHiddenColumn(2);">
<tr style="CURSOR: hand">
<td>
<img src="<%=request.getContextPath()%>/images/pic/title_left.gif"
width="3" height="25">
</td>
<td width="100%" class="column_title">
<nobr>
增加/修改公安局用户
</nobr>
</td>
<td class="column_title" style="padding-right:6px;">
<img src="<%=request.getContextPath()%>/images/pic/icon_column_opened.gif"
width="17" height="17" border="0" id="columnIcon2">
</td>
<td class="column_title" style="padding-right:6px;">
</td>
<td>
<img src="<%=request.getContextPath()%>/images/pic/title_right.gif"
width="3" height="25">
</td>
</tr>
</table>
<div id="columnDiv2" style="display:block;padding-bottom:6px;">
<iframe id="newFrame" src="" style="filter: Chroma(Color=white)"
width=100% height="350" frameborder="0" scrolling="auto" />
</iframe>
</div>
</body>
</html:html>