public function ConfirmClearForm::buildForm in Queue UI 8.2
Form constructor.
Parameters
array $form: An associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Return value
array The form structure.
Overrides ConfirmFormBase::buildForm
File
- src/
Form/ ConfirmClearForm.php, line 55
Class
- ConfirmClearForm
- Class ConfirmClearForm @package Drupal\queue_ui\Form
Namespace
Drupal\queue_ui\FormCode
public function buildForm(array $form, FormStateInterface $form_state) {
// Retrieve the queues to be deleted from the temp store.
$queues = $this->tempStoreFactory
->get('queue_ui_clear_queues')
->get($this
->currentUser()
->id());
if (!$queues) {
return $this
->redirect('queue_ui.overview_form');
}
return parent::buildForm($form, $form_state);
}