Rev 312 | Blame | Compare with Previous | Last modification | View Log | RSS feed
<%@ page import="pt.estgp.estgweb.domain.Teacher" %>
<%@ page import="pt.estgp.estgweb.domain.TeacherImpl" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="/WEB-INF/tlds/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/tlds/struts-nested.tld" prefix="nested" %>
<%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/tlds/struts-tiles.tld" prefix="tiles" %>
<%@ taglib uri="/WEB-INF/tlds/baco.tld" prefix="baco" %>
<%@ taglib uri="/WEB-INF/tlds/jomm.tld" prefix="jomm" %>
<jsp:useBean id="CourseUnitView" type="pt.estgp.estgweb.domain.views.CourseUnitView" scope="request"/>
<jsp:useBean id="UserSession" type="pt.estgp.estgweb.domain.UserSession" scope="request"/>
<%
String fromAction = "";
String user = "";
if (request.getParameter("from") != null)
{
user = "/user";
fromAction = "From" + request.getParameter("from");
if(request.getParameter("from").equals("CourseUnit"))
{
fromAction = "FromHome";
}
}
request.setAttribute("user", user);
request.setAttribute("fromAction", fromAction);
%>
<div id="contentPane">
<h1>${CourseUnitView.name} (${CourseUnitView.code})</h1>
<table width="100%" cellpadding="0" cellspacing="2" border="0">
<tr>
<td valign="top" class="seccao">
<html:form styleClass="form" action="/user/courseUnitControllerFromHome" enctype="multipart/form-data">
<input type="hidden" name="dispatch" value="update"/>
<html:hidden property="courseUnitView.id"/>
<h2><bean:message key="courseunit.objectives"/></h2>
<p>
<baco:cantManage name="CourseUnitView">
<logic:present name="CourseUnitView" property="objectives">
${CourseUnitView.objectives}
</logic:present>
<logic:notPresent name="CourseUnitView" property="objectives">
<bean:message key="courseunit.objectives.not.available"/>
</logic:notPresent>
</baco:cantManage>
<baco:canManage name="CourseUnitView">
<html:textarea styleClass="textarea" property="courseUnitView.objectives"/>
</baco:canManage>
</p>
<p>
<baco:canManage name="CourseUnitView">
<html:file property="programFile"/>
</baco:canManage>
<logic:present name="CourseUnitView" property="programStreamId">
<a href="<%=request.getContextPath()%>/repositoryStream/${CourseUnitView.programStreamId}"><bean:message key="courseunit.programfilepath"/></a> (${CourseUnitView.programSize} Kb)
</logic:present>
<logic:notPresent name="CourseUnitView" property="programStreamId">
<bean:message key="courseunit.programfilepath.not.available"/>
</logic:notPresent>
</p>
<baco:canManage name="CourseUnitView">
<input type="button" onclick="set(form,'update');form.submit()" value="<bean:message key="confirm"/>">
</baco:canManage>
</html:form>
</td>
<td valign="top" class="seccao">
<h2><bean:message key="courseunit.teachers"/></h2>
<table class="dataTable">
<tr>
<th><bean:message key="number"/></th>
<th><bean:message key="name"/></th>
<th><bean:message key="email"/></th>
</tr>
<logic:iterate id="teacher" name="CourseUnitView" property="teachers" type="pt.estgp.estgweb.domain.views.UserView">
<tr>
<td>
${teacher.code}
</td>
<td>
<html:link action="${user}/startLoadTeacherCourseUnit${fromAction}?code=${teacher.code}&courseUnitView.id=${CourseUnitView.id}">${teacher.name}</html:link>
</td>
<td>
${teacher.safeEmail}
</td>
</tr>
</logic:iterate>
</table>
</td>
</tr>
<baco:isAuthenticated>
<tr>
<td class="seccao" valign="top">
<h2><bean:message key="module.Announcements"/></h2>
<logic:notEmpty name="CourseUnitView" property="announcements">
<div class="listCircleWhite">
<ul>
<logic:iterate id="announcement" name="CourseUnitView" property="announcements" type="pt.estgp.estgweb.domain.views.AnnouncementView">
<li>
<h3><html:link action="/user/startLoadAnnouncementFromCourseUnit?id=${announcement.id}">${announcement.title}</html:link></h3>
<p>${announcement.formatedText}</p>
<p class="pFooterSeccao"><bean:message key="from"/>: ${announcement.owner.name} (${announcement.owner.username}) <bean:message key="at"/> ${announcement.formatedSaveDate} </p>
</li>
</logic:iterate>
</ul>
</div>
</logic:notEmpty>
<logic:empty name="CourseUnitView" property="announcements">
<p><bean:message key="announcement.zero.placed"/></p>
</logic:empty>
</td>
<td class="seccao" valign="top">
<h2><bean:message key="courseunit.summaries"/></h2>
<logic:notEmpty name="CourseUnitView" property="summaries">
<div class="listCircleWhite">
<ul>
<logic:iterate id="summary" name="CourseUnitView" property="summaries" type="pt.estgp.estgweb.domain.views.CourseUnitSummaryView">
<li>
<h3>(${summary.date}) - ${summary.title}</h3>
<p>${summary.description}</p>
<p class="pFooterSeccao">${summary.students} <bean:message key="courseunit.summary.present.students"/> </p>
</li>
</logic:iterate>
</ul>
</div>
</logic:notEmpty>
<logic:empty name="CourseUnitView" property="summaries">
<p><bean:message key="courseunit.summaries.zero.placed"/></p>
</logic:empty>
</td>
</tr>
</baco:isAuthenticated>
</table>
</div>
Generated by GNU Enscript 1.6.5.2.