1 <?xml version="1.0" encoding="UTF-8" ?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
4 lang="#{localizationController.language}" xml:lang="#{localizationController.language}"
5 xmlns="http://www.w3.org/1999/xhtml"
6 xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
7 xmlns:h="http://xmlns.jcp.org/jsf/html"
8 xmlns:f="http://xmlns.jcp.org/jsf/core"
11 <ui:composition template="/WEB-INF/templates/admin/admin_base.tpl">
12 <ui:define name="admin_title">#{msg.PAGE_TITLE_ADMIN_LIST_CUSTOMER}</ui:define>
14 <ui:define name="content_header">
15 #{msg.CONTENT_TITLE_ADMIN_LIST_CUSTOMER}
18 <ui:define name="content">
19 <h:dataTable id="table_list_customers" var="customer" value="#{customerController.allCustomers()}" styleClass="table_big" headerClass="table_header_column" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_CUSTOMER}" rendered="#{customerController.hasCustomers()}">
21 <f:facet name="header">#{msg.ADMIN_CUSTOMER_ID}</f:facet>
23 <h:link outcome="admin_show_customer" title="#{msg.ADMIN_LINK_SHOW_CUSTOMER_TITLE}" value="#{customer.customerId}">
24 <f:param name="customerId" value="#{customer.customerId}" />
29 <f:facet name="header">#{msg.ADMIN_CUSTOMER_NUMBER}</f:facet>
31 <h:outputText value="#{customer.customerNumber}" />
35 <f:facet name="header">#{msg.ADMIN_CONTACT_GENDER}</f:facet>
37 <h:outputText value="#{msg[customer.customerContact.contactGender.messageKey]}" />
41 <f:facet name="header">#{msg.ADMIN_CONTACT_FIRST_NAME}</f:facet>
43 <h:outputText value="#{customer.customerContact.contactFirstName}" />
47 <f:facet name="header">#{msg.ADMIN_CONTACT_FAMILY_NAME}</f:facet>
49 <h:outputText value="#{customer.customerContact.contactFamilyName}" />
53 <f:facet name="header">#{msg.ADMIN_CUSTOMER_ACCOUNT_STATUS}</f:facet>
55 <h:outputText styleClass="#{customer.customerAccountStatus.styleClass}" value="#{msg[customer.customerAccountStatus.messageKey]}" />
59 <f:facet name="header">#{msg.ADMIN_CUSTOMER_CREATED}</f:facet>
61 <h:outputText id="customerCreated" value="#{customer.customerCreated.time}">
62 <f:convertDateTime for="customerCreated" type="both" timeStyle="short" dateStyle="short" />
67 <div class="table_medium">
68 <h:form id="admin_add_customer">
69 <div class="table_header">
70 #{msg.ADMIN_ADD_CUSTOMER_TITLE}
74 <fieldset id="customer_contact">
75 <legend title="#{msg.ADMIN_SELECT_CUSTOMER_CONTACT_LEGEND_TITLE}">#{msg.ADMIN_SELECT_CUSTOMER_CONTACT_LEGEND}</legend>
77 <div class="table_row">
78 <div class="table_left_medium">
79 <h:outputLabel for="customerContact" value="#{msg.ADMIN_SELECT_CUSTOMER_CONTACT}" />
82 <div class="table_right_medium">
83 <h:selectOneMenu class="select" id="customerContact" value="#{adminHelper.contact}" converter="ContactConverter">
84 <f:selectItem itemValue="" itemLabel="#{msg.NONE_SELECTED}" />
85 <f:selectItems value="#{customerController.selectableContacts()}" var="contact" itemValue="#{contact}" itemLabel="#{contact.contactId}: #{msg[contact.contactGender.messageKey]} #{contact.contactFirstName} #{contact.contactFamilyName}" />
89 <div class="clear"></div>
95 <h:outputText value="#{msg.ADMIN_ADD_CUSTOMER_OR_ENTER_CONTACT_DATA}" />
98 <ui:include src="/WEB-INF/templates/admin/customer/admin_form_customer_personal_data.tpl" />
100 <div class="table_footer">
101 <h:commandButton class="reset" type="reset" value="#{msg.BUTTON_RESET_FORM}" />
102 <h:commandButton class="submit" type="submit" id="add" value="#{msg.BUTTON_ADMIN_ADD_CUSTOMER}" action="#{adminCustomerController.addCustomer()}" />