From ec89ade5e173ab7f83200d8564ae72cc66ed08c3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Mon, 21 Aug 2017 01:36:16 +0200 Subject: [PATCH] Please cherry-pick: - converted mobile-numer, profile-mode and personal-title selection box into custom JSF tags (awsome stuff!) - added ERROR_PARAMETER_LABEL_MESSAGE_NOT_SET i18n string for JSF label messages - renamed generic.jsf.taglib.xml to widgets.jsf.taglib.xml, fitting previous renamings MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../localization/bundle_de_DE.properties | 1 + .../localization/bundle_en_US.properties | 1 + web/WEB-INF/generic.jsf.taglib.xml | 57 ------- .../columns}/admin_contact_data_columns.tpl | 0 .../admin_contact_data_columns_mini.tpl | 1 - .../{generic => }/messages/message_box.tpl | 4 +- .../messages/message_box_mini.tpl | 4 +- .../table_rows/mobile_selection_table_row.tpl | 36 +++++ .../user_personal_title_table_row.tpl | 31 ++++ .../user_profile_mode_table_row.tpl | 32 ++++ web/WEB-INF/templates/admin/admin_base.tpl | 2 +- .../admin/contact/admin_form_contact_data.tpl | 34 +--- .../admin/contact/admin_show_contact_data.tpl | 3 +- .../mobile/admin_form_add_contact_mobile.tpl | 12 +- .../admin/user/admin_show_user_data.tpl | 3 +- .../admin/user/admin_show_user_data_mini.tpl | 3 +- .../templates/contact/form_contact_data.tpl | 48 +----- web/WEB-INF/templates/guest/guest_base.tpl | 2 +- .../input_fields/mobile_input_fields.tpl | 16 -- .../templates/login/user/user_base.tpl | 4 +- .../selection_boxes/mobile_selection_box.tpl | 22 --- .../personal_title_selection_box.tpl | 17 -- .../profile_mode_selection_box.tpl | 11 -- web/WEB-INF/web.xml | 2 +- web/WEB-INF/widgets.jsf.taglib.xml | 148 ++++++++++++++++++ .../login_user_change_email_address.xhtml | 2 +- 26 files changed, 274 insertions(+), 222 deletions(-) delete mode 100644 web/WEB-INF/generic.jsf.taglib.xml rename web/WEB-INF/{templates/admin/contact => resources/tags/admin/columns}/admin_contact_data_columns.tpl (100%) rename web/WEB-INF/{templates/admin/contact => resources/tags/admin/columns}/admin_contact_data_columns_mini.tpl (99%) rename web/WEB-INF/resources/tags/{generic => }/messages/message_box.tpl (89%) rename web/WEB-INF/resources/tags/{generic => }/messages/message_box_mini.tpl (89%) create mode 100644 web/WEB-INF/resources/tags/table_rows/mobile_selection_table_row.tpl create mode 100644 web/WEB-INF/resources/tags/table_rows/user_personal_title_table_row.tpl create mode 100644 web/WEB-INF/resources/tags/table_rows/user_profile_mode_table_row.tpl delete mode 100644 web/WEB-INF/templates/input_fields/mobile_input_fields.tpl delete mode 100644 web/WEB-INF/templates/selection_boxes/mobile_selection_box.tpl delete mode 100644 web/WEB-INF/templates/selection_boxes/personal_title_selection_box.tpl delete mode 100644 web/WEB-INF/templates/selection_boxes/profile_mode_selection_box.tpl create mode 100644 web/WEB-INF/widgets.jsf.taglib.xml diff --git a/src/java/org/mxchange/localization/bundle_de_DE.properties b/src/java/org/mxchange/localization/bundle_de_DE.properties index 121e8c28..12a5ab03 100644 --- a/src/java/org/mxchange/localization/bundle_de_DE.properties +++ b/src/java/org/mxchange/localization/bundle_de_DE.properties @@ -868,3 +868,4 @@ ERROR_GUEST_REGISTRATION_IN_INDEX_ENABLED=Fehler: Falscher Aufruf der Anmeldesei BUTTON_CHANGE_LOCALE=Aendern #@TODO Please fix German umlauts! BUTTON_CHANGE_LOCALE_TITLE=Aendern Sie hier in der aktuellen Sitzung die angezeigte Sprache. +ERROR_PARAMETER_LABEL_MESSAGE_NOT_SET=Fehler: Parameter "labelMessage" nicht gesetzt. diff --git a/src/java/org/mxchange/localization/bundle_en_US.properties b/src/java/org/mxchange/localization/bundle_en_US.properties index e8e347e2..6a09b611 100644 --- a/src/java/org/mxchange/localization/bundle_en_US.properties +++ b/src/java/org/mxchange/localization/bundle_en_US.properties @@ -833,3 +833,4 @@ BUTTON_ADMIN_CONTINUE_BUSINESS_CONTACT_PERSON=Add basic data ERROR_GUEST_REGISTRATION_IN_INDEX_ENABLED=Error: Wrong request on registration page as the index page serves as registration page. BUTTON_CHANGE_LOCALE=Change BUTTON_CHANGE_LOCALE_TITLE=Change here in your current session the used language for text output. +ERROR_PARAMETER_LABEL_MESSAGE_NOT_SET=Error: Parameter "labelMessage" not set. diff --git a/web/WEB-INF/generic.jsf.taglib.xml b/web/WEB-INF/generic.jsf.taglib.xml deleted file mode 100644 index 519b1897..00000000 --- a/web/WEB-INF/generic.jsf.taglib.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - http://mxchange.org/jsf/core/widgets - - outputMessageBox - This tag renders a style-able and customizable message for any kind of messages that the user should see. - resources/tags/generic/messages/message_box.tpl - - message - The message that should be place into the message box. You may also use EL code here that resolves to a message string. - true - java.lang.String - - - styleClass - The optional CSS style class to be forwarded on the h:outputText's styleClass attribute of the message. The default is "okay" which normally renders as a green colored message. - false - java.lang.String - - - - outputMessageBoxMini - This tag renders a style-able and customizable mini message for any kind of messages that the user should see. It is similar to outputMessageBox tag but it renders a smaller box instead. - resources/tags/generic/messages/message_box_mini.tpl - - message - The message that should be place into the message box. You may also use EL code here that resolves to a message string. - true - java.lang.String - - - styleClass - The optional CSS style class to be forwarded on the h:outputText's styleClass attribute of the message. The default is "okay" which normally renders as a green colored message. - false - java.lang.String - - - diff --git a/web/WEB-INF/templates/admin/contact/admin_contact_data_columns.tpl b/web/WEB-INF/resources/tags/admin/columns/admin_contact_data_columns.tpl similarity index 100% rename from web/WEB-INF/templates/admin/contact/admin_contact_data_columns.tpl rename to web/WEB-INF/resources/tags/admin/columns/admin_contact_data_columns.tpl diff --git a/web/WEB-INF/templates/admin/contact/admin_contact_data_columns_mini.tpl b/web/WEB-INF/resources/tags/admin/columns/admin_contact_data_columns_mini.tpl similarity index 99% rename from web/WEB-INF/templates/admin/contact/admin_contact_data_columns_mini.tpl rename to web/WEB-INF/resources/tags/admin/columns/admin_contact_data_columns_mini.tpl index 61e914a9..f510a317 100644 --- a/web/WEB-INF/templates/admin/contact/admin_contact_data_columns_mini.tpl +++ b/web/WEB-INF/resources/tags/admin/columns/admin_contact_data_columns_mini.tpl @@ -6,7 +6,6 @@ xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:ui="http://xmlns.jcp.org/jsf/facelets"> - diff --git a/web/WEB-INF/resources/tags/generic/messages/message_box.tpl b/web/WEB-INF/resources/tags/messages/message_box.tpl similarity index 89% rename from web/WEB-INF/resources/tags/generic/messages/message_box.tpl rename to web/WEB-INF/resources/tags/messages/message_box.tpl index c32fdf7b..893620e2 100644 --- a/web/WEB-INF/resources/tags/generic/messages/message_box.tpl +++ b/web/WEB-INF/resources/tags/messages/message_box.tpl @@ -5,7 +5,7 @@ xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:f="http://xmlns.jcp.org/jsf/core"> -
+
@@ -29,5 +29,5 @@
- + diff --git a/web/WEB-INF/resources/tags/generic/messages/message_box_mini.tpl b/web/WEB-INF/resources/tags/messages/message_box_mini.tpl similarity index 89% rename from web/WEB-INF/resources/tags/generic/messages/message_box_mini.tpl rename to web/WEB-INF/resources/tags/messages/message_box_mini.tpl index 35cd54ad..893620e2 100644 --- a/web/WEB-INF/resources/tags/generic/messages/message_box_mini.tpl +++ b/web/WEB-INF/resources/tags/messages/message_box_mini.tpl @@ -5,7 +5,7 @@ xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:f="http://xmlns.jcp.org/jsf/core"> -
+
@@ -29,5 +29,5 @@
- + diff --git a/web/WEB-INF/resources/tags/table_rows/mobile_selection_table_row.tpl b/web/WEB-INF/resources/tags/table_rows/mobile_selection_table_row.tpl new file mode 100644 index 00000000..4436316a --- /dev/null +++ b/web/WEB-INF/resources/tags/table_rows/mobile_selection_table_row.tpl @@ -0,0 +1,36 @@ + + + + + + + + + +
+ +
+ +
+ + + + + + + + + +
+
+ + + + +
+
diff --git a/web/WEB-INF/resources/tags/table_rows/user_personal_title_table_row.tpl b/web/WEB-INF/resources/tags/table_rows/user_personal_title_table_row.tpl new file mode 100644 index 00000000..adce3cb0 --- /dev/null +++ b/web/WEB-INF/resources/tags/table_rows/user_personal_title_table_row.tpl @@ -0,0 +1,31 @@ + + + + + + + +
+ +
+ +
+ + + + +
+ +
+
+ + + + +
+
diff --git a/web/WEB-INF/resources/tags/table_rows/user_profile_mode_table_row.tpl b/web/WEB-INF/resources/tags/table_rows/user_profile_mode_table_row.tpl new file mode 100644 index 00000000..132e28db --- /dev/null +++ b/web/WEB-INF/resources/tags/table_rows/user_profile_mode_table_row.tpl @@ -0,0 +1,32 @@ + + + + + + + + + +
+ +
+ +
+ + + +
+ +
+
+ + + + +
+
diff --git a/web/WEB-INF/templates/admin/admin_base.tpl b/web/WEB-INF/templates/admin/admin_base.tpl index 1fd16dda..b0e99e81 100644 --- a/web/WEB-INF/templates/admin/admin_base.tpl +++ b/web/WEB-INF/templates/admin/admin_base.tpl @@ -20,6 +20,6 @@ TODO: Add something here that should be displayed on all admin pages - + diff --git a/web/WEB-INF/templates/admin/contact/admin_form_contact_data.tpl b/web/WEB-INF/templates/admin/contact/admin_form_contact_data.tpl index ddc82a43..dd1aea7f 100644 --- a/web/WEB-INF/templates/admin/contact/admin_form_contact_data.tpl +++ b/web/WEB-INF/templates/admin/contact/admin_form_contact_data.tpl @@ -1,6 +1,7 @@ @@ -14,24 +15,7 @@ - -
- -
- -
- - - - -
- -
-
- - - - +
@@ -233,19 +217,7 @@
- -
- -
- -
- - - -
- -
-
+
diff --git a/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl b/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl index 774bcff8..5fb4f0c7 100644 --- a/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl +++ b/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl @@ -1,6 +1,7 @@ @@ -12,6 +13,6 @@ - + diff --git a/web/WEB-INF/templates/admin/mobile/admin_form_add_contact_mobile.tpl b/web/WEB-INF/templates/admin/mobile/admin_form_add_contact_mobile.tpl index ec1e8c0a..2e62ae93 100644 --- a/web/WEB-INF/templates/admin/mobile/admin_form_add_contact_mobile.tpl +++ b/web/WEB-INF/templates/admin/mobile/admin_form_add_contact_mobile.tpl @@ -36,17 +36,7 @@
- -
- -
- -
- - - -
-
+