projectDAE/ProjectDAE/ProjectDAE-war/build/web/event_details.xhtml

160 lines
5.7 KiB
HTML

<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this license header, choose License Headers in Project Properties.
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://xmlns.jcp.org/jsf/html"
xmlns:f="http://xmlns.jcp.org/jsf/core">
<head>
<title>Event Details</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
</head>
<body>
<div>Event Details:</div>
<h:dataTable value="#{administratorManager.currentEvent}"
var="event"
summary="List of all Event"
rules="all"
cellpadding="5">
<h:column>
<f:facet name="header">ID</f:facet>
<h:outputText value="#{event.id}"/>
</h:column>
<h:column>
<f:facet name="header">Date</f:facet>
<h:outputText value="#{event.date}"/>
</h:column>
<h:column>
<f:facet name="header">Name</f:facet>
<h:outputText value="#{event.name}"/>
</h:column>
<h:column>
<f:facet name="header">Type</f:facet>
<h:outputText value="#{event.type}"/>
</h:column>
<h:column>
<f:facet name="header">Local</f:facet>
<h:outputText value="#{event.local}"/>
</h:column>
<h:column>
<f:facet name="header">Responsible</f:facet>
<h:outputText value="#{event.responsible_name}"/>
</h:column>
<h:column>
<f:facet name="header">Open Inscriptions</f:facet>
<h:outputText value="#{event.openInscriptions}"/>
</h:column>
<h:column>
<h:form rendered="#{!event.openInscriptions}">
<h:commandLink value="Open inscriptions" actionListener="#{administratorManager.openInscription}">
<f:param name="eventID" id="eventID" value="#{event.id}"/>
</h:commandLink>
</h:form>
<h:form rendered="#{event.openInscriptions}">
<h:commandLink value="Close inscriptions" actionListener="#{administratorManager.closeInscription}">
<f:param name="eventID" id="eventID" value="#{event.id}"/>
</h:commandLink>
</h:form>
<h:form>
<h:commandLink action="add_participant_event" value="Add Participant"></h:commandLink>
</h:form>
</h:column>
</h:dataTable>
<br></br>
<div>Enrolled Participants:</div>
<h:dataTable value="#{administratorManager.enrolledParticipants}"
var="participant"
summary="List of Enrolled Participants"
rules="all"
cellpadding="5">
<h:column>
<f:facet name="header">ID</f:facet>
<h:outputText value="#{participant.id}"/>
</h:column>
<h:column>
<f:facet name="header">Name</f:facet>
<h:outputText value="#{participant.name}"/>
</h:column>
<h:column>
<f:facet name="header">Email</f:facet>
<h:outputText value="#{participant.email}"/>
</h:column>
<h:column>
<f:facet name="header">Present</f:facet>
<h:outputText value="No"/>
</h:column>
<h:column>
<f:facet name="header">
<h:outputText value="Actions" />
</f:facet>
<h:form>
<h:commandLink value="Remove participant" actionListener="#{administratorManager.unrollParticipants}" action="event_details?faces-redirect=true">
<f:param name="participantId" id="participantId" value="#{participant.id}"/>
</h:commandLink>
</h:form>
</h:column>
</h:dataTable>
<br></br>
<div>Unrolled Participants:</div>
<h:dataTable value="#{administratorManager.unrolledParticipants}"
var="participant"
summary="List of Unrolled Participants"
rules="all"
cellpadding="5">
<h:column>
<f:facet name="header">ID</f:facet>
<h:outputText value="#{participant.id}"/>
</h:column>
<h:column>
<f:facet name="header">Name</f:facet>
<h:outputText value="#{participant.name}"/>
</h:column>
<h:column>
<f:facet name="header">Email</f:facet>
<h:outputText value="#{participant.email}"/>
</h:column>
<h:column>
<f:facet name="header">
<h:outputText value="Actions" />
</f:facet>
<h:form>
<h:commandLink value="Add participant" actionListener="#{administratorManager.enrollParticipants}" action="event_details?faces-redirect=true">
<f:param name="participantId" id="participantId" value="#{participant.id}"/>
</h:commandLink>
</h:form>
</h:column>
</h:dataTable>
<br></br>
<h:form>
<h:commandLink action="AdminPage" value="Back"></h:commandLink>
</h:form>
</body>
</html>