]> git.mxchange.org Git - pizzaservice-war.git/blob - web/admin/customer/admin_customer_list.xhtml
Updated copyright year
[pizzaservice-war.git] / web / admin / customer / admin_customer_list.xhtml
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">
3 <html
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"
9         >
10
11         <ui:composition template="/WEB-INF/templates/admin/admin_base.tpl">
12                 <ui:define name="admin_title">
13                         <h:outputText value="#{msg.PAGE_TITLE_ADMIN_LIST_USER}" />
14                 </ui:define>
15
16                 <ui:define name="content_header">
17                         <h:outputText value="#{msg.CONTENT_TITLE_ADMIN_LIST_USER}" />
18                 </ui:define>
19
20                 <ui:define name="content">
21                         <h:dataTable id="table_list_customers" var="customer" value="#{customerController.allCustomers()}" styleClass="table_big" headerClass="table_header_column" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_USER}" rendered="#{customerController.hasCustomers()}">
22                                 <h:column>
23                                         <f:facet name="header">
24                                                 <h:outputText value="#{msg.ADMIN_USER_ID}" />
25                                         </f:facet>
26
27                                         <h:link outcome="admin_show_customer" title="#{msg.ADMIN_LINK_SHOW_USER_TITLE}" value="#{customer.customerId}">
28                                                 <f:param name="customerId" value="#{customer.customerId}" />
29                                         </h:link>
30                                 </h:column>
31
32                                 <h:column>
33                                         <f:facet name="header">
34                                                 <h:outputText value="#{msg.ADMIN_USER_NUMBER}" />
35                                         </f:facet>
36
37                                         <h:outputText value="#{customer.customerNumber}" />
38                                 </h:column>
39
40                                 <h:column>
41                                         <f:facet name="header">
42                                                 <h:outputText value="#{msg.ADMIN_CONTACT_GENDER}" />
43                                         </f:facet>
44
45                                         <h:outputText value="#{msg[customer.customerContact.contactGender.messageKey]}" />
46                                 </h:column>
47
48                                 <h:column>
49                                         <f:facet name="header">
50                                                 <h:outputText value="#{msg.ADMIN_CONTACT_FIRST_NAME}" />
51                                         </f:facet>
52
53                                         <h:outputText value="#{customer.customerContact.contactFirstName}" />
54                                 </h:column>
55
56                                 <h:column>
57                                         <f:facet name="header">
58                                                 <h:outputText value="#{msg.ADMIN_CONTACT_FAMILY_NAME}" />
59                                         </f:facet>
60
61                                         <h:outputText value="#{customer.customerContact.contactFamilyName}" />
62                                 </h:column>
63
64                                 <h:column>
65                                         <f:facet name="header">
66                                                 <h:outputText value="#{msg.ADMIN_USER_ACCOUNT_STATUS}" />
67                                         </f:facet>
68
69                                         <h:outputText styleClass="#{customer.customerAccountStatus.styleClass}" value="#{msg[customer.customerAccountStatus.messageKey]}" />
70                                 </h:column>
71
72                                 <h:column>
73                                         <f:facet name="header">
74                                                 <h:outputText value="#{msg.ADMIN_USER_CREATED}" />
75                                         </f:facet>
76
77                                         <h:outputText id="customerCreated" value="#{customer.customerCreated.time}">
78                                                 <f:convertDateTime for="customerCreated" type="both" timeStyle="short" dateStyle="short" />
79                                         </h:outputText>
80                                 </h:column>
81                         </h:dataTable>
82
83                         <div class="table_medium">
84                                 <h:form id="form_admin_add_customer">
85                                         <div class="table_header">
86                                                 <h:outputText value="#{msg.ADMIN_ADD_USER_TITLE}" />
87                                         </div>
88
89                                         <div class="para">
90                                                 <fieldset id="customer_contact">
91                                                         <legend title="#{msg.ADMIN_SELECT_USER_CONTACT_LEGEND_TITLE}">
92                                                                 <h:outputText value="#{msg.ADMIN_SELECT_USER_CONTACT_LEGEND}" />
93                                                         </legend>
94
95                                                         <div class="table_row">
96                                                                 <div class="table_left_medium">
97                                                                         <h:outputLabel for="customerContact" value="#{msg.ADMIN_SELECT_USER_CONTACT}" />
98                                                                 </div>
99
100                                                                 <div class="table_right_medium">
101                                                                         <h:selectOneMenu class="select" id="customerContact" value="#{adminCustomerController.contact}" converter="ContactConverter">
102                                                                                 <f:selectItem itemValue="" itemLabel="#{msg.NONE_SELECTED}" />
103                                                                                 <f:selectItems value="#{customerController.selectableContacts()}" var="contact" itemValue="#{contact}" itemLabel="#{contact.contactId}: #{msg[contact.contactGender.messageKey]} #{contact.contactFirstName} #{contact.contactFamilyName}" />
104                                                                         </h:selectOneMenu>
105                                                                 </div>
106
107                                                                 <div class="clear"></div>
108                                                         </div>
109                                                 </fieldset>
110                                         </div>
111
112                                         <div class="para">
113                                                 <h:outputText value="#{msg.ADMIN_ADD_USER_OR_ENTER_CONTACT_DATA}" />
114                                         </div>
115
116                                         <ui:include src="/WEB-INF/templates/admin/customer/admin_form_customer_personal_data.tpl" />
117
118                                         <div class="table_footer">
119                                                 <h:commandButton class="reset" type="reset" value="#{msg.BUTTON_RESET_FORM}" />
120                                                 <h:commandButton class="submit" type="submit" id="add" value="#{msg.BUTTON_ADMIN_ADD_USER}" action="#{adminCustomerController.addCustomer()}" />
121                                         </div>
122                                 </h:form>
123                         </div>
124                 </ui:define>
125         </ui:composition>
126 </html>