]> git.mxchange.org Git - jjobs-war.git/commitdiff
Please cherry-pick:
authorRoland Häder <roland@mxchange.org>
Sat, 24 Mar 2018 18:24:16 +0000 (19:24 +0100)
committerRoland Häder <roland@mxchange.org>
Sun, 21 Jul 2019 06:01:41 +0000 (08:01 +0200)
- f:validator is no longer working, need to use own JSF tag
  validator:employeeEmailAddressValidator which allows a second parameter
- there is no type="secret", need to be type="password"
- added p:inputTex for headquarter's company name
- added selection box for profile-mode using "new" getter in data controller
- added selection box for branch office owner (employee)
- added navigation rule from employee list to to assign branch office to
  employee
- fixed leftovers from duplication from branch office to employee/department
- added navigator="true"
- renamed employeeCompany to employeeBasicData
- reformatted p:inputText in admin_form_contact_data.tpl
- allow null profile mode (?)
- set org.jboss.weld.development=false
- registered validators.jsf.taglib.xml
- updated/changed copyright to Free Software Foundation

Signed-off-by: Roland Häder <roland@mxchange.org>
17 files changed:
src/java/log4j2.xml [new file with mode: 0644]
web/WEB-INF/beans.xml
web/WEB-INF/faces-config.xml
web/WEB-INF/links.jsf.taglib.xml
web/WEB-INF/resources/tags/admin/form_data/contact/admin_form_contact_data.tpl
web/WEB-INF/resources/tags/admin/form_data/user/admin_form_user_data.tpl
web/WEB-INF/resources/tags/country/form_data/form_country_selector.tpl
web/WEB-INF/resources/tags/table_rows/user_profile_mode_table_row.tpl
web/WEB-INF/templates/admin/basic_data/admin_form_basic_data.tpl
web/WEB-INF/templates/admin/branch_office/admin_form_branch_office_data.tpl
web/WEB-INF/templates/admin/branch_office/admin_form_branch_opening_time.tpl
web/WEB-INF/templates/admin/employee/admin_form_employee_data.tpl
web/WEB-INF/templates/admin/headquarter/admin_form_headquarter.tpl
web/WEB-INF/templates/admin/headquarter/admin_form_headquarter_opening_time.tpl
web/WEB-INF/templates/admin/opening_time/admin_form_opening_time.tpl
web/WEB-INF/web.xml
web/WEB-INF/widgets.jsf.taglib.xml

