📄 querydataauthinfo.jsp
字号:
<%@ page contentType="text/html;charset=GB2312" %>
<%@ page import="cn.com.aheadsoft.recordset.DataAuthRoleRecordSet" %>
<%@ page import="cn.com.aheadsoft.recordset.DataAuthInfoRecordSet" %>
<%@ page import="cn.com.aheadsoft.recordset.UserGroupInfoRecordSet" %>
<%@ page import="cn.com.aheadsoft.recordset.DepartmentInfoRecordSet" %>
<%@ page import="cn.com.aheadsoft.recordset.BasicAuthUnitRecordSet" %>
<%@ page import="cn.com.aheadsoft.recordset.ModuleInfoRecordSet" %>
<%@ page import="cn.com.aheadsoft.util.AccessCtlChecker" %>
<%@ page import="java.util.*" %>
<%
AccessCtlChecker mychecker=new AccessCtlChecker();
List userdata=(List)session.getAttribute("userdata") ;
DataAuthInfoRecordSet datarecordset=(DataAuthInfoRecordSet)userdata.get(0);
DataAuthRoleRecordSet recordsetr=(DataAuthRoleRecordSet)userdata.get(1);
recordsetr.next();
String mroleuid=recordsetr.getDAR_UserGroupID();
String mroleid=recordsetr.getDAR_RoleID();
String mrolename=recordsetr.getDAR_RoleName();
String accessctl=recordsetr.getDAR_AccessControl();
mychecker.setaccessctlword(accessctl);
ModuleInfoRecordSet recordsetm=(ModuleInfoRecordSet)userdata.get(2);
BasicAuthUnitRecordSet recordsetb=(BasicAuthUnitRecordSet)userdata.get(3);
DataAuthRoleRecordSet recordset=(DataAuthRoleRecordSet)userdata.get(4);
//UserGroupInfoRecordSet recordsetu=(UserGroupInfoRecordSet)userdata.get(5);
DepartmentInfoRecordSet recordsetd=(DepartmentInfoRecordSet)userdata.get(5);
String mdid=(String)userdata.get(6);
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<link rel="stylesheet" type="text/css" href="/krm/jsp/css/css.css">
</head>
<form method="post" name="myform" action="/krm/servlet/dataauthinfoservlet">
<input type="hidden" name="status" value="i">
<input type="hidden" name="mroleid" value="<%=mroleid%>">
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" >
<table width="100%" align="center" border="0" cellpadding="0" cellspacing="0" >
<tr >
<td class="trA"> 您的位置:系统管理 >> 数据授权 >> <font class="fontcolor">角色数据授权信息</font></td>
</tr>
<tr height="8">
<td></td>
</tr>
<tr>
<td align="center" >
<table width="98%" border="0" cellpadding="0" cellspacing="0" bordercolor="A1B7DB" class="collapse">
<tr >
<td class="tdA" align="left" colspan="4">对角色 <%=mrolename%> 数据授权信息</td>
</tr>
<%
while(recordsetm.next()){
String modulename=recordsetm.getMI_ModuleName();
String moduleid=recordsetm.getMI_ModuleID();
%>
<tr >
<td height="26" colspan="4" align="center" style="border-bottom:#387798 2px solid;"><table width="75%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td> </td>
<td> </td>
</tr>
</table>
<font color="#000000" size="2"><strong><%=modulename%></strong></font></td>
</tr>
<% recordsetb.beforefirst();
while(recordsetb.next()){
String unitname=recordsetb.getBAU_UnitName();
String unitid=recordsetb.getBAU_UnitID();
String unitmoduleid=recordsetb.getBAU_ModuleID();
if (unitmoduleid.equalsIgnoreCase(moduleid)){
char qdegree=mychecker.getauthdegree(moduleid,unitid,"q");
char idegree=mychecker.getauthdegree(moduleid,unitid,"i");
char udegree=mychecker.getauthdegree(moduleid,unitid,"u");
char ddegree=mychecker.getauthdegree(moduleid,unitid,"d");
if(qdegree=='2' | qdegree=='3'|qdegree=='9' |udegree=='2' | udegree=='3'|udegree=='9' |ddegree=='2' | ddegree=='3'|ddegree=='9' )
{
%>
<tr >
<td class="common1" width="16%" bgcolor="f5f5f5" ><div align="center"><strong> <%=unitname%></strong></div></td>
<td width="84%" > <table width="99%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="A1B7DB" class="collapse">
<%recordsetd.beforefirst();
while(recordsetd.next()){
String dname=recordsetd.getDI_DepartmentName().trim();
String did=recordsetd.getDI_DepartmentID().trim();
%>
<%if (mdid.equalsIgnoreCase(did)) {%>
<%//////////////////////////////////////////////////////%>
<%
if(qdegree=='2'| udegree=='2' |ddegree=='2' |qdegree=='9'| udegree=='9' |ddegree=='9') {
%>
<tr >
<td class="tdC" colspan="4" bgcolor="f5f5f5"> <strong>部门:<%=dname%></strong></td>
</tr>
<%
recordset.beforefirst();
while(recordset.next()){
//String druid=recordset.getDAR_UserGroupID();
String drdeptid=recordset.getDAR_DeptID();
String drid=recordset.getDAR_RoleID();
String drname=recordset.getDAR_RoleName();
%>
<% if(drdeptid.equalsIgnoreCase(did)) {%>
<tr height="25" >
<td width="100%" height="24" colspan="4" align="left" class="common1" > 对角色:<%=drname%></td>
</tr>
<tr bgcolor="f5f5f5" height="20">
<%datarecordset.beforefirst();
while(datarecordset.next()){
String authunit=datarecordset.getDAI_BasicUnitID();
String authmrole= datarecordset.getDAI_MasterRoleID() ;
String authcrole=datarecordset.getDAI_ClientRoleID() ;
String optype=datarecordset.getDAI_OperationType();
if(mroleid.equalsIgnoreCase(authmrole)&drid.equalsIgnoreCase(authcrole)&authunit.equalsIgnoreCase(moduleid+"-"+unitid)&optype.equalsIgnoreCase("q")){
%>
<td height="24" align="left" class="common1"> 可浏览</td>
<%break;}}%>
<%datarecordset.beforefirst();
while(datarecordset.next()){
String authunit=datarecordset.getDAI_BasicUnitID();
String authmrole= datarecordset.getDAI_MasterRoleID() ;
String authcrole=datarecordset.getDAI_ClientRoleID() ;
String optype=datarecordset.getDAI_OperationType();
if(mroleid.equalsIgnoreCase(authmrole)&drid.equalsIgnoreCase(authcrole)&authunit.equalsIgnoreCase(moduleid+"-"+unitid)&optype.equalsIgnoreCase("u")){
%>
<td class="common1" align="left">可修改</td>
<%break;}}%>
<%datarecordset.beforefirst();
while(datarecordset.next()){
String authunit=datarecordset.getDAI_BasicUnitID();
String authmrole= datarecordset.getDAI_MasterRoleID() ;
String authcrole=datarecordset.getDAI_ClientRoleID() ;
String optype=datarecordset.getDAI_OperationType();
if(mroleid.equalsIgnoreCase(authmrole)&drid.equalsIgnoreCase(authcrole)&authunit.equalsIgnoreCase(moduleid+"-"+unitid)&optype.equalsIgnoreCase("d")){
%>
<td class="common1" align="left">可删除</td>
<%break;}}%>
</tr>
<%}%>
<%}%>
<tr height="25">
<td width="100" height="10" colspan="4" ></td>
</tr>
<%}%>
<%} else {%>
<%//////////////////////////////////////////////////////%>
<%
if(qdegree=='3'| udegree=='3' |ddegree=='3' |qdegree=='9'| udegree=='9' |ddegree=='9') {
%>
<tr height="18" >
<td height="24" colspan="4" align="left" bgcolor="f5f5f5" class="tdC" ><strong>部门:<%=dname%></strong></td>
</tr>
<%
recordset.beforefirst();
while(recordset.next()){
//String druid=recordset.getDAR_UserGroupID();
String drdeptid=recordset.getDAR_DeptID();
String drid=recordset.getDAR_RoleID();
String drname=recordset.getDAR_RoleName();
%>
<% if(drdeptid.equalsIgnoreCase(did)) {%>
<tr height="25" >
<td width="100%" height="24" colspan="4" align="left" class="common1"> 对角色:<%=drname%></td>
</tr>
<tr height="20">
<%datarecordset.beforefirst();
while(datarecordset.next()){
String authunit=datarecordset.getDAI_BasicUnitID();
String authmrole= datarecordset.getDAI_MasterRoleID() ;
String authcrole=datarecordset.getDAI_ClientRoleID() ;
String optype=datarecordset.getDAI_OperationType();
if(mroleid.equalsIgnoreCase(authmrole)&drid.equalsIgnoreCase(authcrole)&authunit.equalsIgnoreCase(moduleid+"-"+unitid)&optype.equalsIgnoreCase("q")){
%>
<td height="24" align="left" bgcolor="f5f5f5" class="common1" > 可浏览</td>
<%break;}}%>
<%datarecordset.beforefirst();
while(datarecordset.next()){
String authunit=datarecordset.getDAI_BasicUnitID();
String authmrole= datarecordset.getDAI_MasterRoleID() ;
String authcrole=datarecordset.getDAI_ClientRoleID() ;
String optype=datarecordset.getDAI_OperationType();
if(mroleid.equalsIgnoreCase(authmrole)&drid.equalsIgnoreCase(authcrole)&authunit.equalsIgnoreCase(moduleid+"-"+unitid)&optype.equalsIgnoreCase("u")){
%>
<td align="left" bgcolor="f5f5f5" class="common1" >可修改</td>
<%break;}}%>
<%datarecordset.beforefirst();
while(datarecordset.next()){
String authunit=datarecordset.getDAI_BasicUnitID();
String authmrole= datarecordset.getDAI_MasterRoleID() ;
String authcrole=datarecordset.getDAI_ClientRoleID() ;
String optype=datarecordset.getDAI_OperationType();
if(mroleid.equalsIgnoreCase(authmrole)&drid.equalsIgnoreCase(authcrole)&authunit.equalsIgnoreCase(moduleid+"-"+unitid)&optype.equalsIgnoreCase("d")){
%>
<td align="left" bgcolor="f5f5f5" class="common1" >可删除</td>
<%break;}}%>
</tr>
<%}%>
<%}%>
<tr height="25">
<td width="100" height="10" colspan="4" ></td>
</tr>
<%}%>
<%}%>
<%}%>
<!--<tr height="25"><td bgcolor="#FF0000" colspan="4"></td></tr>-->
</table></td>
</tr>
<tr bgcolor="#FFFFFF" height="25">
<td colspan="4" class="tdB"> </td>
</tr>
<%
}
}
}%>
<%}%>
<tr>
<td colspan="6" > </td>
</tr>
</table>
<br>
</td>
</tr>
</table>
</form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -