You are here

public function CatalogBlock::blockForm in Ubercart 8.4

Overrides BlockPluginTrait::blockForm

File

uc_catalog/src/Plugin/Block/CatalogBlock.php, line 95

Class

CatalogBlock
Provides the product catalog block.

Namespace

Drupal\uc_catalog\Plugin\Block

Code

public function blockForm($form, FormStateInterface $form_state) {
  $form['link_title'] = [
    '#type' => 'checkbox',
    '#title' => $this
      ->t('Make the block title a link to the top-level catalog page.'),
    '#default_value' => $this->configuration['link_title'],
  ];
  $form['expanded'] = [
    '#type' => 'checkbox',
    '#title' => $this
      ->t('Always expand categories.'),
    '#default_value' => $this->configuration['expanded'],
  ];
  $form['product_count'] = [
    '#type' => 'checkbox',
    '#title' => $this
      ->t('Display product counts.'),
    '#default_value' => $this->configuration['product_count'],
  ];
  return $form;
}