Class DefaultCustomerCouponDao
java.lang.Object
de.hybris.platform.servicelayer.internal.dao.DefaultGenericDao<CustomerCouponModel>
de.hybris.platform.customercouponservices.daos.impl.DefaultCustomerCouponDao
- All Implemented Interfaces:
CustomerCouponDao,GenericDao<CustomerCouponModel>
public class DefaultCustomerCouponDao
extends DefaultGenericDao<CustomerCouponModel>
implements CustomerCouponDao
Default implementation of
CustomerCouponDao-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancheckCustomerCouponAvailableForCustomer(String couponCode, CustomerModel customer) Checks if the customer coupon is available for the customerintcountAssignedCouponForCustomer(String couponCode, CustomerModel customer) Counts the assigned customer coupons for the customer by coupon codeprotected SortQueryDatacreateSortQueryData(String sortCode, String query) findAssignableCoupons(CustomerModel customer, String text) Finds assignable customer coupons for the customer by search textfindAssignedCouponsByCustomer(CustomerModel customer, String text) Finds assigned customer coupons by the customer and search textprotected List<CustomerCouponModel>findAssignmentCoupons(CustomerModel customer, String text, String query, Map<String, Object> params) Finds category for promotion source rules by promotion source ruleFinds customer coupons by promotion source rulefindCustomerCouponsByCustomer(CustomerModel customer, PageableData pageableData) Finds paginated customer couponsFinds customer coupons for the customerfindExclPromotionSourceRuleByCategory(String categoryCode) Finds excluded promotion source rules by categoryfindExclPromotionSourceRuleByProduct(String productCode) Finds excluded promotion source rules by product codefindPaginatedCouponsByCustomer(CustomerModel customer, SearchPageData searchPageData) Finds paginated customer coupons by the customer and searchPageDataFinds product for promotion source rules by codefindPromotionSourceRuleByCategory(String categoryCode) Finds promotion source rules by categoryFinds promotion source rules by rule codefindPromotionSourceRuleByProduct(String productCode) Finds promotion source rules by product codeprotected PagedFlexibleSearchServiceprotected PaginatedFlexibleSearchServicevoidsetCustomerCouponSortCodeToQueryAlias(Map<String, String> customerCouponSortCodeToQueryAlias) voidsetPagedFlexibleSearchService(PagedFlexibleSearchService pagedFlexibleSearchService) voidsetPaginatedFlexibleSearchService(PaginatedFlexibleSearchService paginatedFlexibleSearchService) Methods inherited from class de.hybris.platform.servicelayer.internal.dao.DefaultGenericDao
find, find, find, find, find, getFlexibleSearchService, setFlexibleSearchService
-
Constructor Details
-
DefaultCustomerCouponDao
public DefaultCustomerCouponDao()
-
-
Method Details
-
findPromotionSourceRuleByCode
Description copied from interface:CustomerCouponDaoFinds promotion source rules by rule code- Specified by:
findPromotionSourceRuleByCodein interfaceCustomerCouponDao- Parameters:
code- the rule code- Returns:
- the optional of PromotionSourceRuleModel
-
findPromotionSourceRuleByProduct
Description copied from interface:CustomerCouponDaoFinds promotion source rules by product code- Specified by:
findPromotionSourceRuleByProductin interfaceCustomerCouponDao- Parameters:
productCode- the product code- Returns:
- the list of PromotionSourceRuleModel
-
findExclPromotionSourceRuleByProduct
Description copied from interface:CustomerCouponDaoFinds excluded promotion source rules by product code- Specified by:
findExclPromotionSourceRuleByProductin interfaceCustomerCouponDao- Parameters:
productCode- the product code- Returns:
- the list of PromotionSourceRuleModel
-
findPromotionSourceRuleByCategory
Description copied from interface:CustomerCouponDaoFinds promotion source rules by category- Specified by:
findPromotionSourceRuleByCategoryin interfaceCustomerCouponDao- Parameters:
categoryCode- the category code- Returns:
- the list of PromotionSourceRuleModel
-
findExclPromotionSourceRuleByCategory
Description copied from interface:CustomerCouponDaoFinds excluded promotion source rules by category- Specified by:
findExclPromotionSourceRuleByCategoryin interfaceCustomerCouponDao- Parameters:
categoryCode- the category code- Returns:
- the list of PromotionSourceRuleModel
-
findCustomerCouponByPromotionSourceRule
Description copied from interface:CustomerCouponDaoFinds customer coupons by promotion source rule- Specified by:
findCustomerCouponByPromotionSourceRulein interfaceCustomerCouponDao- Parameters:
code- the promotion source rule code- Returns:
- the list of CustomerCouponModel
-
findProductForPromotionSourceRuleByPromotion
public List<ProductForPromotionSourceRuleModel> findProductForPromotionSourceRuleByPromotion(String code) Description copied from interface:CustomerCouponDaoFinds product for promotion source rules by code- Specified by:
findProductForPromotionSourceRuleByPromotionin interfaceCustomerCouponDao- Parameters:
code- the promotion source rule code- Returns:
- the list of ProductForPromotionSourceRuleModel
-
findCategoryForPromotionSourceRuleByPromotion
public List<CatForPromotionSourceRuleModel> findCategoryForPromotionSourceRuleByPromotion(String code) Description copied from interface:CustomerCouponDaoFinds category for promotion source rules by promotion source rule- Specified by:
findCategoryForPromotionSourceRuleByPromotionin interfaceCustomerCouponDao- Parameters:
code- the promotion source rule code- Returns:
- the list of CatForPromotionSourceRuleModel
-
findCustomerCouponsByCustomer
public SearchPageData<CustomerCouponModel> findCustomerCouponsByCustomer(CustomerModel customer, PageableData pageableData) Description copied from interface:CustomerCouponDaoFinds paginated customer coupons- Specified by:
findCustomerCouponsByCustomerin interfaceCustomerCouponDao- Parameters:
customer- the customer modelpageableData- the data used for pagination- Returns:
- the list of paginated CustomerCouponModel
-
createSortQueryData
-
findEffectiveCustomerCouponsByCustomer
Description copied from interface:CustomerCouponDaoFinds customer coupons for the customer- Specified by:
findEffectiveCustomerCouponsByCustomerin interfaceCustomerCouponDao- Parameters:
customer- the customer model- Returns:
- the list of CustomerCouponModel
-
checkCustomerCouponAvailableForCustomer
Description copied from interface:CustomerCouponDaoChecks if the customer coupon is available for the customer- Specified by:
checkCustomerCouponAvailableForCustomerin interfaceCustomerCouponDao- Parameters:
couponCode- the coupon codecustomer- the customer model- Returns:
- true if the coupon is available for the customer and false otherwise
-
countAssignedCouponForCustomer
Description copied from interface:CustomerCouponDaoCounts the assigned customer coupons for the customer by coupon code- Specified by:
countAssignedCouponForCustomerin interfaceCustomerCouponDao- Parameters:
couponCode- the coupon codecustomer- the customer model- Returns:
- the total number of assigned coupons
-
findAssignableCoupons
Description copied from interface:CustomerCouponDaoFinds assignable customer coupons for the customer by search text- Specified by:
findAssignableCouponsin interfaceCustomerCouponDao- Parameters:
customer- the customer modeltext- the text used for searching assignable customer coupons- Returns:
- the list of CustomerCouponModel
-
findAssignedCouponsByCustomer
Description copied from interface:CustomerCouponDaoFinds assigned customer coupons by the customer and search text- Specified by:
findAssignedCouponsByCustomerin interfaceCustomerCouponDao- Parameters:
customer- the customer modeltext- the text used for searching assigned customer coupons- Returns:
- the list of CustomerCouponModel
-
buildParamsMapForAssignableCoupons
-
buildQueryParamsForAssignedCoupons
-
findAssignmentCoupons
protected List<CustomerCouponModel> findAssignmentCoupons(CustomerModel customer, String text, String query, Map<String, Object> params) -
findPaginatedCouponsByCustomer
public SearchPageData<CustomerCouponModel> findPaginatedCouponsByCustomer(CustomerModel customer, SearchPageData searchPageData) Description copied from interface:CustomerCouponDaoFinds paginated customer coupons by the customer and searchPageData- Specified by:
findPaginatedCouponsByCustomerin interfaceCustomerCouponDao- Parameters:
customer- the customer modelsearchPageData- the data used for pagination- Returns:
- the paginated CustomerCouponModel
-
getPagedFlexibleSearchService
-
setPagedFlexibleSearchService
-
getPaginatedFlexibleSearchService
-
setPaginatedFlexibleSearchService
public void setPaginatedFlexibleSearchService(PaginatedFlexibleSearchService paginatedFlexibleSearchService) -
getCustomerCouponSortCodeToQueryAlias
-
setCustomerCouponSortCodeToQueryAlias
-