function EntityTestRevPub::baseFieldDefinitions

Same name in other branches
  1. 9 core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRevPub.php \Drupal\entity_test\Entity\EntityTestRevPub::baseFieldDefinitions()
  2. 10 core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRevPub.php \Drupal\entity_test\Entity\EntityTestRevPub::baseFieldDefinitions()
  3. 11.x core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRevPub.php \Drupal\entity_test\Entity\EntityTestRevPub::baseFieldDefinitions()

Overrides EntityTestRev::baseFieldDefinitions

File

core/modules/system/tests/modules/entity_test/src/Entity/EntityTestRevPub.php, line 55

Class

EntityTestRevPub
Defines the test entity class.

Namespace

Drupal\entity_test\Entity

Code

public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
    $fields = parent::baseFieldDefinitions($entity_type);
    // Add the publishing status field.
    $fields += static::publishedBaseFieldDefinitions($entity_type);
    return $fields;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.