]> git.mxchange.org Git - pizzaservice-war.git/blob - web/admin/user/admin_user_lock.xhtml
Continued a bit: (please cherry-pick)
[pizzaservice-war.git] / web / admin / user / admin_user_lock.xhtml
1
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         <f:metadata>
12                 <f:viewParam name="userId" value="#{beanHelper.user}" converter="UserConverter" required="true" requiredMessage="#{msg.ERROR_PARAMETER_USER_ID_NOT_SET}" />
13                 <f:viewAction action="#{beanHelper.copyUserToController()}" />
14         </f:metadata>
15
16         <ui:composition template="/WEB-INF/templates/admin/admin_base.tpl">
17                 <ui:define name="admin_title">#{msg.PAGE_TITLE_ADMIN_LOCK_USER}</ui:define>
18
19                 <ui:define name="content_header">
20                         #{msg.CONTENT_TITLE_ADMIN_LOCK_USER}
21                 </ui:define>
22
23                 <ui:define name="content">
24                         <h:outputText styleClass="errors" value="#{msg.ERROR_USER_ID_NOT_FOUND}" rendered="#{empty beanHelper.user}" />
25
26                         <h:form id="form_admin_user_unlock" rendered="#{not empty beanHelper.user and beanHelper.user.userAccountStatus == 'CONFIRMED'}">
27                                 <div class="table_medium">
28                                         <div class="table_header">
29                                                 <h:outputFormat value="#{msg.ADMIN_LOCK_USER_TITLE}">
30                                                         <f:param value="#{beanHelper.user.userName}" />
31                                                         <f:param value="#{beanHelper.user.userId}" />
32                                                 </h:outputFormat>
33                                         </div>
34
35                                         <div class="para">
36                                                 <div>
37                                                         <h:outputLabel for="contactGender" value="#{msg.PERSONAL_DATA_GENDER}" />
38                                                 </div>
39
40                                                 <div>
41                                                         <h:outputText id="contactGender" value="#{msg[beanHelper.user.userContact.contactGender.messageKey]}" />
42                                                 </div>
43                                         </div>
44
45                                         <div class="para">
46                                                 <div>
47                                                         <h:outputLabel for="contactFirstName" value="#{msg.PERSONAL_DATA_FIRST_NAME}" />
48                                                 </div>
49
50                                                 <div>
51                                                         <h:outputText id="contactFirstName" value="#{beanHelper.user.userContact.contactFirstName}" />
52                                                 </div>
53                                         </div>
54
55                                         <div class="para">
56                                                 <div>
57                                                         <h:outputLabel for="contactFamilyName" value="#{msg.PERSONAL_DATA_FAMILY_NAME}" />
58                                                 </div>
59
60                                                 <div>
61                                                         <h:outputText id="contactFamilyName" value="#{beanHelper.user.userContact.contactFamilyName}" />
62                                                 </div>
63                                         </div>
64
65                                         <div class="para">
66                                                 <div>
67                                                         <h:outputLabel for="userLockReason" value="#{msg.ADMIN_ENTER_USER_LOCK_REASON}" />
68                                                 </div>
69
70                                                 <div>
71                                                         <h:inputTextarea id="userLockReason" value="#{adminUserController.userLockReason}" cols="50" rows="10" required="true" requiredMessage="#{msg.ADMIN_USER_UNLOCK_REASON_REQUIRED}" rendered="#{beanHelper.user.userAccountStatus == 'CONFIRMED'}" />
72
73                                                         <h:outputText value="#{msg.ERROR_CANNOT_UN_LOCK_USER_ACCOUNT_UNCONFIRMED}" rendered="#{beanHelper.user.userAccountStatus == 'UNCONFIRMED'}" />
74                                                 </div>
75                                         </div>
76
77                                         <div class="table_footer">
78                                                 <h:commandButton styleClass="reset" type="reset" value="#{msg.BUTTON_RESET_FORM}" />
79
80                                                 <h:commandButton styleClass="submit" type="submit" action="#{adminUserController.lockUserAccount(beanHelper.user)}" value="#{msg.BUTTON_ADMIN_LOCK_USER_ACCOUNT}" />
81                                         </div>
82                                 </div>
83                         </h:form>
84
85                         <h:outputText styleClass="errors" value="#{msg.ERROR_CANNOT_UN_LOCK_USER_ACCOUNT_UNCONFIRMED}" rendered="#{beanHelper.user.userAccountStatus == 'UNCONFIRMED'}" />
86                 </ui:define>
87         </ui:composition>
88 </html>