Skip to content

CatalogPricingConditionRuleInterface ​

Type
Interface
Namespace
craft\commerce\base
Extends
craft\base\conditions\ConditionRuleInterface
Implemented by
craft\commerce\elements\conditions\purchasables\CatalogPricingCustomerConditionRule, craft\commerce\elements\conditions\purchasables\CatalogPricingPurchasableConditionRule
Since
5.0.0

CatalogPricingConditionRuleInterface defines the common interface to be implemented by catalog pricing condition rule classes.

View source

Public Methods ​

MethodDescription
displayName()Returns the display name of this class.
extraFields()Returns the list of additional fields that can be returned by toArray() in addition to those listed in fields().
fields()Returns the list of fields that should be returned by default by toArray() when no specific fields are specified.
getAutofocus()Returns whether the rule’s type selector should be autofocused.
getCondition()Returns the condition associated with this rule.
getConfig()Returns the rule’s portable config.
getExclusiveQueryParams()Returns the query param names that this rule should have exclusive control over.
getGroupLabel()Returns the optgroup label the condition rule should be grouped under.
getHtml()Returns the rule’s HTML for a condition builder.
getLabel()Returns the rule’s option label.
getLabelHint()Returns the rule’s option label hint.
instance()Returns static class instance, which can be used to obtain meta information.
isSelectable()Returns whether the component should be selectable in component Type selects.
modifyQuery()Modifies the given query with the condition rule.
setAutofocus()Sets whether the rule’s type selector should be autofocused.
setCondition()Sets the condition associated with this rule.
supportsProjectConfig()Returns whether the rule is safe to include in conditions that are stored in the project config.
toArray()Converts the object into an array.

getExclusiveQueryParams() ​

Returns the query param names that this rule should have exclusive control over.

View source

Returns ​

string[]

modifyQuery() ​

Modifies the given query with the condition rule.

View source

Arguments ​