]> git.mxchange.org Git - jfinancials-war.git/commitdiff
Maybe cherry-pick:
authorRoland Häder <roland@mxchange.org>
Mon, 23 Oct 2017 21:22:08 +0000 (23:22 +0200)
committerRoland Häder <roland@mxchange.org>
Mon, 23 Oct 2017 21:26:24 +0000 (23:26 +0200)
- methods had been unified, need to rename here, to
- added default constructors, invoking super constructor and initializing list

Signed-off-by: Roland Häder <roland@mxchange.org>
src/java/org/mxchange/jfinancials/beans/category/FinancialAdminCategoryWebRequestBean.java
src/java/org/mxchange/jfinancials/beans/category/FinancialCategoryWebRequestBean.java
src/java/org/mxchange/jfinancials/beans/product/FinancialAdminProductWebRequestBean.java
src/java/org/mxchange/jfinancials/beans/product/FinancialProductWebRequestBean.java

index 8acb6c5261bfdcae16228e487c6dc243ec856138..ff82752b368b05d572776ff3393d2ed34c791ab1 100644 (file)
@@ -92,7 +92,7 @@ public class FinancialAdminCategoryWebRequestBean extends BaseFinancialsBean imp
                        category.setCategoryTitle(this.getCategoryTitle());
 
                        // Deligate to remote bean
-                       final Category updatedCategory = this.categoryBean.doAdminAddCategory(category);
+                       final Category updatedCategory = this.categoryBean.addProductCategory(category);
 
                        // Fire event
                        this.categoryAddedEvent.fire(new CategoryAddedEvent(updatedCategory));
index 506e99b83a6841f5e85100aa4c4d6da41b05e4b3..d9d588c9c5f9ac9ca9916c07b3497bcd0e12db24 100644 (file)
@@ -20,6 +20,7 @@ import fish.payara.cdi.jsr107.impl.NamedCache;
 import java.text.MessageFormat;
 import java.util.Comparator;
 import java.util.Iterator;
+import java.util.LinkedList;
 import java.util.List;
 import javax.annotation.PostConstruct;
 import javax.cache.Cache;
@@ -66,6 +67,17 @@ public class FinancialCategoryWebRequestBean extends BaseFinancialsBean implemen
        @NamedCache (cacheName = "categoryCache")
        private Cache<Long, Category> categoryCache;
 
+       /**
+        * Default constructor
+        */
+       public FinancialCategoryWebRequestBean () {
+               // Call super constructor
+               super();
+
+               // Init list
+               this.allCategories = new LinkedList<>();
+       }
+
        /**
         * Observes events fired after a new product category has been added
         * <p>
index f22a312ef2bcb8a80e50f747bdc12ecce8b28424..8419a1692e7bc5db286055c39db4a0585b9817d8 100644 (file)
@@ -105,7 +105,7 @@ public class FinancialAdminProductWebRequestBean extends BaseFinancialsBean impl
                        product.setProductTitle(this.getProductTitle());
 
                        // Call bean
-                       final Product updatedProduct = this.productRemoteBean.doAdminAddProduct(product);
+                       final Product updatedProduct = this.productRemoteBean.addGenericProduct(product);
 
                        // Fire event
                        this.addedProductEvent.fire(new ProductAddedEvent(updatedProduct));
index 9d9fb5322a4c7fd0c3e30644d9d9c8783e7f990d..88da637e434c9c613098711f362d7d434980c728 100644 (file)
@@ -20,6 +20,7 @@ import fish.payara.cdi.jsr107.impl.NamedCache;
 import java.text.MessageFormat;
 import java.util.Comparator;
 import java.util.Iterator;
+import java.util.LinkedList;
 import java.util.List;
 import javax.annotation.PostConstruct;
 import javax.cache.Cache;
@@ -67,6 +68,17 @@ public class FinancialProductWebRequestBean extends BaseFinancialsBean implement
        @NamedCache (cacheName = "productCache")
        private Cache<Long, Product> productCache;
 
+       /**
+        * Default constructor
+        */
+       public FinancialProductWebRequestBean () {
+               // Call super constructor
+               super();
+
+               // Init list
+               this.allProducts = new LinkedList<>();
+       }
+
        /**
         * Observes events fired after a new product has been added
         * <p>