Subversion Repositories bacoAlunos

Rev

Rev 250 | Blame | Compare with Previous | Last modification | View Log | RSS feed

<%@ page import="pt.estgp.estgweb.Globals" %>
<%@ page import="pt.estgp.estgweb.domain.UserSession" %>
<%@ page import="pt.estgp.estgweb.web.UserSessionProxy" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="/WEB-INF/tlds/struts-tiles.tld" prefix="tiles" %>
<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>

<tiles:useAttribute name="separator" id="separator" classname="org.apache.struts.tiles.DirectStringAttribute"/>
<div id="separatorsTop">
    <%
        UserSession userSession = UserSessionProxy.loadUserSessionFromRequest(request);
        int sep = 1;
        try
        {
            sep = Integer.parseInt(separator.toString());
        }
        catch(NumberFormatException e)
        {}
        catch(NullPointerException e)
        {}

        String sep0 = "";
        String sep1 = "";
        String sep2 = "";
        String sep3 = "";
        String sep4 = "";
        String sep5 = "";
        String sep6 = "";
        String sep7 = "";

        String link0 = "href=\"" + request.getContextPath() + "/Welcome.do\"";
        String link1 = "href=\"" + request.getContextPath() + "/user/startHome.do\"";
        String link2 = "href=\"" + request.getContextPath() + "/user/startCourseUnits.do\"";
        String link3 = "href=\"" + request.getContextPath() + "/user/startProfile.do\"";
        String link4 = "href=\"" + request.getContextPath() + "/user/startServiceZone.do\"";
        String link5 = "href=\"" + request.getContextPath() + "/proxy/layoutIOnline/ionline/\"";
        String link6 = "href=\"" + request.getContextPath() + "/proxy/layoutIntranetUtils/estgp/intranet/escola/utils.html\"";
        String link7 = "href=\"" + request.getContextPath() + "/proxy/layoutIntranetContacts/estgp/intranet/contactos/servicos.html\"";

        if(sep == 0)
        {
            sep0 ="class=\"selected\"";
            link0 = "";
        }
        else if(sep == 1)
        {
            sep1 ="class=\"selected\"";
            link1 = "";
        }
        else if(sep == 2)
        {
            sep2 ="class=\"selected\"";
               link2 = "";
        }
        else if(sep == 3)
        {
               link3 = "";
            sep3 ="class=\"selected\"";
        }
        else if(sep == 4)
        {
               link4 = "";
            sep4 ="class=\"selected\"";
        }
        else if(sep == 5)
        {
               link5 = "";
            sep5 ="class=\"selected\"";
        }
        else if(sep == 6)
        {
               link6 = "";
            sep6 ="class=\"selected\"";
        }
        else if(sep == 7)
        {
               link7 = "";
            sep7 ="class=\"selected\"";
        }



    %>
    <div id="separators">
        <ul>
            <li <%=sep0%>><a <%=link0%>><span><bean:message key="intranet.separator.welcome.home"/></span></a></li>
            <li <%=sep1%>><a <%=link1%>><span><bean:message key="intranet.separator.home"/></span></a></li>
            <li <%=sep3%>><a <%=link3%>><span><bean:message key="intranet.separator.profile"/></span></a></li>
            <li <%=sep4%>><a <%=link4%>><span><bean:message key="intranet.separator.service.zone"/></span></a></li>
            <li <%=sep5%>><a <%=link5%>><span><bean:message key="intranet.separator.ionline"/></span></a></li>
            <li <%=sep7%>><a <%=link7%>><span><bean:message key="intranet.separator.contacts"/></span></a></li>
            <li <%=sep6%>><a <%=link6%>><span><bean:message key="intranet.separator.utils"/></span></a></li>
        </ul>
    </div>

Generated by GNU Enscript 1.6.5.2.