You are here

public function Webform::getNumberOfActions in Webform 6.x

Same name and namespace in other branches
  1. 8.5 src/Entity/Webform.php \Drupal\webform\Entity\Webform::getNumberOfActions()

Get the number of actions (aka submit buttons).

Return value

int The number of actions (aka submit buttons).

Overrides WebformInterface::getNumberOfActions

1 call to Webform::getNumberOfActions()
Webform::hasActions in src/Entity/Webform.php
Determine if the webform has any custom actions (aka submit buttons).

File

src/Entity/Webform.php, line 852

Class

Webform
Defines the webform entity.

Namespace

Drupal\webform\Entity

Code

public function getNumberOfActions() {
  $this
    ->initElements();
  return count($this->elementsActions);
}