]> git.mxchange.org Git - jjobs-war.git/blobdiff - web/admin/user/admin_user_unlock.xhtml
Continued with cleanup: (please cherry-pick)
[jjobs-war.git] / web / admin / user / admin_user_unlock.xhtml
index 19ec057cd5a3ce69a1a42190403e31610eabc2d3..f9ed10adc2c9862d029a679f7c398aa6d6662307 100644 (file)
                        <h:outputText styleClass="errors" value="#{msg.ERROR_USER_ID_NOT_FOUND}" rendered="#{empty beanHelper.user}" />
 
                        <h:form id="form_admin_user_unlock" rendered="#{not empty beanHelper.user}">
-                               <div class="table">
+                               <div class="table_medium">
                                        <div class="table_header">
                                                <h:outputFormat value="#{msg.ADMIN_UNLOCK_USER_TITLE}">
-                                                       <f:param value="#{beanHelper.user.userId}" />
                                                        <f:param value="#{beanHelper.user.userName}" />
+                                                       <f:param value="#{beanHelper.user.userId}" />
                                                </h:outputFormat>
                                        </div>
 
-                                       <div class="table_row">
-                                               <div class="table_left25">
+                                       <div class="para">
+                                               <div>
                                                        <h:outputLabel for="contactGender" value="#{msg.PERSONAL_DATA_GENDER}" />
                                                </div>
 
-                                               <div class="table_right75">
+                                               <div>
                                                        <h:outputText id="contactGender" value="#{msg[beanHelper.user.userContact.contactGender.messageKey]}" />
                                                </div>
                                        </div>
 
-                                       <div class="table_row">
-                                               <div class="table_left25">
+                                       <div class="para">
+                                               <div>
                                                        <h:outputLabel for="contactFirstName" value="#{msg.PERSONAL_DATA_FIRST_NAME}" />
                                                </div>
 
-                                               <div class="table_right75">
+                                               <div>
                                                        <h:outputText id="contactFirstName" value="#{beanHelper.user.userContact.contactFirstName}" />
                                                </div>
                                        </div>
 
-                                       <div class="table_row">
-                                               <div class="table_left25">
+                                       <div class="para">
+                                               <div>
                                                        <h:outputLabel for="contactFamilyName" value="#{msg.PERSONAL_DATA_FAMILY_NAME}" />
                                                </div>
 
-                                               <div class="table_right75">
+                                               <div>
                                                        <h:outputText id="contactFamilyName" value="#{beanHelper.user.userContact.contactFamilyName}" />
                                                </div>
                                        </div>
 
-                                       <div class="table_row">
-                                               <div class="table_left25">
+                                       <div class="para">
+                                               <div>
                                                        <h:outputLabel for="userLockReason" value="#{msg.ADMIN_ENTER_USER_LOCK_REASON}" />
                                                </div>
 
-                                               <div class="table_right75">
-                                                       <h:inputTextarea id="userLockReason" value="#{adminUserController.userLockReason}" cols="30" rows="20" required="true" requiredMessage="#{msg.ADMIN_USER_UNLOCK_REASON_REQUIRED}" />
+                                               <div>
+                                                       <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'}" />
 
-                                                       <h:outputText value="#{adminUserController.userLockReason}" />
+                                                       <h:outputText value="#{adminUserController.userLockReason}" rendered="#{beanHelper.user.userAccountStatus == 'LOCKED'}" />
 
-                                                       <h:outputText value="#{msg.ERROR_CANNOT_UN_LOCK_USER_ACCOUNT_UNCONFIRMED}" rendered="#{beanHelper.user.userAccountStatus == UserAccountStatus.UNCONFIRMED}" />
+                                                       <h:outputText value="#{msg.ERROR_CANNOT_UN_LOCK_USER_ACCOUNT_UNCONFIRMED}" rendered="#{beanHelper.user.userAccountStatus == 'UNCONFIRMED'}" />
                                                </div>
                                        </div>
 
                                        <div class="table_footer">
                                                <h:commandButton styleClass="reset" type="reset" value="#{msg.BUTTON_RESET_FORM}" />
 
-                                               <h:commandButton styleClass="submit" type="submit" action="#{adminUserController.lockUserAccount(beanHelper.user)}" value="#{msg.BUTTON_ADMIN_LOCK_USER_ACCOUNT}" rendered="#{beanHelper.user.userAccountStatus == UserAccountStatus.CONFIRMED}" />
+                                               <ui:fragment rendered="#{beanHelper.user.userAccountStatus == 'CONFIRMED'}">
+                                                       <h:commandButton styleClass="submit" type="submit" action="#{adminUserController.lockUserAccount(beanHelper.user)}" value="#{msg.BUTTON_ADMIN_LOCK_USER_ACCOUNT}" />
+                                               </ui:fragment>
 
-                                               <h:commandButton styleClass="submit" type="submit" action="#{adminUserController.unlockUserAccount(beanHelper.user)}" value="#{msg.BUTTON_ADMIN_UNLOCK_USER_ACCOUNT}" rendered="#{beanHelper.user.userAccountStatus == UserAccountStatus.LOCKED}" />
+                                               <ui:fragment rendered="#{beanHelper.user.userAccountStatus == 'LOCKED'}">
+                                                       <h:commandButton styleClass="submit" type="submit" action="#{adminUserController.unlockUserAccount(beanHelper.user)}" value="#{msg.BUTTON_ADMIN_UNLOCK_USER_ACCOUNT}" />
+                                               </ui:fragment>
 
-                                               <h:outputText value="#{msg.ERROR_CANNOT_UN_LOCK_USER_ACCOUNT_UNCONFIRMED}" rendered="#{beanHelper.user.userAccountStatus == UserAccountStatus.UNCONFIRMED}" />
+                                               <h:outputText value="#{msg.ERROR_CANNOT_UN_LOCK_USER_ACCOUNT_UNCONFIRMED}" rendered="#{beanHelper.user.userAccountStatus == 'UNCONFIRMED'}" />
                                        </div>
                                </div>
                        </h:form>