📄 editbasicaccessrules.jspf
字号:
<% /* editbasicacccessrules.jsp * * page for editing a admingroups access rules, included from Administratorprivileges.jsp * * Created on 14 mars 2002, 20:49 * * author Philip Vendil */ %><% int row = 0; %><SCRIPT language="JavaScript"><!-- function roleupdated(){ var currentrole = document.basicrules.<%=SELECT_ROLE%>.options[document.basicrules.<%=SELECT_ROLE%>.options.selectedIndex].value; if(currentrole == <%=BasicAccessRuleSet.ROLE_NONE %>){ document.basicrules.<%=SELECT_CAS %>.disabled = true; document.basicrules.<%=SELECT_ENDENTITYRULES%>.disabled = true; document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.disabled = true; document.basicrules.<%=SELECT_OTHER %>.disabled = true; numofcas = document.basicrules.<%=SELECT_CAS %>.length; for( i=numofcas-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_CAS%>.options[i].selected=false; } numofendentity = document.basicrules.<%=SELECT_ENDENTITYRULES %>.length; for( i=numofendentity-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=false; } numofprofiles = document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.length; for( i=numofprofiles-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_ENDENTITYPROFILES%>.options[i].selected=false; } numofother = document.basicrules.<%=SELECT_OTHER %>.length; for( i=numofother-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_OTHER %>.options[i]=null; } } if(currentrole == <%=BasicAccessRuleSet.ROLE_SUPERADMINISTRATOR %>){ document.basicrules.<%=SELECT_CAS %>.disabled = true; document.basicrules.<%=SELECT_ENDENTITYRULES%>.disabled = true; document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.disabled = true; document.basicrules.<%=SELECT_OTHER %>.disabled = true; numofcas = document.basicrules.<%=SELECT_CAS %>.length; for( i=numofcas-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_CAS%>.options[i].selected=false; } numofendentity = document.basicrules.<%=SELECT_ENDENTITYRULES %>.length; for( i=numofendentity-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=false; } numofprofiles = document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.length; for( i=numofprofiles-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_ENDENTITYPROFILES%>.options[i].selected=false; } numofother = document.basicrules.<%=SELECT_OTHER %>.length; for( i=numofother-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_OTHER %>.options[i]=null; } } if(currentrole == <%= BasicAccessRuleSet.ROLE_CAADMINISTRATOR%>){ document.basicrules.<%=SELECT_CAS %>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYRULES%>.disabled = true; document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.disabled = true; document.basicrules.<%=SELECT_OTHER %>.disabled = false; numofendentity = document.basicrules.<%=SELECT_ENDENTITYRULES %>.length; for( i=numofendentity-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=false; } numofprofiles = document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.length; for( i=numofprofiles-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_ENDENTITYPROFILES%>.options[i].selected=false; } numofother = document.basicrules.<%=SELECT_OTHER %>.length; for( i=numofother-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_OTHER %>.options[i]=null; } <% if(globalconfiguration.getIssueHardwareTokens()){ %> document.basicrules.<%=SELECT_OTHER %>.options[0]=new Option("<%= ejbcawebbean.getText(BasicAccessRuleSet.OTHERTEXTS[BasicAccessRuleSet.OTHER_ISSUEHARDTOKENS]) %>",<%= BasicAccessRuleSet.OTHER_ISSUEHARDTOKENS %>); <% } %> } if(currentrole == <%= BasicAccessRuleSet.ROLE_RAADMINISTRATOR%>){ document.basicrules.<%=SELECT_CAS %>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYRULES%>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.disabled = false; document.basicrules.<%=SELECT_OTHER %>.disabled = false; numofendentity = document.basicrules.<%=SELECT_ENDENTITYRULES %>.length; for( i=numofendentity-1; i >= 0; i-- ){ if(document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_VIEW %> || document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_VIEWHISTORY %> || document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_CREATE %> || document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_EDIT %> || document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_DELETE %> || document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_REVOKE %>) document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=true; else document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=false; } numofother = document.basicrules.<%=SELECT_OTHER %>.length; for( i=numofother-1; i >= 0; i-- ){ document.basicrules.<%=SELECT_OTHER %>.options[i]=null; } document.basicrules.<%=SELECT_OTHER %>.options[0]=new Option("<%= ejbcawebbean.getText(BasicAccessRuleSet.OTHERTEXTS[BasicAccessRuleSet.OTHER_VIEWLOG]) %>",<%= BasicAccessRuleSet.OTHER_VIEWLOG %>); <% if(globalconfiguration.getIssueHardwareTokens()){ %> document.basicrules.<%=SELECT_OTHER %>.options[1]=new Option("<%= ejbcawebbean.getText(BasicAccessRuleSet.OTHERTEXTS[BasicAccessRuleSet.OTHER_ISSUEHARDTOKENS]) %>",<%= BasicAccessRuleSet.OTHER_ISSUEHARDTOKENS %>); <% } %> } if(currentrole == <%= BasicAccessRuleSet.ROLE_SUPERVISOR%>){ document.basicrules.<%=SELECT_CAS %>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYRULES%>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.disabled = false; document.basicrules.<%=SELECT_OTHER %>.disabled = true; numofendentity = document.basicrules.<%=SELECT_ENDENTITYRULES %>.length; for( i=numofendentity-1; i >= 0; i-- ){ if(document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_VIEW %> || document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value == <%=BasicAccessRuleSet.ENDENTITY_VIEWHISTORY %>) document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=true; else document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected=false; } }}function checkallfields(){ var illegalfields = 0; var illegalselection = false; document.basicrules.<%=SELECT_CAS %>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYRULES%>.disabled = false; document.basicrules.<%=SELECT_ENDENTITYPROFILES %>.disabled = false; document.basicrules.<%=SELECT_OTHER %>.disabled = false; var currentrole = document.basicrules.<%=SELECT_ROLE%>.options[document.basicrules.<%=SELECT_ROLE%>.options.selectedIndex].value; if(currentrole == <%= BasicAccessRuleSet.ROLE_NONE%>){ alert("<%= ejbcawebbean.getText("SELECTAROLE") %>"); illegalfields++; } if(currentrole == <%= BasicAccessRuleSet.ROLE_SUPERVISOR%>){ var numofendentity = document.basicrules.<%=SELECT_ENDENTITYRULES %>.length; for( i=numofendentity-1; i >= 0; i-- ){ if(document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].selected){ if(!(document.basicrules.<%=SELECT_ENDENTITYRULES%>.options[i].value==<%= BasicAccessRuleSet.ENDENTITY_VIEW%> ||
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -