public function TopDownload::blockForm in Download Count 8
Overrides BlockPluginTrait::blockForm
File
- src/
Plugin/ Block/ TopDownload.php, line 71
Class
- TopDownload
- Provides a 'Top Downloaded Files' block.
Namespace
Drupal\download_count\Plugin\BlockCode
public function blockForm($form, FormStateInterface $form_state) {
$form = parent::blockForm($form, $form_state);
$config = $this
->getConfiguration();
$form['download_count_top_block_limit'] = [
'#type' => 'textfield',
'#title' => $this
->t('Number of items to display'),
'#default_value' => isset($config['download_count_top_block_limit']) ? $config['download_count_top_block_limit'] : 10,
];
return $form;
}