From: Roland Häder Date: Sun, 22 Jan 2023 05:51:00 +0000 (+0100) Subject: Please cherry-pick: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=06b17b6e4fa902fe0ffa8b4f30c1e70aa4962c8b;p=jfinancials-war.git Please cherry-pick: - jcoree.jar has changed, so showFacesException() is now the new name as this method shows a message from a thrown exception --- diff --git a/src/java/org/mxchange/jfinancials/beans/contact/FinancialsContactWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/contact/FinancialsContactWebRequestBean.java index 753dd437..ba2a8420 100644 --- a/src/java/org/mxchange/jfinancials/beans/contact/FinancialsContactWebRequestBean.java +++ b/src/java/org/mxchange/jfinancials/beans/contact/FinancialsContactWebRequestBean.java @@ -347,7 +347,7 @@ public class FinancialsContactWebRequestBean extends BaseFinancialsBean implemen throw new FacesException("Not all required fields are set."); //NOI18N } else if (!this.userLoginController.ifCurrentPasswordMatches()) { // Password not matching - this.showFacesMessage("form_login_change_personal:currentPassword", new UserPasswordMismatchException(this.userLoginController.getLoggedInUser()), FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_login_change_personal:currentPassword", new UserPasswordMismatchException(this.userLoginController.getLoggedInUser()), FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } diff --git a/src/java/org/mxchange/jfinancials/beans/contact/mobile/FinancialsAdminContactMobileWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/contact/mobile/FinancialsAdminContactMobileWebRequestBean.java index 08fc1511..67c1a085 100644 --- a/src/java/org/mxchange/jfinancials/beans/contact/mobile/FinancialsAdminContactMobileWebRequestBean.java +++ b/src/java/org/mxchange/jfinancials/beans/contact/mobile/FinancialsAdminContactMobileWebRequestBean.java @@ -330,7 +330,7 @@ public class FinancialsAdminContactMobileWebRequestBean extends BaseFinancialsBe updatedContact = this.adminContactMobileBean.linkNewMobileNumberWithContact(targetContact, number); } catch (final MobileNumberAlreadyLinkedException | ContactNotFoundException ex) { // Throw again as cause - this.showFacesMessage("form_add_contact_mobile:mobileNumber", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_add_contact_mobile:mobileNumber", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } @@ -466,7 +466,7 @@ public class FinancialsAdminContactMobileWebRequestBean extends BaseFinancialsBe updatedContact = this.adminContactMobileBean.unlinkMobileDataFromContact(this.getContact(), number); } catch (final MobileNumberNotLinkedException | ContactNotFoundException ex) { // Did not work - this.showFacesMessage("form_unlink_contact_mobile:mobileNumberId", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_unlink_contact_mobile:mobileNumberId", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } diff --git a/src/java/org/mxchange/jfinancials/beans/contact/phone/FinancialsAdminContactPhoneWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/contact/phone/FinancialsAdminContactPhoneWebRequestBean.java index 497842b6..484da1db 100644 --- a/src/java/org/mxchange/jfinancials/beans/contact/phone/FinancialsAdminContactPhoneWebRequestBean.java +++ b/src/java/org/mxchange/jfinancials/beans/contact/phone/FinancialsAdminContactPhoneWebRequestBean.java @@ -43,7 +43,6 @@ import org.mxchange.jcontacts.model.contact.Contact; import org.mxchange.jcontacts.model.phone.AdminContactsPhoneSessionBeanRemote; import org.mxchange.jcountry.model.data.Country; import org.mxchange.jfinancials.beans.BaseFinancialsBean; -import org.mxchange.jfinancials.beans.phone.FinancialsAdminPhoneWebRequestController; import org.mxchange.jphone.events.fax.created.ObservableCreatedFaxNumberEvent; import org.mxchange.jphone.events.landline.created.ObservableCreatedLandLineNumberEvent; import org.mxchange.jphone.exceptions.phone.PhoneNumberAlreadyLinkedException; @@ -93,12 +92,6 @@ public class FinancialsAdminContactPhoneWebRequestBean extends BaseFinancialsBea @Any private Event adminLinkedLandLineNumberEvent; - /** - * Administrative phone controller - */ - @Inject - private FinancialsAdminPhoneWebRequestController adminPhoneController; - /** * Contact instance */ @@ -424,7 +417,7 @@ public class FinancialsAdminContactPhoneWebRequestBean extends BaseFinancialsBea updatedContact = this.adminContactPhoneBean.linkNewFaxNumberWithContact(targetContact, number); } catch (final PhoneNumberAlreadyLinkedException | ContactNotFoundException ex) { // Throw again as cause - this.showFacesMessage("form_add_contact_fax:faxNumber", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_add_contact_fax:faxNumber", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } @@ -488,7 +481,7 @@ public class FinancialsAdminContactPhoneWebRequestBean extends BaseFinancialsBea updatedContact = this.adminContactPhoneBean.linkNewLandLineNumberWithContact(targetContact, number); } catch (final PhoneNumberAlreadyLinkedException | ContactNotFoundException ex) { // Throw again as cause - this.showFacesMessage("form_add_contact_landLine:landLineNumber", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_add_contact_landLine:landLineNumber", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } @@ -687,7 +680,7 @@ public class FinancialsAdminContactPhoneWebRequestBean extends BaseFinancialsBea updatedContact = this.adminContactPhoneBean.unlinkFaxDataFromContact(this.getContact(), number); } catch (final PhoneNumberNotLinkedException | ContactNotFoundException ex) { // Did not work - this.showFacesMessage("form_unlink_contact_fax:faxNumberId", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_unlink_contact_fax:faxNumberId", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } @@ -742,7 +735,7 @@ public class FinancialsAdminContactPhoneWebRequestBean extends BaseFinancialsBea updatedContact = this.adminContactPhoneBean.unlinkLandLineDataFromContact(this.getContact(), number); } catch (final PhoneNumberNotLinkedException | ContactNotFoundException ex) { // Did not work - this.showFacesMessage("form_unlink_contact_landLine:landLineNumberId", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_unlink_contact_landLine:landLineNumberId", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N } diff --git a/src/java/org/mxchange/jfinancials/beans/mobileprovider/FinancialsAdminMobileProviderWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/mobileprovider/FinancialsAdminMobileProviderWebRequestBean.java index 435d5399..241cf412 100644 --- a/src/java/org/mxchange/jfinancials/beans/mobileprovider/FinancialsAdminMobileProviderWebRequestBean.java +++ b/src/java/org/mxchange/jfinancials/beans/mobileprovider/FinancialsAdminMobileProviderWebRequestBean.java @@ -110,7 +110,7 @@ public class FinancialsAdminMobileProviderWebRequestBean extends BaseFinancialsB // Is the provider already created? if (this.isMobileProviderCreated(mobileProvider)) { // Then throw exception - this.showFacesMessage("form_add_mobile_provider:providerDialPrefix", new MobileProviderAlreadyAddedException(mobileProvider), FacesMessage.SEVERITY_WARN); //NOI18N + this.showFacesException("form_add_mobile_provider:providerDialPrefix", new MobileProviderAlreadyAddedException(mobileProvider), FacesMessage.SEVERITY_WARN); //NOI18N return; } diff --git a/src/java/org/mxchange/jfinancials/beans/user/email_address/FinancialsEmailChangeWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/user/email_address/FinancialsEmailChangeWebRequestBean.java index c1937395..ad5b2b1f 100644 --- a/src/java/org/mxchange/jfinancials/beans/user/email_address/FinancialsEmailChangeWebRequestBean.java +++ b/src/java/org/mxchange/jfinancials/beans/user/email_address/FinancialsEmailChangeWebRequestBean.java @@ -115,7 +115,7 @@ public class FinancialsEmailChangeWebRequestBean extends BaseFinancialsBean impl return ""; //NOI18N } else if (!this.userLoginController.ifCurrentPasswordMatches()) { // Password not matching - this.showFacesMessage("form_login_user_change_email_address:currentPassword", new UserPasswordMismatchException(this.userLoginController.getLoggedInUser()), FacesMessage.SEVERITY_WARN); //NOI18N + this.showFacesException("form_login_user_change_email_address:currentPassword", new UserPasswordMismatchException(this.userLoginController.getLoggedInUser()), FacesMessage.SEVERITY_WARN); //NOI18N return ""; //NOI18N } diff --git a/src/java/org/mxchange/jfinancials/beans/user/resendlink/FinancialsResendLinkWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/user/resendlink/FinancialsResendLinkWebRequestBean.java index c352ed11..89ceb509 100644 --- a/src/java/org/mxchange/jfinancials/beans/user/resendlink/FinancialsResendLinkWebRequestBean.java +++ b/src/java/org/mxchange/jfinancials/beans/user/resendlink/FinancialsResendLinkWebRequestBean.java @@ -152,7 +152,7 @@ public class FinancialsResendLinkWebRequestBean extends BaseFinancialsBean imple return ""; //NOI18N } catch (final UserStatusLockedException | UserStatusConfirmedException ex) { // Output message, this should not happen as the confirmation key is being removed - this.showFacesMessage("form_resend_link:resendEmailAddress", ex, FacesMessage.SEVERITY_ERROR); //NOI18N + this.showFacesException("form_resend_link:resendEmailAddress", ex, FacesMessage.SEVERITY_ERROR); //NOI18N return ""; //NOI18N }