alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

Java EE 6 example source code file (allInOne.xhtml)

This example Java EE 6 source code file (allInOne.xhtml) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - Java EE 6 tags/keywords

descreva, describe, describe, doctype, home, no, sprint, story, story, transitional//en, transitional//en, type, type, w3c//dtd

The Java EE 6 allInOne.xhtml source code

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.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:f="http://java.sun.com/jsf/core">

<ui:composition template="template.xhtml">
<ui:define name="pageTitle">
    <h:outputText value="HOME needs i18n">
</ui:define>

<ui:define name="content">
	<h:messages globalOnly="true" showDetail="true" tooltip="true" errorClass="errorMsgs" infoClass="infoMsgs" />	
    <h:form id="frmNew">	    
    	<h2>New Sprint
		<h:panelGrid columns="3" style="width: 300px">
				<h:outputLabel value="#{i18n['sprints.label.name']}:" for="itName"  />
				<h:inputText id="itName" value="#{allInOneMB.sprintsMB.toSave.name}" required="true" requiredMessage="Type the short name" />
				<h:message for="itName" />
				
				<h:outputLabel value="#{i18n['sprints.label.goals']}:" for="itGoals"  />
				<h:inputText id="itGoals" value="#{allInOneMB.sprintsMB.toSave.goals}" required="true" requiredMessage="Describe the goals" />
				<h:message for="itGoals" />
				
				<h:outputLabel value="#{i18n['sprints.label.iterationScope']}:" for="itIterationScope"  />
				<h:inputText id="itIterationScope" value="#{allInOneMB.sprintsMB.toSave.iterationScope}" required="true" requiredMessage="Type the scope" />
				<h:message for="itIterationScope" />
				
				<h:outputLabel value="#{i18n['sprints.label.startedAt']}:" for="itStartedAt"  />
				<h:inputText id="itStartedAt" value="#{allInOneMB.sprintsMB.toSave.startedAt}" required="true" requiredMessage="Type when this sprint start" />
				<h:message for="itStartedAt" />
				
				<h:outputLabel value="#{i18n['sprints.label.dailyMeetingTime']}:" for="itDailyMeetingTime"  />
				<h:inputText id="itDailyMeetingTime" value="#{allInOneMB.sprintsMB.toSave.dailyMeetingTime}" required="true" requiredMessage="Type the estimation (story points)" />
				<h:message for="itDailyMeetingTime" />
				
				<f:verbatim>
				<f:verbatim>
				<h:commandButton action="#{allInOneMB.sprintsMB.save}" value="save" />
		</h:panelGrid>
    </h:form>
    <h:form id="frmList">
    	<h2>Sprints
		<h:panelGrid columns="3" style="width: 300px">
				<h:outputLabel value="Not exist sprints" style="color: orange"  rendered="#{allInOneMB.sprintsMB.dm.rowCount eq 0}"/>
		</h:panelGrid>
		<h:dataTable value="#{allInOneMB.sprintsMB.dm}" var="sprint" width="100%" rendered="#{allInOneMB.sprintsMB.dm.rowCount > 0}">
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{allInOneMB.sprintsMB.dm.rowIndex + 1}" />
				<f:facet name="footer">#{""}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{sprint.name}" />
				<f:facet name="footer">#{allInOneMB.sprintsMB.dm.rowCount}#{" sprints"}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{sprint.goals}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{sprint.iterationScope}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{sprint.startedAt}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{sprint.dailyMeetingTime}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column>
				<f:facet name="header">
				<h:commandButton action="#{allInOneMB.sprintsMB.edit}" value="edit ..."  />
				<h:commandButton action="#{allInOneMB.sprintsMB.remove}" value="remove"  />
				<h:commandButton action="#{allInOneMB.sprintsMB.showStories}" value="stories ..."  />
				<h:commandButton action="#{allInOneMB.sprintsMB.showDashboard}" value="dashboard ..."  />
				<f:facet name="footer">#{" "}
			</h:column>
		</h:dataTable>
    </h:form>
    <h:form id="frmNewStory">
    	<h2>New Story
		<h:panelGrid columns="3" style="width: 300px">
				<h:outputLabel value="#{i18n['stories.label.sprint']}:" for="otSprint"  />
				<h:outputText id="otSprint" value="#{storiesMB.toSave.sprint.name}"  />
				<h:message for="otSprint" />
				<h:outputLabel value="#{i18n['stories.label.name']}:" for="itName"  />
				<h:inputText id="itName" value="#{storiesMB.toSave.name}" required="true" requiredMessage="Describe the story" />
				<h:message for="itName" />
				<h:outputLabel value="#{i18n['stories.label.acceptance']}:" for="itAcceptance"  />
				<h:inputTextarea id="itAcceptance" value="#{storiesMB.toSave.acceptance}" required="true" cols="50" rows="4" requiredMessage="Describe the acceptance" />
				<h:message for="itAcceptance" />
				<h:outputLabel value="#{i18n['stories.label.priority']}:" for="selPriority"  />
				<h:inputText id="selPriority" value="#{storiesMB.toSave.priority}" required="true" requiredMessage="Type the priority (sequence to do)" />
				<h:message for="selPriority" />
				<h:outputLabel value="#{i18n['stories.label.estimation']}:" for="itEstimation"  />
				<h:inputText id="itEstimation" value="#{storiesMB.toSave.estimation}" required="true" requiredMessage="Type the estimation (story points)" />
				<h:message for="itEstimation" />
				<f:verbatim>
				<f:verbatim>
				<h:commandButton action="#{storiesMB.save}" value="save" />
		</h:panelGrid>
    </h:form>
    <h:form id="frmStories">
    	<h2>Stories
		<h:panelGrid columns="3" >
				<h:outputLabel value="No exist stories for this sprint"  rendered="#{storiesMB.dm.rowCount eq 0}"/>
		</h:panelGrid>
		<h:dataTable value="#{storiesMB.dm}" var="story" width="100%" rendered="#{storiesMB.dm.rowCount > 0}">
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{storiesMB.dm.rowIndex + 1}" />
				<f:facet name="footer">#{""}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{story.name}" />
				<f:facet name="footer">#{storiesMB.dm.rowCount}#{" stories"}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{story.priority}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{story.estimation}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{story.acceptance}" />
				<f:facet name="footer">#{" "}
			</h:column>
			<h:column>
				<f:facet name="header">
				<h:commandButton action="#{storiesMB.edit}" value="edit ..." immediate="true" />
				<h:commandButton action="#{storiesMB.remove}" value="remove" immediate="true" />
				<h:commandButton action="#{storiesMB.showTasks}" value="tasks" immediate="true" />
				<f:facet name="footer">#{" "}
			</h:column>
		</h:dataTable>
    </h:form>
    <h:form id="frmNewTask">
	    <h:commandLink action="stories" value="#{'go back stories'}" immediate="true" />
    	<h2>New Task
		<h:panelGrid columns="3" style="width: 300px">
				<h:outputLabel value="#{i18n['tasks.label.story']}:" for="otStory"  />
				<h:outputText id="otStory" value="#{tasksMB.taskToSave.story.name}" />
				<h:message for="otStory" />
				<h:outputLabel value="#{i18n['tasks.label.name']}:" for="itName"  />
				<h:inputText id="itName" value="#{tasksMB.taskToSave.name}" required="true" requiredMessage="Descreva a tarefa" />
				<h:message for="itName" />
				<f:verbatim>
				<f:verbatim>
				<h:commandButton action="#{tasksMB.save}" value="save" />
		</h:panelGrid>
    </h:form>
    <h:form id="frmTasks">
    	<h2>Tasks
		<h:panelGrid columns="3" style="width: 300px">
				<h:outputLabel value="Nao ha tarefas para esta estoria" style="color: orange"  rendered="#{tasksMB.dmTasks.rowCount eq 0}"/>
		</h:panelGrid>
		<h:dataTable value="#{tasksMB.dmTasks}" var="task" width="300px" rendered="#{tasksMB.dmTasks.rowCount > 0}">
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{tasksMB.dmTasks.rowIndex + 1}" />
				<f:facet name="footer">#{""}
			</h:column>
			<h:column headerClass="textColumn">
				<f:facet name="header">
				<h:outputText value="#{task.name}" />
				<f:facet name="footer">#{tasksMB.dmTasks.rowCount}#{" tasks"}
			</h:column>
			<h:column>
				<f:facet name="header">
				<h:commandButton action="#{tasksMB.edit}" value="edit ..." immediate="true" />
				<h:commandButton action="#{tasksMB.remove}" value="remove" immediate="true" />
				<f:facet name="footer">#{" "}
			</h:column>
		</h:dataTable>
    </h:form>
</ui:define>
</ui:composition>
</html>  

Other Java EE 6 examples (source code examples)

Here is a short list of links related to this Java EE 6 allInOne.xhtml source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.