From 0d514a107e0f5b19687f9f1057b787019615e66b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 31 May 2016 15:27:46 +0200 Subject: [PATCH] added title (e.g. Dr., Prof. etc) MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- nbproject/faces-config.NavData | 122 +++++++++--------- .../JobsAdminContactWebRequestBean.java | 18 +++ .../JobsAdminContactWebRequestController.java | 14 ++ .../localization/bundle_de_DE.properties | 1 + .../localization/bundle_en_US.properties | 1 + .../admin/contact/admin_form_contact_data.tpl | 14 ++ 6 files changed, 109 insertions(+), 61 deletions(-) diff --git a/nbproject/faces-config.NavData b/nbproject/faces-config.NavData index 3df3c843..e492c25d 100644 --- a/nbproject/faces-config.NavData +++ b/nbproject/faces-config.NavData @@ -2,67 +2,67 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java index 3aa0ea26..53d1845d 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java @@ -214,6 +214,11 @@ public class JobsAdminContactWebRequestBean extends BaseJobsController implement */ private String street; + /** + * Title + */ + private String title; + /** * An event fired when the administrator has updated contact data */ @@ -310,6 +315,7 @@ public class JobsAdminContactWebRequestBean extends BaseJobsController implement // Set all fields: contact this.setContactId(contact.getContactId()); + this.setTitle(contact.getContactTitle()); this.setBirthday(contact.getContactBirthday()); this.setCity(contact.getContactCity()); this.setComment(contact.getContactComment()); @@ -679,6 +685,16 @@ public class JobsAdminContactWebRequestBean extends BaseJobsController implement this.street = street; } + @Override + public String getTitle () { + return this.title; + } + + @Override + public void setTitle (final String title) { + this.title = title; + } + @Override public Integer getZipCode () { return this.zipCode; @@ -703,6 +719,7 @@ public class JobsAdminContactWebRequestBean extends BaseJobsController implement // Clear all data // - personal data this.setGender(Gender.UNKNOWN); + this.setTitle(null); this.setFirstName(null); this.setFamilyName(null); this.setStreet(null); @@ -778,6 +795,7 @@ public class JobsAdminContactWebRequestBean extends BaseJobsController implement // Update all fields contact.setContactGender(this.getGender()); + contact.setContactTitle(this.getTitle()); contact.setContactFirstName(this.getFirstName()); contact.setContactFamilyName(this.getFamilyName()); contact.setContactStreet(this.getStreet()); diff --git a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestController.java b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestController.java index 5959a700..8df27e4d 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestController.java +++ b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestController.java @@ -369,6 +369,20 @@ public interface JobsAdminContactWebRequestController extends Serializable { */ void setStreet (final String street); + /** + * Getter for title + *

+ * @return title + */ + String getTitle (); + + /** + * Setter for title + *

+ * @param title Title + */ + void setTitle (final String title); + /** * ZIP code *

diff --git a/src/java/org/mxchange/localization/bundle_de_DE.properties b/src/java/org/mxchange/localization/bundle_de_DE.properties index fa9635ad..e475afb7 100644 --- a/src/java/org/mxchange/localization/bundle_de_DE.properties +++ b/src/java/org/mxchange/localization/bundle_de_DE.properties @@ -545,3 +545,4 @@ GUEST_CONTACT_DATA_ZIP_CODE_REQUIRED=Bitte geben Sie Ihre Postleitzahl ein. GUEST_CONTACT_DATA_CITY_REQUIRED=Bitte geben Sie Ihren Wohnort ein. GUEST_CONTACT_DATA_BIRTHDAY_REQUIRED=Bitte geben Sie Ihr Geburtsdatum ein. FIELD_GENDER_REQUIRED=Bitte w\u00e4hlen Sie eine Anrede aus. +ADMIN_PERSONAL_DATA_TITLE=Titel: diff --git a/src/java/org/mxchange/localization/bundle_en_US.properties b/src/java/org/mxchange/localization/bundle_en_US.properties index 689fc279..4959551d 100644 --- a/src/java/org/mxchange/localization/bundle_en_US.properties +++ b/src/java/org/mxchange/localization/bundle_en_US.properties @@ -546,3 +546,4 @@ GUEST_CONTACT_DATA_ZIP_CODE_REQUIRED=Please enter your ZIP code. GUEST_CONTACT_DATA_CITY_REQUIRED=Please enter your city. GUEST_CONTACT_DATA_BIRTHDAY_REQUIRED=Please enter your birthday. FIELD_GENDER_REQUIRED=Please select a salutation. +ADMIN_PERSONAL_DATA_TITLE=Title: 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 0282508c..f7f3228b 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 @@ -41,6 +41,20 @@ +

+
+ +
+ +
+ +
+ +
+
+ + +
-- 2.39.5