Document Tree
Document Properties
Kbid
K28256
Last Modified
13-Oct-2021
Added to KB
07-Jun-2017
Public Access
Everyone
Status
Online
Doc Type
Concepts
Product
  • ICM 7.10
  • ICM 11
  • ICM 12
Concept - Promotion Activation Status and Accessibility

Introduction

It is often a non-trivial problem to determine if a promotion can be applied. Besides some general aspects, e.g., is the promotion enabled, has the promotion an adequate start and end date, there are some more aspects to consider which might influence the visibility and validity of a promotion like A/B test, affiliates or customer segmentation. These aspects strongly depend on the currently logged in user (customer) and on the used application (B2C, B2B).

All the mentioned aspects have to be considered for all Business Objects that are related to promotions (PromotionCode, PromotionCodeGroup, Promotion, Campaign).

In order to reduce some complexity and to cluster the related topics, two viewpoints have been introduced: Activation status and Accessibility.

Activation status contains all aspects that determine whether a promotion object is enabled and available in general. This includes:

  • Object is enabled
  • Object is available (if flag exist)
  • Object start / end date matches the current instant of time (Preview configuration is also considered)

Accessibility means that a promotion object is accessible for the current user (customer) in the context of the current application. This includes:

  • Object is assigned to the current application
  • Object is somehow assigned to the current user. This assignment is based on Usergroups and UserGroup relations and considers assignment of customers, customer segments, A/B tests (included and excluded) as well as affiliates

The term promotion object is used as a placeholder for all promotion-related business objects: PromotionCode, PromotionCodeGroup, Promotion and Campaign.

Both viewpoints are described in detail in the next paragraphs.

Activation Status

As mentioned above, the activation status describes whether a promotion object is generally available and enabled. Every business object might have different aspects to be considered to determine whether it is active or not. In order to provide an extendable and exchangeable solution the determination of the activation status is computed by external handlers. There are different type of handlers for the different business objects PromotionCode, PromotionCodeGroup, Promotion and, Campaign.

The handlers are wired via Java extension points and can be be extended or exchanged. If there are no handlers available, the promotion object is treated as active by default. If there are multiple handlers, the results are combined by logical AND, which means, that a promotion object is only declared as active, when ALL handlers declare it as active.

The following picture shows the overall workflow containing all relevant promotion business objects. If an object is asked for "isActive()", then it will call its connected "...BOIsActiveHandlers". If the combined result is true, the next higher level object is also asked. If the object on the "next level" does not exist or is not relevant, it will be skipped. E.g., PromotionCodeBO with single code has no promotion code group, or promotions without campaign.

Example: A promotion with a promotion code based on a promotion code group, where the promotion is assigned to campaign:

PromotionCodeBO.isActive() -> calls all PromotionCodeBOIsActiveHandlers -> if result is true -> call PromotionCodeGroupBO.isActive() -> calls all PromotionCodeGroupBOIsActiveHandlers -> if result is true -> call PromotionBO.isActive() -> calls all PromotionBOIsActiveHandlers -> if result is true -> CampaignBO.isActive() -> calls all CampaignBOIsActiveHandlers -> return result

A promotion code group can be assigned to multiple promotions. A promotion can also be assigned to multiple campaigns. If this is the case, then it is sufficient, that at least one of the objects on the next level is active.

The following diagram shows two examples. In the first example the promotion code is active, because there is one path from the root (promotion code) to a leaf (promotion), where all objects are active. In the second example the promotion code and promotion code group are both active, but the assigned promotions or the assigned campaign at the leaf of the tree are not active and as a result the promotion code is not active, too.

As mentioned above, the determination of the activation status is done by external handlers. The following table gives an overview about the handler implementations which are provided as standard.

Handler Interface / Extension point nameImplementationExtension nameChecks

PromotionCodeBOIsActiveHandler /
com.intershop.component.promotion.capi.PromotionCodeBOAccessibilityHandler-isActive

no default implementation-no checks - active by default
PromotionCodeGroupBOIsActiveHandler /
com.intershop.component.promotion.capi.PromotionCodeGroupBOAccessibilityHandler-isActive
PromotionCodeGroupBOIsActiveHandlerImplPromotionCodeGroupBOIsActiveHandlerEnable flag of the promotion code group
Promotion code group start and end date relating to evaluation date (preview time, session start time, current time)
PromotionBOIsActiveHandler /
com.intershop.component.promotion.capi.PromotionBOIsActiveHandler-isActive
PromotionBOIsActiveHandlerImplPromotionBOIsActiveHandlerEnable flag of the promotion
Promotion start and end date relating to evaluation date (preview time, session start time, current time)
all checks if promotion does not belong to a campaign
CampaignBOIsActiveHandler /
com.intershop.component.marketing.capi.campaign.CampaignBOIsActiveHandler-isActive
CampaignBOIsActiveHandlerImplCampaignBOIsActiveHandlerEnable flag of the campaign
Campaign start and end date relating to evaluation date (preview time, session start time, current time)

