Read-only view over a promotion's stored configuration properties - entry codes, discount and gift settings, quiz and upload options, and qualifying product categories - loaded from the reward.properties file held against the reward. Produced by PromotionService.promotionDetails and consumed by cart pricing, checkout rules and points rule evaluation to decide whether and how a promotion applies.


Properties

PropertyReturnsDescription
allowAnonbooleanWhether anonymous (not logged in) users are allowed to enter this promotion.
backgroundImageStringPath or URL of the background image configured for this promotion.
detailsStringFree-text details configured for this promotion.
enterablebooleanWhether this promotion can currently be entered, ie whether either quiz entry or user upload entry is enabled.
maxCartCostIntegerMaximum cart cost a cart may have to still qualify for this promotion.
maxToGiftIntegerMaximum quantity of the free gift a single cart can receive under this promotion.
minCartCostIntegerMinimum cart cost a cart must reach to qualify for this promotion.
productCategoriesStringRaw, comma-separated product category names configured for this promotion, used for form promotions.
productCategoriesListList<String>Product category names configured for this promotion, used for form promotions, split from the raw comma-separated getProductCategories value.
promoCategoryCodesStringRaw, delimiter-separated category codes that qualify a cart for this promotion.
promoDiscountAmountBigDecimalDiscount amount applied by this promotion, when isPromoDiscountEnabled is true.
promoDiscountEnabledbooleanWhether this promotion applies a discount.
promoEntryCodesStringRaw, delimiter-separated entry codes for this promotion. If set, a user must enter one of these codes to activate the promotion.
promoGiftEnabledbooleanWhether this promotion gives a free gift item.
promoGiftSkuStringSKU code of the free gift product given by this promotion, when isPromoGiftEnabled is true.
promoProductCodesStringRaw, delimiter-separated product codes that qualify a cart for this promotion.
qualifyingCategoriesStringRaw, comma-separated names of the product categories that qualify a cart item for this checkout promotion.
qualifyingCategoriesListList<String>Names of the product categories that qualify a cart item for this checkout promotion, split from the raw comma-separated getQualifyingCategories value.
quizEnabledbooleanWhether participants can enter this promotion by completing a quiz.
quizHtmlStringThe promotion's quiz content, rendered from the configured quizHtml MVEL template. Computed once and cached.
rewardIdlongDatabase ID of the promotion (Reward) these details belong to.
selectOrgbooleanWhether the entrant is required to select an organisation when entering this promotion.
selectOrgTypeStringThe organisation type the entrant must select from, when isSelectOrg is true.
selectProductbooleanWhether the entrant is required to select a product when entering this promotion.
storeNameStringName of the store this promotion applies to.
userUploadEnabledbooleanWhether participants can enter this promotion by uploading content.
userUploadMessageStringMessage shown to the user when uploading content for this promotion, rendered from the configured userUploadMessage MVEL template. Computed once and cached.

Methods

getRewardId() · reward() · getUserUploadMessage() · isUserUploadEnabled() · isQuizEnabled() · getQuizHtml() · getDetails() · isAllowAnon() · isSelectOrg() · isEnterable() · getSelectOrgType() · getProductCategories() · getStoreName() · getPromoProductCodes() · getPromoCategoryCodes() · getPromoEntryCodes() · isPromoDiscountEnabled() · getPromoDiscountAmount() · isPromoGiftEnabled() · getPromoGiftSku() · getMaxToGift() · getMaxCartCost() · getMinCartCost() · getProductCategoriesList() · isSelectProduct() · getBackgroundImage() · getQualifyingCategories() · getQualifyingCategoriesList()

getRewardId()

Returns: long

Database ID of the promotion (Reward) these details belong to.

reward()

Returns: Reward

The promotion (Reward) these details belong to.

getUserUploadMessage()

Returns: String

Message shown to the user when uploading content for this promotion, rendered from the configured userUploadMessage MVEL template. Computed once and cached.

isUserUploadEnabled()

Returns: boolean

Whether participants can enter this promotion by uploading content.

isQuizEnabled()

Returns: boolean

Whether participants can enter this promotion by completing a quiz.

getQuizHtml()

Returns: String

The promotion's quiz content, rendered from the configured quizHtml MVEL template. Computed once and cached.

getDetails()

Returns: String

Free-text details configured for this promotion.

isAllowAnon()

Returns: boolean

Whether anonymous (not logged in) users are allowed to enter this promotion.

isSelectOrg()

Returns: boolean

Whether the entrant is required to select an organisation when entering this promotion.

isEnterable()

Returns: boolean

Whether this promotion can currently be entered, ie whether either quiz entry or user upload entry is enabled.

getSelectOrgType()

Returns: String

The organisation type the entrant must select from, when isSelectOrg is true.

getProductCategories()

Returns: String

Raw, comma-separated product category names configured for this promotion, used for form promotions.

getStoreName()

Returns: String

Name of the store this promotion applies to.

getPromoProductCodes()

Returns: String

Raw, delimiter-separated product codes that qualify a cart for this promotion.

getPromoCategoryCodes()

Returns: String

Raw, delimiter-separated category codes that qualify a cart for this promotion.

getPromoEntryCodes()

Returns: String

Raw, delimiter-separated entry codes for this promotion. If set, a user must enter one of these codes to activate the promotion.

isPromoDiscountEnabled()

Returns: boolean

Whether this promotion applies a discount.

getPromoDiscountAmount()

Returns: BigDecimal

Discount amount applied by this promotion, when isPromoDiscountEnabled is true.

isPromoGiftEnabled()

Returns: boolean

Whether this promotion gives a free gift item.

getPromoGiftSku()

Returns: String

SKU code of the free gift product given by this promotion, when isPromoGiftEnabled is true.

getMaxToGift()

Returns: Integer

Maximum quantity of the free gift a single cart can receive under this promotion.

getMaxCartCost()

Returns: Integer

Maximum cart cost a cart may have to still qualify for this promotion.

getMinCartCost()

Returns: Integer

Minimum cart cost a cart must reach to qualify for this promotion.

getProductCategoriesList()

Returns: List<String>

Product category names configured for this promotion, used for form promotions, split from the raw comma-separated getProductCategories value.

isSelectProduct()

Returns: boolean

Whether the entrant is required to select a product when entering this promotion.

getBackgroundImage()

Returns: String

Path or URL of the background image configured for this promotion.

getQualifyingCategories()

Returns: String

Raw, comma-separated names of the product categories that qualify a cart item for this checkout promotion.

getQualifyingCategoriesList()

Returns: List<String>

Names of the product categories that qualify a cart item for this checkout promotion, split from the raw comma-separated getQualifyingCategories value.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.