Aggiunto l'esempio del capitolo su Java Server Faces

This commit is contained in:
Fabio Scotto di Santolo
2019-04-05 23:14:28 +02:00
parent 3d0faaa090
commit 9de150ccdc
21 changed files with 430 additions and 1 deletions

View File

@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<!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:h="http://xmlns.jcp.org/jsf/html"
xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
xmlns:f="http://xmlns.jcp.org/jsf/core">
<ui:composition template="layout.xhtml">
<f:metadata>
<f:viewParam name="id" value="#{bookView.book.id}"/>
<f:viewAction action="#{bookView.doFindBookById}"/>
</f:metadata>
<ui:define name="title">View a book</ui:define>
<ui:define name="content">
<h:panelGrid columns="2">
<h:outputLabel value="Title: "/>
<h:outputText value="#{bookView.book.title}"/>
<h:outputLabel value="Price: "/>
<h:outputText value="#{bookView.book.price}"/>
<h:outputLabel value="Description: "/>
<h:outputText value="#{bookView.book.description}"/>
<h:outputLabel value="Number of pages: "/>
<h:outputText value="#{bookView.book.nbOfPage}"/>
<h:outputLabel value="Illustrations: "/>
<h:selectBooleanCheckbox value="#{bookView.book.illustrations}"/>
</h:panelGrid>
</ui:define>
</ui:composition>
</html>