index.xhtml 2.26 KB
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:h="http://java.sun.com/jsf/html" xmlns:users="http://java.sun.com/jsf/composite/cditools/user" xmlns:tools="http://java.sun.com/jsf/composite/cditools" xmlns:p="http://primefaces.org/ui" xmlns:f="http://java.sun.com/jsf/core">
<h:body>
	<ui:composition template="#{sessionHandler.template}">
		<f:metadata>
			<!--  <f:event type="preRenderView" listener="#{userOverviewView.initView()}" />  -->
		</f:metadata>

		<ui:define name="content">
		
			<h1>#{i18n['tournaments.admin.title']}</h1>
			<p>#{i18n['tournaments.admin.description']}</p>
			<h2>#{i18n['tournaments.active_tournaments']}</h2>
 			<p:dataTable value="#{tournamentAdminView.activeTournaments}" var="tournament">
 				<p:column>
					<f:facet name="header">
						<h:outputText value="#{i18n['tournament.name']}" />
					</f:facet>
					<h:outputText value="#{tournament.tournamentName}" />
				</p:column>
				<p:column>
					<f:facet name="header">
						<h:outputText value="#{i18n['tournament.status']}" />
					</f:facet>
					<h:outputText value="#{tournament.tournamentStatus}" />
				</p:column>
				<p:column>
					<f:facet name="header">
						<h:outputText value="#{i18n['tournament.type']}" />
					</f:facet>
					<h:outputText value="#{tournament.tournamentType}" />
				</p:column>
				<p:column>
					<f:facet name="header">
						<h:outputText value="#{i18n['tournament.playerspermatch_slash_teamsize']}" />
					</f:facet>
					<h:outputText value="#{tournament.playersPerMatch}/#{tournament.playersPerTeam}" />
				</p:column>
				<p:column>
					<f:facet name="header">
						<h:outputText value="#{i18n['tournament.game']}" />
					</f:facet>
					<h:outputText value="#{tournament.tournamentGame.name}" />
				</p:column>
				<p:column>
					<f:facet name="header">
						<h:outputText value="#{i18n['tournament.rules']}" />
					</f:facet>
					<h:outputText value="#{tournament.rules.name}" />
				</p:column>
 			</p:dataTable>
			<h:form>
				<p:commandButton value="#{i18n['tournament.admin.create']}" action="#{tournamentAdminView.create}" />
			</h:form>
		</ui:define>
	</ui:composition>
</h:body>
</html>