You are here

public function CouponRedemption::buildOptionsForm in Commerce Core 8.2

Provide a form to edit options for this plugin.

Overrides AreaPluginBase::buildOptionsForm

File

modules/promotion/src/Plugin/views/area/CouponRedemption.php, line 90

Class

CouponRedemption
Defines a coupon redemption area handler.

Namespace

Drupal\commerce_promotion\Plugin\views\area

Code

public function buildOptionsForm(&$form, FormStateInterface $form_state) {
  parent::buildOptionsForm($form, $form_state);
  $form['empty']['#description'] = $this
    ->t("Even if selected, this area handler will never render if a valid order cannot be found in the View's arguments.");
  $form['allow_multiple'] = [
    '#type' => 'checkbox',
    '#title' => $this
      ->t('Allow multiple coupons to be redeemed'),
    '#default_value' => $this->options['allow_multiple'],
  ];
}