Class PromotionTypeHandler
Provides the capability to show or hide specific promotion types that inherit from PromotionData.
Inheritance
Inherited Members
Namespace: EPiServer.Commerce.Marketing
Assembly: EPiServer.Business.Commerce.dll
Version: 13.30.0Syntax
public class PromotionTypeHandler
Constructors
PromotionTypeHandler(IContentTypeRepository, ITypeScannerLookup)
Creates an instance of PromotionTypeHandler.
Declaration
public PromotionTypeHandler(IContentTypeRepository contentTypeRepository, ITypeScannerLookup typeScannerLookup)
Parameters
Type | Name | Description |
---|---|---|
EPiServer.DataAbstraction.IContentTypeRepository | contentTypeRepository | The content type repository. |
EPiServer.Framework.TypeScanner.ITypeScannerLookup | typeScannerLookup | The type scanner lookup. |
Methods
DisableBuiltinPromotions()
Disables all built-in promotion types that inherit from PromotionData.
Declaration
public void DisableBuiltinPromotions()
DisablePromotions(IEnumerable<Type>)
Disables specific promotions which inherit from PromotionData.
Declaration
public void DisablePromotions(IEnumerable<Type> promotionTypes)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Type> | promotionTypes | The collection of promotion types that need to be disabled. |
Remarks
The promotion types must inherit from PromotionData.
EnablePromotions(IEnumerable<Type>)
Enables specific promotions which inherit from PromotionData.
Declaration
public void EnablePromotions(IEnumerable<Type> promotionTypes)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Type> | promotionTypes | The collection of promotion types that need to be enabled. |
Remarks
The promotion types must inherit from PromotionData.
GetAllPromotionTypes()
Gets all promotion types that inherit from PromotionData.
Declaration
public IEnumerable<Type> GetAllPromotionTypes()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Type> | The collection of promotion types. |
Remarks
The abstract types are not included.