For adding additional handlers or replacing existing ones see Cookbook - Promotion Activation Status and Accessibility.

Accessibility

As mentioned above, the accessibility describes if a promotion object is accessible for the current user (customer) in the context of the current application. Every business object might have different aspects to be considered to determine whether it is accessible or not. In order to provide an extendable and exchangeable solution the determination of the accessibility is computed by external handlers. There are different types of handlers of the different business objects PromotionCode, PromotionCodeGroup, Promotion, and Campaign.

The handlers are wired via Java extension points and can therefore be extended or exchanged. If there are no handlers available, the promotion object is treated as accessible by default. If there are multiple handlers, the results are combined by logical AND, which means that a promotion object is only declared as accessible, when ALL handlers declare it as accessible.

The following picture shows the overall workflow containing all relevant promotion business objects. If an object is asked for "isAccessible()", it will call its connected "...BOAccessibilityHandlers". If the combined result is true, the next higher level object is also asked. If the object on the "next level" does not exist or is not relevant, it will be skipped. E.g., a PromotionCodeBO with single code has no promotion code group, or promotions without a campaign.

Example: A promotion with a promotion code based on a promotion code group, where the promotion is assigned to campaign:

PromotionCodeBO.isAccessible() -> calls all PromotionCodeBOAccessibilityHandlers -> if result is true -> call PromotionCodeGroupBO.isAccessible() -> calls all PromotionCodeGroupBOAccessibilityHandlers -> if result is true -> call PromotionBO.isAccessible() -> calls all PromotionBOAccessibilityHandlers -> if result is true -> CampaignBO.isAccessible() -> calls all CampaignBOAccessibilityHandlers -> return result

A promotion code group can be assigned to multiple promotions. A promotion can also be assigned to multiple campaigns. If this is the case, it is sufficient, that at least one of the objects on the next higher level is accessible.

The following diagram shows two examples. In the first example the promotion code is accessible, because there is one path from the root (promotion code) to a leaf (promotion) where all objects are accessible. In the second example the promotion code and promotion code group are both accessible, but the assigned promotions or the assigned campaign at the leaf of the tree are not accessible and as a result the promotion code is not accessible, too.

As mentioned above, the determination of the accessibility is done by external handlers. The following table gives an overview about the handler implementations which are provided as standard.

Handler Interface / Extension point nameImplementationExtension nameChecks
PromotionCodeBOAccessibilityHandler /
com.intershop.component.promotion.capi.PromotionCodeBOAccessibilityHandler-isAccessible
no default implementation-no checks - accessible by default
PromotionCodeGroupBOAccessibilityHandler /
com.intershop.component.promotion.capi.PromotionCodeGroupBOAccessibilityHandler-isAccessible
PromotionCodeGroupBOAccessibilityHandlerImplPromotionCodeGroupBOAccessibilityHandler

Is promotion code group available for the current application (Application assignment)?
Is promotion code group available for the current user (usergroup assignment)?

PromotionBOAccessibilityHandler /
com.intershop.component.promotion.capi.PromotionBOAccessibilityHandler-isAccessible

PromotionBOAccessibilityHandlerImpl

PromotionBOAccessibilityHandler

Is promotion available for the current application (Application assignment)?
Is promotion available for the current user (usergroup assignment)?

CampaignBOAccessibilityHandler /
com.intershop.component.marketing.capi.campaign.CampaignBOAccessibilityHandler-isAccessible
CampaignBOAccessibilityHandlerImplCampaignBOAccessibilityHandlerIs campaign available for the current user (usergroup assignment)?

For adding additional handlers or replacing existing ones see Cookbook - Promotion Activation Status and Accessibility.

Disclaimer
The information provided in the Knowledge Base may not be applicable to all systems and situations. Intershop Communications will not be liable to any party for any direct or indirect damages resulting from the use of the Customer Support section of the Intershop Corporate Web site, including, without limitation, any lost profits, business interruption, loss of programs or other data on your information handling system.
The Intershop Knowledge Portal uses only technically necessary cookies. We do not track visitors or have visitors tracked by 3rd parties. Please find further information on privacy in the Intershop Privacy Policy and Legal Notice.
Home
Knowledge Base
Product Releases
Log on to continue
This Knowledge Base document is reserved for registered customers.
Log on with your Intershop Entra ID to continue.
Write an email to supportadmin@intershop.de if you experience login issues,
or if you want to register as customer.