]> git.mxchange.org Git - jjobs-war.git/blob - web/admin/contact/unlink/admin_contact_landline_unlink.xhtml
Please cherry-pick:
[jjobs-war.git] / web / admin / contact / unlink / admin_contact_landline_unlink.xhtml
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <ui:composition template="/WEB-INF/templates/admin/admin_base.tpl"
3                                 xmlns="http://www.w3.org/1999/xhtml"
4                                 xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
5                                 xmlns:h="http://xmlns.jcp.org/jsf/html"
6                                 xmlns:f="http://xmlns.jcp.org/jsf/core">
7
8         <ui:define name="metadata">
9                 <f:metadata>
10                         <f:viewParam name="phoneId" value="#{beanHelper.landLineNumber}" converter="LandLineNumberConverter" required="true" requiredMessage="#{msg.ERROR_PARAMETER_PHONE_ID_NOT_SET}" converterMessage="#{msg.PARAMETER_PHONE_ID_INVALID}" />
11                         <f:viewParam name="contactId" value="#{beanHelper.contact}" converter="ContactConverter" required="true" requiredMessage="#{msg.ERROR_PARAMETER_CONTACT_ID_NOT_SET}" converterMessage="#{msg.PARAMETER_CONTACT_ID_INVALID}" />
12                 </f:metadata>
13         </ui:define>
14
15         <ui:define name="admin_title">
16                 <h:outputText value="#{msg.PAGE_TITLE_ADMIN_UNLINK_CONTACT_LAND_LINE_NUMBER}" />
17         </ui:define>
18
19         <ui:define name="content_header">
20                 <h:outputText value="#{msg.CONTENT_TITLE_ADMIN_UNLINK_CONTACT_LAND_LINE_NUMBER}" />
21         </ui:define>
22
23         <ui:define name="content">
24                 <h:form id="form_unlink_contact_landline" rendered="#{not empty beanHelper.landLineNumber and not empty beanHelper.contact and beanHelper.contact.contactLandLineNumber == beanHelper.landLineNumber}">
25                         <h:panelGroup styleClass="table" layout="block">
26                                 <div class="table_header">
27                                         <h:outputText value="#{msg.ADMIN_UNLINK_CONTACT_LAND_LINE_NUMBER_TITLE}" />
28                                 </div>
29
30                                 <div class="para">
31                                         <ui:include src="/WEB-INF/templates/admin/contact/admin_contact_data_mini.tpl" />
32                                 </div>
33
34                                 <div class="para">
35                                         <h:link outcome="admin_show_contact" value="#{msg.ADMIN_SHOW_FULL_CONTACT_DATA}">
36                                                 <f:param name="contactId" value="#{beanHelper.contact.contactId}" />
37                                         </h:link>
38                                 </div>
39
40                                 <div class="para">
41                                         <ui:include src="/WEB-INF/templates/admin/landline/admin_landline_data.tpl">
42                                                 <ui:param name="isShowPage" value="#{false}" />
43                                                 <ui:param name="showAdminLinks" value="#{false}" />
44                                         </ui:include>
45                                 </div>
46
47                                 <div class="table_footer">
48                                         <h:commandButton styleClass="unlink_button" type="submit" id="unlink_landline" value="#{msg.BUTTON_ADMIN_UNLINK_LAND_LINE_NUMBER}" action="#{adminContactPhoneController.unlinkLandLineContactData()}" />
49                                 </div>
50                         </h:panelGroup>
51                 </h:form>
52
53                 <ui:fragment rendered="#{empty beanHelper.landLineNumber}">
54                         <ui:include src="/WEB-INF/templates/messages/message_box.tpl">
55                                 <ui:param name="message" value="#{msg.ERROR_BEAN_HELPER_LAND_LINE_NUMBER_NOT_SET}" />
56                                 <ui:param name="styleClass" value="errors" />
57                         </ui:include>
58                 </ui:fragment>
59
60                 <ui:fragment rendered="#{empty beanHelper.contact}">
61                         <ui:include src="/WEB-INF/templates/messages/message_box.tpl">
62                                 <ui:param name="message" value="#{msg.ERROR_BEAN_HELPER_CONTACT_NOT_SET}" />
63                                 <ui:param name="styleClass" value="errors" />
64                         </ui:include>
65                 </ui:fragment>
66
67                 <h:outputFormat styleClass="errors" value="#{msg.ERROR_LAND_LINE_NUMBER_CONTACT_NOT_LINKED}" rendered="#{not empty beanHelper.landLineNumber and not empty beanHelper.contact and beanHelper.contact.contactLandLineNumber != beanHelper.landLineNumber}">
68                         <f:param value="#{beanHelper.landLineNumber.phoneId}" />
69                         <f:param value="#{beanHelper.contact.contactId}" />
70                 </h:outputFormat>
71         </ui:define>
72 </ui:composition>