]> git.mxchange.org Git - pizzaservice-war.git/blobdiff - src/java/org/mxchange/pizzaapplication/beans/country/PizzaAdminCountryWebRequestBean.java
Rewrites:
[pizzaservice-war.git] / src / java / org / mxchange / pizzaapplication / beans / country / PizzaAdminCountryWebRequestBean.java
index 014bcbe6de59c883c22372348a07fb368b174486..10ce8b88f66f944104605578bc4da908b3fe9197 100644 (file)
@@ -147,6 +147,9 @@ public class PizzaAdminCountryWebRequestBean implements PizzaAdminCountryWebRequ
                // Fire event
                this.addedCountryEvent.fire(new AdminEventCountryAdded(updatedCountry));
 
+               // Clear this bean
+               this.clear();
+
                // Redirect to list
                return "admin_list_country"; //NOI18N
        }
@@ -222,6 +225,19 @@ public class PizzaAdminCountryWebRequestBean implements PizzaAdminCountryWebRequ
                return (!this.allCountries().isEmpty());
        }
 
+       /**
+        * Clears this bean
+        */
+       private void clear () {
+               // Clear all fields
+               this.setCountryAbroadDialPrefix(null);
+               this.setCountryCode(null);
+               this.setCountryExternalDialPrefix(null);
+               this.setCountryI18nKey(null);
+               this.setCountryIsLocalPrefixRequired(Boolean.FALSE);
+               this.setCountryPhoneCode(null);
+       }
+
        /**
         * Checks if given country is already added by iterating over the whole list
         * and try to find it.