Constructor
new VlocityDCOfferGroupSelection()
Properties:
Name | Type | Description |
---|---|---|
childProduct |
OfferObject | child offer object |
currentPlanGroup |
OfferProductGroupObject | current plan group |
type |
String | vlocity-dc-offer-group-selection type(e.g. "radio" or "checkbox") |
paymentTypeDesc |
String | payment type description. |
price |
String | One Time or recurring charge value |
isRecurring |
Boolean | price type is recurring or one time. |
Example
Sample Usage -
Include the component in your template simply by adding vlocity-dc-offer-group-selection custom tag
<vlocity-dc-offer-group-selection .type="${"radio"}" .childProduct="${planOption}" .currentplangroup="${currentPlanGroup} isRecurring=false"
></vlocity-dc-offer-group-selection>
--------------------------------------------------------------------------------------------------------------------------------------
KEY INFO -
events fired : vlocity-dc-save-child-offers and vlocity-dc-refresh-offer-groups
events registered :
| Event Name | Event source component | Callback Function |
|------------------------------------|---------------------------------------------------------------------------------------------------------|------------------------|
| | Mutiple Event Sources: | |
| | | Component Name | Description | | |
| vlocity-dc-refresh-offer-groups | |---------------------------------------|-----------------------------------------------------| | refreshPage() |
| | | vlocity-dc-offer-addons | Event for refreshing offer groups | | |
| | | vlocity-dc-offer-group-sections | | | |
| | | vlocity-dc-offer-group-selection | | | |
Dependency - vlocity-dc-offer-group-selection is a component that has no dependency on parent component.
| Parent Component | Expected Child Component |
|------------------|---------------------------|
| none | none |
Sample with slots -
<vlocity-dc-offer-group-selection>
<span slot="{slot_name}">
Custom HTML elements goes here
</span>
</vlocity-dc-offer-group-selection>
List of available slots -
| Slot names | Dynamic | Description | Impact |
|---------------------------------------|-------------|-----------------------------------------------------------|
| dc-group-selection-radio-wrapper | - | Wrapper for component | Replaces template DOM |
| dc-product-description | - | Wrapper for productDescription | Replaces DOM |
| dc-product-payment | - | Wrapper for productPaymentSlot | Replaces DOM |
| dc-group-selection-checkbox-wrapper | - | Wrapper for checkbox | Replaces DOM |
| dc-product-description | - | Wrapper for productDescription | Replaces DOM |
| dc-child-product-payment | - | Wrapper for childProductPayment | Replaces DOM |
Extends
- LitElement
Members
(static, readonly) properties
Properties that will be available in the binding system
Properties:
Name | Type | Description |
---|---|---|
childProduct |
OfferObject | child offer object |
isRecurring |
Boolean | price type is recurring or one time. |
currentPlanGroup |
OfferProductGroupObject | current plan group |
type |
String | vlocity-dc-offer-group-selection type(e.g. "radio" or "checkbox") |
paymentTypeDesc |
String | payment type description. |
price |
String | One Time or recurring charge value |
Methods
(static) connectedCallback()
Invoked when vlocity-dc-offer-group-selection component is added to the document’s DOM.
(static) refreshPage(data)
callback function for event vlocity-dc-refresh-offer-groups.
Parameters:
Name | Type | Description |
---|---|---|
data |
ConfiguredOfferObject | configured offer. |
(static) updateAddon(context)
Invoked on click of vlocity-dc-offer-group-selection.
Parameters:
Name | Type | Description |
---|---|---|
context |
Object | offer group selection component object. |