Files
myhealth/1.sources/MyHealth/docroot/home.xhtml
Marcos Garcia Nuñez 75ed5e2635 Mejora en la gestión de excepciones y errores. Nuevo managedBean para
gestión de errores anto AJAX como en peticiones normales.
2020-01-01 21:42:31 +01:00

34 lines
1.6 KiB
HTML

<?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:ui="http://java.sun.com/jsf/facelets" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
xmlns:p="http://primefaces.org/ui" xmlns:o="http://omnifaces.org/ui">
<ui:composition template="./header.xhtml">
<ui:define name="content">
<h:form>
<p:panel header="Pagina principal">
<div class="ui-g ui-fluid">
<div class="ui-g-12 ui-md-12">
Logeado como:
<h:outputLabel value="#{home.userDisplayName}" style="font-weight: bold;" />
</div>
<div class="ui-g-2 ui-md-2">
<p:outputLabel for="selectorTema" value="Cambio de tema" />
</div>
<div class="ui-g-3 ui-md-3">
<p:themeSwitcher id="selectorTema" style="width:300px" value="#{sessionPreferences.currentTheme}">
<f:selectItem itemLabel="Seleccione un tema" itemValue="" noSelectionOption="true" />
<f:selectItems value="#{home.themes}" var="theme" itemLabel="#{theme.displayName}" itemValue="#{theme.name}" />
<p:ajax listener="#{sessionPreferences.updateCurrentTheme}" />
</p:themeSwitcher>
</div>
<div class="ui-g-2 ui-md-2">
<p:commandButton value="Usar tema" update="messages" action="#{sessionPreferences.updateCurrentTheme}" icon="pi pi-save" />
</div>
<div class="ui-g-5 ui-md-5" />
</div>
</p:panel>
</h:form>
</ui:define>
</ui:composition>
</html>