pm-4.1.x-dev/modules/pm_epic/src/Entity/PmEpic.php
modules/pm_epic/src/Entity/PmEpic.php
<?php
namespace Drupal\pm_epic\Entity;
use Drupal\pm_epic\PmEpicInterface;
use Drupal\pm\PmContentEntityBase;
/**
* Defines the pm epic entity class.
*
* @ContentEntityType(
* id = "pm_epic",
* label = @Translation("Epic"),
* label_collection = @Translation("Epics"),
* label_singular = @Translation("Epic"),
* label_plural = @Translation("Epics"),
* label_count = @PluralTranslation(
* singular = "@count Epics",
* plural = "@count Epics",
* ),
* bundle_label = @Translation("Epic type"),
* handlers = {
* "list_builder" = "Drupal\pm_epic\PmEpicListBuilder",
* "views_data" = "Drupal\views\EntityViewsData",
* "access" = "Drupal\pm_epic\PmEpicAccessControlHandler",
* "form" = {
* "add" = "Drupal\pm_epic\Form\PmEpicForm",
* "edit" = "Drupal\pm_epic\Form\PmEpicForm",
* "delete" = "Drupal\Core\Entity\ContentEntityDeleteForm",
* },
* "route_provider" = {
* "html" = "Drupal\Core\Entity\Routing\AdminHtmlRouteProvider",
* }
* },
* base_table = "pm_epic",
* admin_permission = "administer pm epic types",
* entity_keys = {
* "id" = "id",
* "bundle" = "bundle",
* "label" = "label",
* "uuid" = "uuid",
* "owner" = "uid",
* },
* links = {
* "collection" = "/admin/pm/epic",
* "add-form" = "/pm/epic/add/{pm_epic_type}",
* "add-page" = "/pm/epic/add",
* "canonical" = "/pm/epic/{pm_epic}",
* "edit-form" = "/pm/epic/{pm_epic}/edit",
* "delete-form" = "/pm/epic/{pm_epic}/delete",
* },
* bundle_entity_type = "pm_epic_type",
* field_ui_base_route = "entity.pm_epic_type.edit_form",
* )
*/
class PmEpic extends PmContentEntityBase implements PmEpicInterface {
/**
* {@inheritdoc}
*/
public static function getPmContentEntityBaseFieldNames() {
return [
'pm_key',
'pm_project',
'pm_date',
'pm_status',
'pm_priority',
'pm_feature_list',
'pm_assignee',
'pm_reviewer',
];
}
}
