You are here

public function YamlFormSubmissionStorage::getPreviousSubmission in YAML Form 8

Get a form submission's previous sibling.

Parameters

\Drupal\yamlform\YamlFormSubmissionInterface $yamlform_submission: A form submission.

\Drupal\Core\Entity\EntityInterface|null $source_entity: (optional) A form submission source entity.

\Drupal\Core\Session\AccountInterface $account: The current user account.

Return value

\Drupal\yamlform\YamlFormSubmissionInterface|null The form submission's previous sibling.

Overrides YamlFormSubmissionStorageInterface::getPreviousSubmission

File

src/YamlFormSubmissionStorage.php, line 184

Class

YamlFormSubmissionStorage
Defines the form submission storage.

Namespace

Drupal\yamlform

Code

public function getPreviousSubmission(YamlFormSubmissionInterface $yamlform_submission, EntityInterface $source_entity = NULL, AccountInterface $account = NULL) {
  return $this
    ->getSiblingSubmission($yamlform_submission, $source_entity, $account, 'previous');
}