From e156316044d4ce34685b947d732a6b572bb3be26 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Wed, 21 Mar 2018 00:19:39 +0100 Subject: [PATCH] Please cherry-pick: - removed no longer required profile-mode backing bean - removed admin_form_user_personal_data.tpl as there is no need for it - added validators.jsf.taglib.xml which holds descriptions for JSF validators ... - always sort/filter by direct entity - fixed i18n keys, was missing an underscore MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- ...LICENSE.txt => primefaces-6.2_LICENSE.txt} | 0 ...nancialsProfileModeWebApplicationBean.java | 66 --------------- ...lsProfileModeWebApplicationController.java | 28 ------- .../user/admin_form_user_personal_data.tpl | 16 ---- web/WEB-INF/validators.jsf.taglib.xml | 83 +++++++++++++++++++ .../basic_data/admin_basic_data_list.xhtml | 4 +- .../admin_branch_office_list.xhtml | 10 +-- web/admin/contact/admin_contact_edit.xhtml | 2 +- web/admin/contact/admin_contact_list.xhtml | 2 +- .../department/admin_department_list.xhtml | 8 +- web/admin/employee/admin_employee_list.xhtml | 14 ++-- .../headquarter/admin_headquarter_list.xhtml | 4 +- web/admin/user/admin_user_list.xhtml | 8 +- 13 files changed, 112 insertions(+), 133 deletions(-) rename lib/primefaces/{primefaces-6.1_LICENSE.txt => primefaces-6.2_LICENSE.txt} (100%) delete mode 100644 src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationBean.java delete mode 100644 src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationController.java delete mode 100644 web/WEB-INF/templates/admin/user/admin_form_user_personal_data.tpl create mode 100644 web/WEB-INF/validators.jsf.taglib.xml diff --git a/lib/primefaces/primefaces-6.1_LICENSE.txt b/lib/primefaces/primefaces-6.2_LICENSE.txt similarity index 100% rename from lib/primefaces/primefaces-6.1_LICENSE.txt rename to lib/primefaces/primefaces-6.2_LICENSE.txt diff --git a/src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationBean.java b/src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationBean.java deleted file mode 100644 index 54d720bf..00000000 --- a/src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationBean.java +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Copyright (C) 2016, 2017 Roland Häder - * - * 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 . - */ -package org.mxchange.jfinancials.beans.profilemode; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import javax.enterprise.context.ApplicationScoped; -import javax.inject.Named; -import org.mxchange.jfinancials.beans.BaseFinancialsBean; -import org.mxchange.jusercore.model.user.profilemodes.ProfileMode; - -/** - * A profile mode bean - *

- * @author Roland Häder - */ -@Named ("profileModeController") -@ApplicationScoped -public class FinancialsProfileModeWebApplicationBean extends BaseFinancialsBean implements FinancialsProfileModeWebApplicationController { - - /** - * Serial number - */ - private static final long serialVersionUID = 835_482_364_189L; - - /** - * A list of all profile modes - */ - private final List allProfileModes; - - /** - * Default constructor - */ - public FinancialsProfileModeWebApplicationBean () { - // Call super constructor - super(); - - // Init list - this.allProfileModes = Arrays.asList(ProfileMode.values()); - } - - /** - * Getter for all profile modes as array - *

- * @return All profile modes as list - */ - public List allProfileModes () { - // Return it - return Collections.unmodifiableList(this.allProfileModes); - } -} diff --git a/src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationController.java b/src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationController.java deleted file mode 100644 index 20331e0c..00000000 --- a/src/java/org/mxchange/jfinancials/beans/profilemode/FinancialsProfileModeWebApplicationController.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright (C) 2016, 2017 Roland Häder - * - * 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 . - */ -package org.mxchange.jfinancials.beans.profilemode; - -import java.io.Serializable; - -/** - * An interface for data beans - *

- * @author Roland Häder - */ -public interface FinancialsProfileModeWebApplicationController extends Serializable { - -} diff --git a/web/WEB-INF/templates/admin/user/admin_form_user_personal_data.tpl b/web/WEB-INF/templates/admin/user/admin_form_user_personal_data.tpl deleted file mode 100644 index 973b944a..00000000 --- a/web/WEB-INF/templates/admin/user/admin_form_user_personal_data.tpl +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - - - - - - diff --git a/web/WEB-INF/validators.jsf.taglib.xml b/web/WEB-INF/validators.jsf.taglib.xml new file mode 100644 index 00000000..e575a7ac --- /dev/null +++ b/web/WEB-INF/validators.jsf.taglib.xml @@ -0,0 +1,83 @@ + + + + http://mxchange.org/jsf/core/validators + + emailAddressValidator + + EmailAddressValidator + + + Whether email address is allowed to be empty. + allowEmptyRequiredData + java.lang.Boolean + false + + + + basicDataEmailAddressValidator + + BasicDataEmailAddressValidator + + + Whether email address is allowed to be empty. + allowEmptyRequiredData + java.lang.Boolean + false + + + + employeeEmailAddressValidator + + EmployeeEmailAddressValidator + + + Whether email address is allowed to be empty. + allowEmptyRequiredData + java.lang.Boolean + false + + + + headquarterEmailAddressValidator + + HeadquarterEmailAddressValidator + + + Whether email address is allowed to be empty. + allowEmptyRequiredData + java.lang.Boolean + false + + + + urlValidator + + UrlValidator + + + Whether URL is allowed to be empty. + allowEmptyRequiredData + java.lang.Boolean + false + + + diff --git a/web/admin/basic_data/admin_basic_data_list.xhtml b/web/admin/basic_data/admin_basic_data_list.xhtml index 86988c96..db857280 100644 --- a/web/admin/basic_data/admin_basic_data_list.xhtml +++ b/web/admin/basic_data/admin_basic_data_list.xhtml @@ -32,7 +32,7 @@ rowsPerPageTemplate="5,10,20,50,100" sortMode="multiple" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_BASIC_DATA}" - emptyMessage="#{msg.ADMIN__EMPTY_LISTBASIC_DATA}" + emptyMessage="#{msg.ADMIN__EMPTY_LIST_BASIC_DATA}" widgetVar="basicDataList" > @@ -53,7 +53,7 @@ - + - + - + - + - + @@ -110,7 +110,7 @@ - + - +