Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class HalPublicationBlock extends BlockBase implements BlockPluginInterface
- {
- /**
- * {@inheritdoc}
- */
- public function build()
- {
- //do contain id but not bid
- $config = $this->getConfiguration();
- //$bid=$this->get->?
- /**
- * {@inheritdoc}
- */
- public function blockSubmit($form, FormStateInterface $form_state) {
- $block_id = $form['id']['#default_value'];
- $this->configuration['block_class'] = $block_id;
- }
- $formObject = $form_state->getFormObject()
- /** @var DrupalblockBlockInterface $block */
- $block = $formObject->getEntity();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement