@Service(value="blAdminCatalogService") public class AdminCatalogServiceImpl extends java.lang.Object implements AdminCatalogService
| Modifier and Type | Field and Description |
|---|---|
protected CatalogService |
catalogService |
protected javax.persistence.EntityManager |
em |
protected SkuDao |
skuDao |
| Constructor and Description |
|---|
AdminCatalogServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Boolean |
cloneProduct(java.lang.Long productId)
This will create a new product along with a new Sku for the defaultSku, along with new
Skus for all of the additional Skus.
|
java.util.List<java.util.List<ProductOptionValue>> |
generatePermutations(int currentTypeIndex,
java.util.List<ProductOptionValue> currentPermutation,
java.util.List<ProductOption> options)
Generates all the possible permutations for the combinations of given ProductOptions
|
java.lang.Integer |
generateSkusFromProduct(java.lang.Long productId)
Clear out any Skus that are already attached to the Product
if there were any there and generate a new set of Skus based
on the permutations of ProductOptions attached to this Product
|
protected boolean |
isSamePermutation(java.util.List<ProductOptionValue> perm1,
java.util.List<ProductOptionValue> perm2) |
protected CatalogService catalogService
protected SkuDao skuDao
protected javax.persistence.EntityManager em
public java.lang.Integer generateSkusFromProduct(java.lang.Long productId)
AdminCatalogServicegenerateSkusFromProduct in interface AdminCatalogServiceproductId - - the Product to generate Skus fromprotected boolean isSamePermutation(java.util.List<ProductOptionValue> perm1, java.util.List<ProductOptionValue> perm2)
public java.util.List<java.util.List<ProductOptionValue>> generatePermutations(int currentTypeIndex, java.util.List<ProductOptionValue> currentPermutation, java.util.List<ProductOption> options)
currentTypeIndex - currentPermutation - options - public java.lang.Boolean cloneProduct(java.lang.Long productId)
AdminCatalogServicecloneProduct in interface AdminCatalogServiceCopyright © 2018. All Rights Reserved.