You are here

public function OgFieldBase::setFieldName in Organic groups 8

Set the field name.

The field name is often the same as the plugin ID, however it is overridable. For example, the group audience field is identified as \Drupal\og\OgGroupAudienceHelper::DEFAULT_FIELD, however the actual field name attached to the bundle can be arbitrary.

Parameters

string $field_name: The field name.

Return value

$this

Overrides OgFieldsInterface::setFieldName

File

src/OgFieldBase.php, line 90

Class

OgFieldBase
OG related fields base plugin.

Namespace

Drupal\og

Code

public function setFieldName($field_name) {
  $this->fieldName = $field_name;
  return $this;
}