]> git.mxchange.org Git - jjobs-war.git/blob - web/admin/contact/unlink/admin_contact_mobile_unlink.xhtml
Please cherry-pick:
[jjobs-war.git] / web / admin / contact / unlink / admin_contact_mobile_unlink.xhtml
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <ui:composition
3         template="/WEB-INF/templates/admin/admin_base.tpl"
4         xmlns="http://www.w3.org/1999/xhtml"
5         xmlns:core="http://mxchange.org/jsf/core/widgets"
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         xmlns:p="http://primefaces.org/ui"
10         >
11
12         <ui:define name="metadata">
13                 <f:metadata>
14                         <f:viewParam
15                                 name="mobileId"
16                                 value="#{beanHelper.mobileNumber}"
17                                 converter="MobileNumberConverter"
18                                 required="true"
19                                 requiredMessage="#{msg.ERROR_PARAMETER_PHONE_ID_NOT_SET}"
20                                 converterMessage="#{msg.PARAMETER_PHONE_ID_INVALID}"
21                                 />
22                         <f:viewParam
23                                 name="contactId"
24                                 value="#{beanHelper.contact}"
25                                 converter="ContactConverter"
26                                 required="true"
27                                 requiredMessage="#{msg.ERROR_PARAMETER_CONTACT_ID_NOT_SET}"
28                                 converterMessage="#{msg.PARAMETER_CONTACT_ID_INVALID}"
29                                 />
30                 </f:metadata>
31         </ui:define>
32
33         <ui:define name="document_admin_title">
34                 <h:outputText value="#{msg.PAGE_TITLE_ADMIN_UNLINK_CONTACT_MOBILE_NUMBER}" />
35         </ui:define>
36
37         <ui:define name="content_header">
38                 <h:outputText value="#{msg.CONTENT_TITLE_ADMIN_UNLINK_CONTACT_MOBILE_NUMBER}" />
39         </ui:define>
40
41         <ui:define name="content">
42                 <h:form rendered="#{not empty beanHelper.mobileNumber and not empty beanHelper.contact and beanHelper.contact.contactMobileNumber == beanHelper.mobileNumber}">
43                         <h:panelGroup styleClass="table" layout="block">
44                                 <div class="table-header">
45                                         <h:outputText value="#{msg.ADMIN_UNLINK_CONTACT_MOBILE_NUMBER_TITLE}" />
46                                 </div>
47
48                                 <div class="para">
49                                         <ui:include src="/WEB-INF/templates/admin/contact/admin_contact_data_mini.tpl" />
50                                 </div>
51
52                                 <div class="para">
53                                         <p:link
54                                                 outcome="admin_show_contact"
55                                                 value="#{msg.ADMIN_SHOW_FULL_CONTACT_DATA}"
56                                                 title="#{msg.ADMIN_SHOW_FULL_CONTACT_DATA_TITLE}"
57                                                 >
58                                                 <f:param name="contactId" value="#{beanHelper.contact.contactId}" />
59                                         </p:link>
60                                 </div>
61
62                                 <div class="para">
63                                         <core:outputAdminMobilePanelGrid mobileNumber="#{beanHelper.mobileNumber}" contact="#{beanHelper.contact}" renderShowLink="false" showAdminDropdownMenu="false" />
64                                 </div>
65
66                                 <p:commandButton
67                                         type="submit"
68                                         value="#{msg.BUTTON_ADMIN_UNLINK_MOBILE_NUMBER}"
69                                         action="#{adminContactPhoneController.unlinkMobileContactData()}"
70                                         />
71                         </h:panelGroup>
72                 </h:form>
73
74                 <h:outputFormat styleClass="alert-danger" value="#{msg.ERROR_MOBILE_NUMBER_CONTACT_NOT_LINKED}" rendered="#{not empty beanHelper.mobileNumber and not empty beanHelper.contact and beanHelper.contact.contactMobileNumber != beanHelper.mobileNumber}">
75                         <f:param value="#{beanHelper.mobileNumber.mobileId}" />
76                         <f:param value="#{beanHelper.contact.contactId}" />
77                 </h:outputFormat>
78         </ui:define>
79 </ui:composition>