%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%> <%@ page import="java.lang.Integer"%> <%@ page import="edu.cornell.mannlib.vitro.webapp.flags.PortalFlagChoices" %> <%@ page import="edu.cornell.mannlib.vitro.webapp.flags.AuthFlag" %> <%@ page import="edu.cornell.mannlib.vitro.webapp.flags.PortalFlag" %> <%@ page import="edu.cornell.mannlib.vitro.webapp.beans.ApplicationBean" %> <%@ page import="edu.cornell.mannlib.vitro.webapp.beans.Portal" %> <%@ page errorPage="/error.jsp"%> <% /*********************************************** Display A Form for filling out Portal Flags request.attributes: PortalFlag object via attribute "portalState". request.parameters: None yet. Consider sticking < % = MiscWebUtils.getReqInfo(request) % > in the html output for debugging info. This was written by jc55 and split into this file from browseGroups.jsp by bdc34. **********************************************/ PortalFlag portalFilterState = (PortalFlag) request.getAttribute("portalFlag"); if (portalFilterState == null) { String e = "portalFlagChoices.jsp expects that request attribute 'portalFlag' be set to a portal state [PortalFlag] object."; throw new JspException(e); } AuthFlag authFlag = (AuthFlag) request.getAttribute("authFlag"); if (authFlag == null) { String e = "portalFlagChoices.jsp expects that request attribute 'authFlag' be set to a authorization state [AuthFlag] object."; throw new JspException(e); } ApplicationBean appBean = (ApplicationBean) request.getAttribute("appBean"); if (appBean == null) { String e = "portalFlagChoices.jsp expects request attribute 'appBean' be set to an application bean object"; throw new JspException(e); } Portal portal = (Portal) request.getAttribute("portalBean"); if( portal == null ) portal = new Portal(); int portalId = portal.getPortalId(); %> <% String width1Str=request.getParameter("width1"); int width1=14; if (width1Str!=null && !width1Str.equals("")) { try { width1=Integer.parseInt(width1Str); } catch (NumberFormatException ex) { throw new JspException("Error: width1 parameter cannot be decoded as integer in portalFlagChoices.jsp"); } } %>
/> limit to /> omit | <%=PortalFlagChoices.getFlag1Choices(portalFilterState,appBean,portalId)%> |
/> limit to /> omit | <%=PortalFlagChoices.getFlag2Choices(portalFilterState, appBean)%> |
/> limit to /> omit | <%=PortalFlagChoices.getFlag3Choices(portalFilterState,appBean,portal)%> |
filter as indicated above <% if (authFlag.getUserSecurityLevel()>=appBean.FILTER_SECURITY_LEVEL) {%> don't filter at all<% }%> |