diff --git a/src/java/log4j2.xml b/src/java/log4j2.xml
new file mode 100644 (file)
index 0000000..90439ed
--- /dev/null
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (C) 2016 - 2018 Free Software Foundation
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU Affero General Public License as
+published by the Free Software Foundation, either version 3 of the
+License, or (at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU Affero General Public License for more details.
+
+You should have received a copy of the GNU Affero General Public License
+along with this program.  If not, see <http://www.gnu.org/licenses/>.
+-->
+<Configuration status="INFO">
+       <Appenders>
+               <Console name="STDOUT" target="SYSTEM_OUT">
+                       <PatternLayout pattern="%d %-5p [%t] %C{2} (%F:%L) - %m%n"/>
+               </Console>
+       </Appenders>
+       <Loggers>
+               <Root level="trace">
+                       <AppenderRef ref="STDOUT" level="TRACE"/>
+               </Root>
+       </Loggers>
+</Configuration>
index 604563e42f59448924cb5ce7458e8e34eabe8cc1..eca5bf30a9767b38aee6e9e00857c8fb320add17 100644 (file)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
-Copyright (C) 2016, 2017 Roland Häder
+Copyright (C) 2016 - 2018 Free Software Foundation
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
index 116ae73b366b4cac68d36c5e8059101c70a186c5..90b934d2cd4479aaaa84e37ebb7afdbce50d6de2 100644 (file)
                        <from-outcome>user_contact_data_saved</from-outcome>
                        <to-view-id>/user/login_contact_data_saved.xhtml</to-view-id>
                </navigation-case>
-               <navigation-case>
-                       <from-outcome>admin_delete_product</from-outcome>
-                       <to-view-id>/admin/admin_product_delete.xhtml</to-view-id>
-               </navigation-case>
        </navigation-rule>
        <navigation-rule>
                <from-view-id>/user/login_user_change_personal_data.xhtml</from-view-id>
                        <to-view-id>/admin/branch_office/admin_branch_office_show.xhtml</to-view-id>
                </navigation-case>
                <navigation-case>
-                       <from-outcome>admin_assign_employee_owner</from-outcome>
+                       <from-outcome>admin_assign_user_owner</from-outcome>
                        <to-view-id>/admin/employee/admin_assign_employee_user.xhtml</to-view-id>
                </navigation-case>
+               <navigation-case>
+                       <from-outcome>admin_assign_branch_office</from-outcome>
+                       <to-view-id>/admin/employee/admin_assign_employee_branch_office.xhtml</to-view-id>
+               </navigation-case>
        </navigation-rule>
        <navigation-rule>
                <from-view-id>/admin/opening_time/admin_opening_time_list.xhtml</from-view-id>
index 0598de75efcc32f9b2e602ebf0e84ca613561847..f959474a847113b6eb8cd4563a0c1922ecf4f6dc 100644 (file)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
-Copyright (C) 2017 Roland Häder
+Copyright (C) 2017, 2018 Free Software Foundation
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU Affero General Public License as
index d29069f09ee57db016c70b2684c756087af3aa74..ee0a6e3eb1c578931bc1b0805412aee2fbd71bbb 100644 (file)
@@ -2,6 +2,7 @@
 <ui:composition
        xmlns="http://www.w3.org/1999/xhtml"
        xmlns:core="http://mxchange.org/jsf/core/widgets"
+       xmlns:validator="http://mxchange.org/jsf/core/validators"
        xmlns:f="http://xmlns.jcp.org/jsf/core"
        xmlns:h="http://xmlns.jcp.org/jsf/html"
        xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
                        <core:outputPersonalTitleSelectionBox targetController="#{adminContactController}" allowEmptyRequiredData="#{allowEmptyRequiredData}" />
 
                        <p:outputLabel for="firstName" value="#{msg.ADMIN_PERSONAL_DATA_FIRST_NAME}" />
-                       <p:inputText id="firstName" size="10" maxlength="255" value="#{adminContactController.firstName}" />
+                       <p:inputText
+                               id="firstName"
+                               size="10"
+                               maxlength="255"
+                               value="#{adminContactController.firstName}"
+                               required="#{empty allowEmptyRequiredData or not allowEmptyRequiredData}"
+                               requiredMessage="#{msg.ADMIN_CONTACT_DATA_FIRST_NAME_REQUIRED}"
+                               />
 
                        <p:outputLabel for="title" value="#{msg.ADMIN_PERSONAL_DATA_TITLE}" />
-                       <p:inputText id="title" size="5" maxlength="255" value="#{adminContactController.academicTitle}" />
+                       <p:inputText
+                               id="title"
+                               size="5"
+                               maxlength="255"
+                               value="#{adminContactController.academicTitle}"
+                               />
 
                        <p:outputLabel for="familyName" value="#{msg.ADMIN_PERSONAL_DATA_FAMILY_NAME}" />
-                       <p:inputText id="familyName" size="10" maxlength="255" value="#{adminContactController.familyName}" />
+                       <p:inputText
+                               id="familyName"
+                               size="10"
+                               maxlength="255"
+                               value="#{adminContactController.familyName}"
+                               required="#{empty allowEmptyRequiredData or not allowEmptyRequiredData}"
+                               requiredMessage="#{msg.ADMIN_CONTACT_DATA_FAMILY_NAME_REQUIRED}"
+                               />
 
                        <p:outputLabel for="street" value="#{msg.ADMIN_DATA_STREET_NAME}" />
-                       <p:inputText id="street" size="20" maxlength="255" value="#{adminContactController.street}" />
+                       <p:inputText
+                               id="street"
+                               size="20"
+                               maxlength="255"
+                               value="#{adminContactController.street}"
+                               />
 
                        <p:outputLabel for="houseNumber" value="#{msg.ADMIN_DATA_HOUSE_NUMBER}" />
-                       <p:inputText id="houseNumber" size="3" maxlength="5" value="#{adminContactController.houseNumber}" validatorMessage="#{msg.ENTERED_HOUSE_NUMBER_INVALID}">
+                       <p:inputText
+                               id="houseNumber"
+                               size="3"
+                               maxlength="5"
+                               value="#{adminContactController.houseNumber}"
+                               validatorMessage="#{msg.ENTERED_HOUSE_NUMBER_INVALID}"
+                               >
                                <f:validateLongRange for="houseNumber" minimum="1" maximum="500" />
                        </p:inputText>
 
                        <p:inputText id="city" size="10" maxlength="255" value="#{adminContactController.city}" />
 
                        <p:outputLabel for="country" value="#{msg.ADMIN_SELECT_COUNTRY}" />
-                       <core:outputCountrySelector id="country" value="#{adminContactController.contactCountry}" />
+                       <core:outputCountrySelector
+                               id="country"
+                               value="#{adminContactController.contactCountry}"
+                               required="#{empty allowEmptyRequiredData or not allowEmptyRequiredData}"
+                               requiredMessage="#{msg.ADMIN_SELECT_CONTACT_COUNTRY_REQUIRED}"
+                               />
 
                        <p:outputLabel for="landLineCountry" value="#{msg.ADMIN_PERSONAL_DATA_PHONE_NUMBER}" />
                        <core:inputLandLineNumberPanelGrid targetController="#{adminContactController}" />
 
                        <p:outputLabel for="emailAddress" value="#{msg.DATA_EMAIL_ADDRESS}" />
                        <p:inputText id="emailAddress" size="20" maxlength="255" value="#{adminContactController.emailAddress}" validatorMessage="#{msg.ENTERED_EMAIL_ADDRESS_IS_INVALID}">
-                               <f:validator for="emailAddress" validatorId="EmailAddressValidator" />
-                               <f:attribute name="allowEmptyValue" value="#{allowEmptyRequiredData}" />
+                               <validator:emailAddressValidator allowEmptyRequiredData="#{allowEmptyRequiredData}" />
                        </p:inputText>
 
                        <p:outputLabel for="contactBirthday" value="#{msg.ADMIN_PERSONAL_DATA_BIRTHDAY}" />
-                       <p:calendar id="contactBirthday" value="#{contactController.birthday}" />
+                       <p:calendar
+                               id="contactBirthday"
+                               value="#{contactController.birthday}"
+                               title="#{msg.ADMIN_PERSONAL_DATA_BIRTHDAY_TITLE}"
+                               pattern="#{msg.DATE_PATTERN}"
+                               navigator="true"
+                               />
 
                        <p:outputLabel for="contactComment" value="#{msg.ADMIN_PERSONAL_DATA_COMMENT}" />
                        <p:inputTextarea id="contactComment" value="#{adminContactController.comment}" rows="7" cols="35" />
index a986d6cd04d271a416df4eef890b68e825a56ecc..08afc952d9ab55920e3ed9e6c987780d7ac79998 100644 (file)
                                <p:inputText id="userName" size="20" maxlength="255" value="#{adminUserController.userName}" required="true" requiredMessage="#{msg.ADMIN_USER_NAME_IS_REQUIRED}" />
 
                                <p:outputLabel for="userPassword" value="#{msg.ADMIN_USER_DATA_ENTER_PASSWORD}" />
-                               <p:inputText type="secret" id="userPassword" size="10" maxlength="255" value="#{adminUserController.userPassword}" />
+                               <p:inputText type="password" id="userPassword" size="10" maxlength="255" value="#{adminUserController.userPassword}" />
 
                                <p:outputLabel for="userPasswordRepeat" value="#{msg.ADMIN_USER_DATA_ENTER_PASSWORD_REPEAT}" />
-                               <p:inputText type="secret" id="userPasswordRepeat" size="10" maxlength="255" value="#{adminUserController.userPasswordRepeat}" />
+                               <p:inputText type="password" id="userPasswordRepeat" size="10" maxlength="255" value="#{adminUserController.userPasswordRepeat}" />
 
                                <p:outputLabel for="userMustChangePassword" value="#{msg.ADMIN_USER_MUST_CHANGE_PASSWORD}" />
                                <p:selectBooleanCheckbox id="userMustChangePassword" value="#{adminUserController.userMustChangePassword}" />
+
+                               <p:outputLabel for="userProfileMode" value="#{msg.ADMIN_SELECT_USER_PROFILE_MODE}" />
+                               <p:selectOneMenu
+                                       id="userProfileMode"
+                                       value="#{adminUserController.userProfileMode}"
+                                       filter="true"
+                                       filterMatchMode="contains"
+                                       >
+                                       <f:selectItem itemValue="#{null}" itemLabel="#{msg.PLEASE_SELECT}" noSelectionOption="true" itemDisabled="true" />
+                                       <f:selectItems value="#{dataController.profileModes}" var="profileMode" itemValue="#{profileMode}" itemLabel="#{msg[profileMode.messageKey]}" />
+                               </p:selectOneMenu>
                        </p:panelGrid>
                </p:fieldset>
 
index 720312274eb738b5d8a451d21e98f02c41b4950e..14ff97a745b59c6f70f02bc52abdda8c9f257ff2 100644 (file)
@@ -2,7 +2,6 @@
 <ui:composition
        xmlns="http://www.w3.org/1999/xhtml"
        xmlns:f="http://xmlns.jcp.org/jsf/core"
-       xmlns:h="http://xmlns.jcp.org/jsf/html"
        xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
        xmlns:p="http://primefaces.org/ui">
 
index 2f3f6f1807cfd2bad8d3ec5326e86d3ef01cbdac..32b9946f0be555c950e45d96369c7d451d40a733 100644 (file)
@@ -14,7 +14,8 @@
                        filter="true"
                        filterMatchMode="contains"
                        >
-                       <f:selectItems value="#{profileModeController.allProfileModes()}" var="mode" itemValue="#{mode}" itemLabel="#{msg[mode.messageKey]}" />
+                       <f:selectItem itemValue="#{null}" itemLabel="#{msg.PLEASE_SELECT}" noSelectionOption="true" itemDisabled="true" />
+                       <f:selectItems value="#{dataController.profileModes}" var="profileMode" itemValue="#{profileMode}" itemLabel="#{msg[profileMode.messageKey]}" />
                </p:selectOneMenu>
 
                <p:message for="personalTitle" />
index 5f7c79a44a84394abc7c599954f392e5034f3f83..d9cfe262ed16ce7602c9dd02f3d7f7636b9f3a09 100644 (file)
@@ -5,6 +5,7 @@
 <ui:composition
        xmlns="http://www.w3.org/1999/xhtml"
        xmlns:core="http://mxchange.org/jsf/core/widgets"
+       xmlns:validator="http://mxchange.org/jsf/core/validators"
        xmlns:f="http://xmlns.jcp.org/jsf/core"
        xmlns:h="http://xmlns.jcp.org/jsf/html"
        xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
                                        required="true"
                                        requiredMessage="#{msg.ADMIN_BASIC_DATA_COMPANY_NAME_REQUIRED}"
                                        >
-                                       <f:validator validatorId="CompanyNameValidator" />
+                                       <f:validator validatorId="BasicDataCompanyNameValidator" />
                                        <f:attribute name="checkExisting" value="false" />
                                </p:inputText>
 
                                <p:outputLabel for="companyEmailAddress" value="#{msg.ADMIN_BASIC_DATA_COMPANY_EMAIL_ADDRESS}" />
                                <p:inputText id="companyEmailAddress" size="20" maxlength="255" value="#{adminBasicCompanyDataController.companyEmailAddress}" validatorMessage="#{msg.ENTERED_EMAIL_ADDRESS_IS_INVALID}">
-                                       <f:validator validatorId="BasicDataEmailAddressValidator" />
-                                       <f:attribute name="allowEmptyValue" value="true" />
+                                       <validator:basicDataEmailAddressValidator allowEmptyRequiredData="true" />
                                </p:inputText>
 
                                <p:outputLabel for="companyLogo" value="#{msg.ADMIN_SELECT_BASIC_DATA_COMPANY_LOGO}" />
@@ -40,8 +40,7 @@
 
                                <p:outputLabel for="companyWebsiteUrl" value="#{msg.ADMIN_BASIC_DATA_COMPANY_WEBSITE_URL}" />
                                <p:inputText id="companyWebsiteUrl" size="30" maxlength="200" value="#{adminBasicCompanyDataController.companyWebsiteUrl}" validatorMessage="#{msg.URL_NOT_MATCHING_REGULAR_EXPRESSION}">
-                                       <f:validator validatorId="UrlValidator" />
-                                       <f:attribute name="allowEmptyValue" value="true" />
+                                       <validator:urlValidator allowEmptyRequiredData="true" />
                                </p:inputText>
 
                                <p:outputLabel for="companyUserOwner" value="#{msg.ADMIN_SELECT_BASIC_DATA_COMPANY_USER_OWNER}" />
@@ -65,7 +64,7 @@
                                        >
                                        <f:converter converterId="EmployeeConverter" />
                                        <f:selectItem itemValue="#{null}" itemLabel="#{msg.NONE_SELECTED}" />
-                                       <f:selectItems value="#{employeeController.allEmployees()}" var="companyHeadquarter" itemValue="#{companyEmployee}" itemLabel="#{companyEmployee.foo}" />
+                                       <f:selectItems value="#{employeeController.allEmployees()}" var="companyEmployee" itemValue="#{companyEmployee}" itemLabel="#{beanHelper.renderEmployee(companyEmployee)}" />
                                </p:selectOneMenu>
 
                                <p:outputLabel for="companyFounder" value="#{msg.ADMIN_SELECT_BASIC_DATA_COMPANY_FOUNDER}" />
@@ -77,7 +76,7 @@
                                        >
                                        <f:converter converterId="EmployeeConverter" />
                                        <f:selectItem itemValue="#{null}" itemLabel="#{msg.NONE_SELECTED}" />
-                                       <f:selectItems value="#{employeeController.allEmployees()}" var="companyHeadquarter" itemValue="#{companyEmployee}" itemLabel="#{companyEmployee.foo}" />
+                                       <f:selectItems value="#{employeeController.allEmployees()}" var="companyEmployee" itemValue="#{companyEmployee}" itemLabel="#{beanHelper.renderEmployee(companyEmployee)}" />
                                </p:selectOneMenu>
 
                                <p:outputLabel for="companyHeadquarter" value="#{msg.ADMIN_SELECT_BASIC_DATA_COMPANY_HEADQUARTER}" />
index c7ad682b5a3b438983802baf7cfda7a2a3c2b9f8..e4fd7bd2b10887d28f21ae54e5fc0fedc70d182a 100644 (file)
@@ -5,6 +5,7 @@
 <ui:composition
        xmlns="http://www.w3.org/1999/xhtml"
        xmlns:core="http://mxchange.org/jsf/core/widgets"
+       xmlns:validator="http://mxchange.org/jsf/core/validators"
        xmlns:f="http://xmlns.jcp.org/jsf/core"
        xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
        xmlns:p="http://primefaces.org/ui">
                                >
                                <f:converter converterId="EmployeeConverter" />
                                <f:selectItem itemValue="#{null}" itemLabel="#{msg.NONE_SELECTED}" />
-                               <f:selectItems value="#{employeeController.allEmployees()}" var="companyHeadquarter" itemValue="#{companyEmployee}" itemLabel="#{companyEmployee.foo}" />
+                               <f:selectItems value="#{employeeController.allEmployees()}" var="companyEmployee" itemValue="#{companyEmployee}" itemLabel="#{beanHelper.renderEmployee(companyEmployee)}" />
+                       </p:selectOneMenu>
+
+                       <p:outputLabel for="branchOwner" value="#{msg.ADMIN_ASSIGN_BRANCH_OFFICE_OWNER}" />
+                       <p:selectOneMenu
+                               id="branchOwner"
+                               value="#{adminBranchOfficeController.branchOwner}"
+                               filter="true"
+                               filterMatchMode="contains"
+                               >
+                               <f:converter converterId="EmployeeConverter" />
+                               <f:selectItem itemValue="#{null}" itemLabel="#{msg.NONE_SELECTED}" />
+                               <f:selectItems value="#{employeeController.allEmployees()}" var="companyEmployee" itemValue="#{companyEmployee}" itemLabel="#{beanHelper.renderEmployee(companyEmployee)}" />
                        </p:selectOneMenu>
 
                        <p:outputLabel for="branchUserOwner" value="#{msg.ADMIN_ASSIGN_BRANCH_OFFICE_USER_OWNER}" />
@@ -51,8 +64,7 @@
 
                        <p:outputLabel for="branchEmailAddress" value="#{msg.ADMIN_ENTER_BRANCH_OFFICE_EMAIL_ADDRESS}" />
                        <p:inputText id="branchEmailAddress" size="20" maxlength="255" value="#{adminBranchOfficeController.branchEmailAddress}" validatorMessage="#{msg.ENTERED_EMAIL_ADDRESS_IS_INVALID}">
-                               <f:validator validatorId="BranchOfficeEmailAddressValidator" />
-                               <f:attribute name="allowEmptyValue" value="true" />
+                               <validator:basicDataEmailAddressValidator allowEmptyRequiredData="true" />
                        </p:inputText>
 
                        <p:outputLabel for="landLineCountry" value="#{msg.ADMIN_ENTER_BRANCH_OFFICE_LAND_LINE_NUMBER}" />
                                <f:validateLongRange for="branchHouseNumber" minimum="1" maximum="500" />
                        </p:inputText>
 
+                       <p:outputLabel for="branchLastHouseNumber" value="#{msg.ADMIN_DATA_LAST_HOUSE_NUMBER}" />
+                       <p:inputText id="branchLastHouseNumber" size="3" maxlength="5" value="#{adminBranchOfficeController.branchLastHouseNumber}" validatorMessage="#{msg.ENTERED_HOUSE_NUMBER_INVALID}">
+                               <f:validateLongRange for="branchLastHouseNumber" minimum="1" maximum="500" />
+                       </p:inputText>
+
+                       <p:outputLabel for="branchHouseNumberExtension" value="#{msg.ADMIN_DATA_HOUSE_NUMBER_EXTENSION}" />
+                       <p:inputText id="branchHouseNumberExtension" size="1" maxlength="255" value="#{adminBranchOfficeController.branchHouseNumberExtension}" validatorMessage="#{msg.ENTERED_HOUSE_NUMBER_INVALID}" />
+
                        <p:outputLabel for="branchStore" value="#{msg.ADMIN_ENTER_DATA_STORE}" />
                        <p:inputText id="branchStore" size="3" maxlength="5" value="#{adminBranchOfficeController.branchStore}" validatorMessage="#{msg.ENTERED_STORE_INVALID}">
                                <f:validateLongRange for="branchStore" minimum="-5" maximum="200" />
index b581c709a50f5ddba3a2502432cb31172ab61b97..a3b1a93c8790d410119dadc607db3761d6476721 100644 (file)
@@ -46,8 +46,9 @@
                                value="#{adminBranchOfficeController.openingStartTime}"
                                pattern="HH:mm"
                                timeOnly="true"
-                               required="true"
                                stepMinute="5"
+                               navigator="true"
+                               required="true"
                                requiredMessage="#{msg.ADMIN_START_TIME_REQUIRED}"
                                />
 
@@ -56,8 +57,9 @@
                                value="#{adminBranchOfficeController.openingEndTime}"
                                pattern="HH:mm"
                                timeOnly="true"
-                               required="true"
                                stepMinute="5"
+                               navigator="true"
+                               required="true"
                                requiredMessage="#{msg.ADMIN_END_TIME_REQUIRED}"
                                />
                </p:panelGrid>
index d5747d89b22566c10cb6a53cd8572bcd7efc1289..2cc22003942cf2a1a4d2e11e3887a2fb718c9755 100644 (file)
@@ -2,6 +2,7 @@
 <ui:composition
        xmlns="http://www.w3.org/1999/xhtml"
        xmlns:core="http://mxchange.org/jsf/core/widgets"
+       xmlns:validator="http://mxchange.org/jsf/core/validators"
        xmlns:f="http://xmlns.jcp.org/jsf/core"
        xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
        xmlns:p="http://primefaces.org/ui">
        -->
        <p:fieldset legend="#{msg.ADMIN_EMPLOYEE_GENERAL_LEGEND}">
                <p:panelGrid layout="grid" columns="2" columnClasses="ui-grid-col-4,ui-grid-col-8" styleClass="table table-full ui-noborder">
-                       <p:outputLabel for="employeeCompany" value="#{msg.ADMIN_ASSIGN_EMPLOYEE_COMPANY}" />
+                       <p:outputLabel for="employeeBasicData" value="#{msg.ADMIN_ASSIGN_EMPLOYEE_COMPANY}" />
                        <p:selectOneMenu
-                               id="employeeCompany"
-                               value="#{adminEmployeeController.employeeCompany}"
+                               id="employeeBasicData"
+                               value="#{adminEmployeeController.employeeBasicData}"
                                filter="true"
                                filterMatchMode="contains"
                                required="true"
                                <f:selectItems value="#{branchOfficeController.allBranchOffices()}" var="branchOffice" itemValue="#{branchOffice}" itemLabel="#{beanHelper.renderBranchOffice(branchOffice)}" />
                        </p:selectOneMenu>
 
-                       <p:outputLabel for="employeePersonalContact" value="#{msg.ADMIN_ASSIGN_EMPLOYEE_PERSONAL_DATA}" />
+                       <p:outputLabel for="employeePersonalData" value="#{msg.ADMIN_ASSIGN_EMPLOYEE_PERSONAL_DATA}" />
                        <p:selectOneMenu
-                               id="employeePersonalContact"
-                               value="#{adminEmployeeController.employeePersonalContact}"
+                               id="employeePersonalData"
+                               value="#{adminEmployeeController.employeePersonalData}"
                                filter="true"
                                filterMatchMode="contains"
                                >
@@ -63,8 +64,7 @@
 
                        <p:outputLabel for="employeeEmailAddress" value="#{msg.ADMIN_ENTER_EMPLOYEE_EMAIL_ADDRESS}" />
                        <p:inputText id="employeeEmailAddress" size="20" maxlength="255" value="#{adminEmployeeController.employeeEmailAddress}" validatorMessage="#{msg.ENTERED_EMAIL_ADDRESS_IS_INVALID}">
-                               <f:validator validatorId="EmailAddressValidator" />
-                               <f:attribute name="allowEmptyValue" value="true" />
+                               <validator:employeeEmailAddressValidator allowEmptyRequiredData="true" />
                        </p:inputText>
 
                        <p:outputLabel for="employeeStaffNumber" value="#{msg.ADMIN_ENTER_EMPLOYEE_STAFF_NUMBER}" />
index 3dec21a1751ccae65c5c998a5bd09b97ce194ae4..97e6f3cddf674daf2877e2d7db9e006cc98801ce 100644 (file)
@@ -5,12 +5,26 @@
 <ui:composition
        xmlns="http://www.w3.org/1999/xhtml"
        xmlns:core="http://mxchange.org/jsf/core/widgets"
+       xmlns:validator="http://mxchange.org/jsf/core/validators"
        xmlns:f="http://xmlns.jcp.org/jsf/core"
        xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
        xmlns:p="http://primefaces.org/ui">
 
        <p:fieldset legend="#{msg.ADMIN_HEADQUARTER_LEGEND}">
                <p:panelGrid layout="grid" columns="2" columnClasses="ui-grid-col-4,ui-grid-col-8" styleClass="table table-full ui-noborder">
+                       <p:outputLabel for="headquarterCompanyName" value="#{msg.ADMIN_HEADQUARTER_COMPANY_NAME}" />
+                       <p:inputText
+                               id="headquarterCompanyName"
+                               value="#{adminHeadquarterController.headquarterCompanyName}"
+                               size="30"
+                               maxlength="200"
+                               required="true"
+                               requiredMessage="#{msg.ADMIN_HEADQUARTER_COMPANY_NAME_REQUIRED}"
+                               >
+                               <f:validator validatorId="BasicDataCompanyNameValidator" />
+                               <f:attribute name="checkExisting" value="false" />
+                       </p:inputText>
+
                        <p:outputLabel for="headquarterContactEmployee" value="#{msg.ADMIN_ASSIGN_HEADQUARTER_CONTACT_EMPLOYEE}" />
                        <p:selectOneMenu
                                id="headquarterContactEmployee"
@@ -20,7 +34,7 @@
                                >
                                <f:converter converterId="EmployeeConverter" />
                                <f:selectItem itemValue="#{null}" itemLabel="#{msg.NONE_SELECTED}" />
-                               <f:selectItems value="#{employeeController.allEmployees()}" var="companyHeadquarter" itemValue="#{companyEmployee}" itemLabel="#{companyEmployee.foo}" />
+                               <f:selectItems value="#{employeeController.allEmployees()}" var="companyEmployee" itemValue="#{companyEmployee}" itemLabel="#{beanHelper.renderEmployee(companyEmployee)}" />
                        </p:selectOneMenu>
 
                        <p:outputLabel for="headquarterUserOwner" value="#{msg.ADMIN_ASSIGN_HEADQUARTER_USER_OWNER}" />
@@ -37,8 +51,7 @@
 
                        <p:outputLabel for="headquarterEmailAddress" value="#{msg.ADMIN_ENTER_HEADQUARTER_EMAIL_ADDRESS}" />
                        <p:inputText id="headquarterEmailAddress" size="20" maxlength="255" value="#{adminHeadquarterController.headquarterEmailAddress}" validatorMessage="#{msg.ENTERED_EMAIL_ADDRESS_IS_INVALID}">
-                               <f:validator validatorId="HeadquarterEmailAddressValidator" />
-                               <f:attribute name="allowEmptyValue" value="true" />
+                               <validator:headquarterEmailAddressValidator allowEmptyRequiredData="true" />
                        </p:inputText>
 
                        <p:outputLabel for="landLineCountry" value="#{msg.ADMIN_ENTER_HEADQUARTER_LAND_LINE_NUMBER}" />
                                <f:validateLongRange for="headquarterHouseNumber" minimum="1" maximum="500" />
                        </p:inputText>
 
+                       <p:outputLabel for="headquarterHouseNumberExtension" value="#{msg.ADMIN_DATA_HOUSE_NUMBER_EXTENSION}" />
+                       <p:inputText id="headquarterHouseNumberExtension" size="1" maxlength="255" value="#{adminHeadquarterController.headquarterHouseNumberExtension}" validatorMessage="#{msg.ENTERED_HOUSE_NUMBER_INVALID}" />
+
+                       <p:outputLabel for="headquarterLastHouseNumber" value="#{msg.ADMIN_DATA_LAST_HOUSE_NUMBER}" />
+                       <p:inputText id="headquarterLastHouseNumber" size="3" maxlength="5" value="#{adminHeadquarterController.headquarterLastHouseNumber}" validatorMessage="#{msg.ENTERED_HOUSE_NUMBER_INVALID}">
+                               <f:validateLongRange for="headquarterLastHouseNumber" minimum="1" maximum="500" />
+                       </p:inputText>
+
                        <p:outputLabel for="headquarterStore" value="#{msg.ADMIN_ENTER_DATA_STORE}" />
                        <p:inputText id="headquarterStore" size="3" maxlength="5" value="#{adminHeadquarterController.headquarterStore}" validatorMessage="#{msg.ENTERED_STORE_INVALID}">
                                <f:validateLongRange for="headquarterStore" minimum="-5" maximum="200" />
index b581c709a50f5ddba3a2502432cb31172ab61b97..29fac7ddafb6b4837d0d5a468d6e60fa8c732db0 100644 (file)
@@ -17,7 +17,7 @@
 
                        <p:selectOneMenu
                                id="openingStartDay"
-                               value="#{adminBranchOfficeController.openingStartDay}"
+                               value="#{adminHeadquarterController.openingStartDay}"
                                filter="true"
                                filterMatchMode="contains"
                                required="true"
@@ -30,7 +30,7 @@
 
                        <p:selectOneMenu
                                id="openingEndDay"
-                               value="#{adminBranchOfficeController.openingEndDay}"
+                               value="#{adminHeadquarterController.openingEndDay}"
                                filter="true"
                                filterMatchMode="contains"
                                required="true"
 
                        <p:calendar
                                id="openingStartTime"
-                               value="#{adminBranchOfficeController.openingStartTime}"
+                               value="#{adminHeadquarterController.openingStartTime}"
                                pattern="HH:mm"
                                timeOnly="true"
-                               required="true"
                                stepMinute="5"
+                               navigator="true"
+                               required="true"
                                requiredMessage="#{msg.ADMIN_START_TIME_REQUIRED}"
                                />
 
                        <p:calendar
                                id="openingEndTime"
-                               value="#{adminBranchOfficeController.openingEndTime}"
+                               value="#{adminHeadquarterController.openingEndTime}"
                                pattern="HH:mm"
                                timeOnly="true"
-                               required="true"
                                stepMinute="5"
+                               navigator="true"
+                               required="true"
                                requiredMessage="#{msg.ADMIN_END_TIME_REQUIRED}"
                                />
                </p:panelGrid>
index 9587f92d749c786dcbc23e510cda34a6924668c3..73db01cbdaf9cfc2b1319fbe3fedcd4866aeebdb 100644 (file)
@@ -46,8 +46,9 @@
                                value="#{adminOpeningTimeController.openingStartTime}"
                                pattern="HH:mm"
                                timeOnly="true"
-                               required="true"
                                stepMinute="5"
+                               navigator="true"
+                               required="true"
                                requiredMessage="#{msg.ADMIN_START_TIME_REQUIRED}"
                                />
 
@@ -56,8 +57,9 @@
                                value="#{adminOpeningTimeController.openingEndTime}"
                                pattern="HH:mm"
                                timeOnly="true"
-                               required="true"
                                stepMinute="5"
+                               navigator="true"
+                               required="true"
                                requiredMessage="#{msg.ADMIN_END_TIME_REQUIRED}"
                                />
                </p:panelGrid>
index 282b797b6427ce6f10584c8c5e2c14e7d0f2decf..ea67a16d40f3de28261eb5bc4549d8a40f22cb79 100644 (file)
@@ -18,7 +18,7 @@
         <param-value>true</param-value>
     </context-param>
     <context-param>
-        <description>Refresh perioid of facelets.</description>
+        <description>Refresh period of facelets.</description>
         <param-name>javax.faces.FACELETS_REFRESH_PERIOD</param-name>
         <param-value>-1</param-value>
     </context-param>
     <context-param>
         <description>Development mode for WELD, keep disabled unless really needed. Currently it messes up the website.</description>
         <param-name>org.jboss.weld.development</param-name>
-        <param-value>true</param-value>
+        <param-value>false</param-value>
     </context-param>
     <context-param>
         <description>Generic custom JSF tags library</description>
         <param-name>javax.faces.FACELETS_LIBRARIES</param-name>
-        <param-value>/WEB-INF/widgets.jsf.taglib.xml;/WEB-INF/links.jsf.taglib.xml;/WEB-INF/project-links.jsf.taglib.xml</param-value>
+        <param-value>/WEB-INF/widgets.jsf.taglib.xml;/WEB-INF/validators.jsf.taglib.xml;/WEB-INF/links.jsf.taglib.xml;/WEB-INF/project-links.jsf.taglib.xml</param-value>
     </context-param>
     <context-param>
         <description>Project stage</description>
         <param-name>is_feature_company_employee_enabled</param-name>
         <param-value>true</param-value>
     </context-param>
+    <context-param>
+        <description>Whether the public user profile is enabled. If this option is enabled, the setting "is_user_login_require_user_name" must also be enabled as it is mandadory.</description>
+        <param-name>is_feature_public_user_profile_enabled</param-name>
+        <param-value>true</param-value>
+    </context-param>
     <context-param>
         <description>Maximum passwords that must be different.</description>
         <param-name>max_user_password_history</param-name>
         <param-name>is_debug_register_enabled</param-name>
         <param-value>false</param-value>
     </context-param>
-    <context-param>
-        <description>Whether the public user profile is enabled. If this option is enabled, the setting "is_user_login_require_user_name" must also be enabled as it is mandadory.</description>
-        <param-name>is_public_profile_enabled</param-name>
-        <param-value>true</param-value>
-    </context-param>
     <context-param>
         <description>Whether user names are required for completing registration.</description>
         <param-name>is_user_login_require_user_name</param-name>
index c8b9fb57ae7603a03dbee47b1328ea4f9f1394f3..e30997d1b3483bedaad3c88b813b7dd6ce9de8d9 100644 (file)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
-Copyright (C) 2017 Roland Häder
+Copyright (C) 2017, 2018 Free Software Foundation
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU Affero General Public License as