]> git.mxchange.org Git - jjobs-war.git/blob - web/admin/contact_business/admin_contact_business_list.xhtml
Please cherry-pick (Massive rewrite):
[jjobs-war.git] / web / admin / contact_business / admin_contact_business_list.xhtml
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html
3         lang="#{localizationController.language}" xml:lang="#{localizationController.language}"
4         xmlns="http://www.w3.org/1999/xhtml"
5         xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
6         xmlns:h="http://xmlns.jcp.org/jsf/html"
7         xmlns:f="http://xmlns.jcp.org/jsf/core"
8         >
9
10         <ui:composition template="/WEB-INF/templates/admin/admin_base.tpl">
11                 <ui:define name="admin_title">
12                         <h:outputText value="#{msg.PAGE_TITLE_ADMIN_LIST_CONTACT_BUSINESS}" />
13                 </ui:define>
14
15                 <ui:define name="content_header">
16                         <h:outputText value="#{msg.CONTENT_TITLE_ADMIN_LIST_CONTACT_BUSINESS}" />
17                 </ui:define>
18
19                 <ui:define name="content">
20                         <ui:fragment rendered="#{adminBusinessDataController.allBusinessContacts().isEmpty()}">
21                                 <ui:include src="/WEB-INF/templates/generic/message_box.tpl">
22                                         <ui:param name="message" value="#{msg.ADMIN_CONTACT_BUSINESS_LIST_EMPTY}" />
23                                         <ui:param name="styleClass" value="errors" />
24                                 </ui:include>
25                         </ui:fragment>
26
27                         <h:dataTable id="table_list_business_contacts" var="businessContact" value="#{adminBusinessDataController.allBusinessContacts()}" styleClass="table_full" headerClass="table_header_column" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_CONTACT_BUSINESS}" rendered="#{not adminBusinessDataController.allBusinessContacts().isEmpty()}">
28                                 <h:column>
29                                         <f:facet name="header">
30                                                 <h:outputText value="#{msg.ADMIN_CONTACT_BUSINESS_ID}" />
31                                         </f:facet>
32
33                                         <h:link outcome="admin_show_contact_business" title="#{msg.ADMIN_LINK_SHOW_BUSINESS_CONTACT_DATA_TITLE}" value="#{businessContact.businessDataId}">
34                                                 <f:param name="businessDataId" value="#{businessContact.businessDataId}" />
35                                         </h:link>
36                                 </h:column>
37
38                                 <h:column>
39                                         <f:facet name="header">
40                                                 <h:outputText value="#{msg.ADMIN_CONTACT_BUSINESS_OWNER_ID}" />
41                                         </f:facet>
42
43                                         <h:link outcome="admin_show_user" title="#{msg.ADMIN_LINK_SHOW_CONTACT_BUSINESS_OWNER_USER_TITLE}" value="#{businessContact.contactCompanyUserOwner.userId}" rendered="#{not empty businessContact.contactCompanyUserOwner}" />
44
45                                         <h:link outcome="admin_assign_contact_business_owner" title="#{msg.ADMIN_LINK_ASSIGN_CONTACT_BUSINESS_OWNER_USER_TITLE}" value="#{msg[ADMIN_LINK_ASSIGN_CONTACT_BUSINESS_OWNER_USER]}" rendered="#{empty businessContact.contactCompanyUserOwner}" />
46                                 </h:column>
47
48                                 <h:column>
49                                         <f:facet name="header">
50                                                 <h:outputText value="#{msg.ADMIN_CONTACT_BUSINESS_COMPANY_NAME}" />
51                                         </f:facet>
52
53                                         <h:outputText value="#{businessContact.companyName}&nbsp;#{businessContact.companyLegalStatus}" />
54                                 </h:column>
55
56                                 <h:column>
57                                         <f:facet name="header">
58                                                 <h:outputText value="#{msg.ADMIN_CONTACT_BUSINESS_CONTACT_PERSON}" />
59                                         </f:facet>
60
61                                         <h:link outcome="admin_show_business_employee" title="#{msg.ADMIN_LINK_SHOW_CONTACT_BUSINESS_CONTACT_PERSON_TITLE}" value="#{businessContact.companyContact.employeeId}" rendered="#{not empty businessContact.companyContact}" />
62
63                                         <h:link outcome="admin_assign_contact_business_contact" title="#{msg.ADMIN_LINK_ASSIGN_CONTACT_BUSINESS_CONTACT_PERSON_TITLE}" value="#{msg[ADMIN_LINK_ASSIGN_CONTACT_BUSINESS_CONTACT_PERSON]}" rendered="#{empty businessContact.companyContact}" />
64                                 </h:column>
65
66                                 <h:column>
67                                         <f:facet name="header">
68                                                 <h:outputText value="#{msg.ADMIN_CONTACT_BUSINESS_CREATED}" />
69                                         </f:facet>
70
71                                         <h:outputText id="contactCreated" value="#{businessContact.contactCreated.time}">
72                                                 <f:convertDateTime for="contactCreated" type="both" timeStyle="short" dateStyle="short" />
73                                         </h:outputText>
74                                 </h:column>
75                         </h:dataTable>
76
77                         <h:form id="form_admin_add_contact_business">
78                                 <h:panelGroup styleClass="table_medium" layout="block">
79                                         <div class="table_header">
80                                                 <h:outputText value="#{msg.ADMIN_ADD_CONTACT_BUSINESS_TITLE}" />
81                                         </div>
82
83                                         <div class="para">
84                                                 <h:outputText value="#{msg.ADMIN_ADD_CONTACT_BUSINESS_MINIMUM_DATA}" />
85                                         </div>
86
87                                         <ui:include src="/WEB-INF/templates/admin/contact_business/admin_form_contact_business_data.tpl" />
88
89                                         <div class="table_footer">
90                                                 <h:commandButton styleClass="reset right_space" type="reset" value="#{msg.BUTTON_RESET_FORM}" />
91                                                 <h:commandButton styleClass="submit" type="submit" id="add_contact" value="#{msg.BUTTON_ADMIN_CONTINUE_BUSINESS_CONTACT_PERSON}" action="#{adminBusinessDataController.addBusinessBasicData()}" />
92                                         </div>
93                                 </h:panelGroup>
94                         </h:form>
95                 </ui:define>
96         </ui:composition>
97 </html>