You are here

public function CurrentContact::getArgument in RedHen CRM 8

Return the default argument.

This needs to be overridden by every default argument handler to properly do what is needed.

Overrides ArgumentDefaultPluginBase::getArgument

File

modules/redhen_contact/src/Plugin/views/argument_default/CurrentContact.php, line 25

Class

CurrentContact
Default argument plugin to extract the current user's Redhen Contact.

Namespace

Drupal\redhen_contact\Plugin\views\argument_default

Code

public function getArgument() {
  return Contact::loadByUser(\Drupal::currentUser())
    ->id();
}