This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Route name can be used in several place (links, redirects, local actions etc.) | |
entity.content_entity_manage_inventory.canonical: | |
path: '/content_entity_manage_inventory/{content_entity_manage_inventory}' | |
defaults: | |
# Calls the view controller, defined in the annotation of the contact entity | |
_entity_view: 'content_entity_manage_inventory' | |
_title: 'Inventory Content' | |
requirements: | |
# Calls the access controller of the entity, $operation 'view' | |
_entity_access: 'content_entity_manage_inventory.view' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Manage Inventory | |
type: module | |
description: 'Provides Inventory entity.' | |
package: Custom | |
core: 8.x | |
package: Custom |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# All action links for this module | |
manage_inventory.inventory_add: | |
# Which route will be called by the link | |
route_name: entity.manage_inventory.add_form | |
title: 'Add Inventory' | |
# Where will the link appear, defined by route name. | |
appears_on: | |
- entity.content_entity_manage_inventory.collection |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Define the 'local' links for the module | |
inventory.settings_tab: | |
route_name: manage_inventory.inventory_settings | |
title: Settings | |
base_route: manage_inventory.inventory_settings | |
inventory.view: | |
route_name: entity.content_entity_manage_inventory.canonical | |
base_route: entity.content_entity_manage_inventory.canonical |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Drupal\manage_inventory; | |
use Drupal\Core\Entity\ContentEntityInterface; | |
use Drupal\user\EntityOwnerInterface; | |
use Drupal\Core\Entity\EntityChangedInterface; | |
/** | |
* Provides an interface defining a Inventory entity. | |
* @ingroup manage_inventory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @file | |
* Contains \Drupal\manage_inventory\Entity\Contact. | |
*/ | |
namespace Drupal\manage_inventory\Entity; | |
use Drupal\Core\Entity\EntityStorageInterface; | |
use Drupal\Core\Field\BaseFieldDefinition; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Drupal\manage_inventory\Form; | |
use Drupal\Core\Entity\ContentEntityForm; | |
use Drupal\Core\Language\Language; | |
use Drupal\Core\Form\FormStateInterface; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Drupal\manage_inventory\Form; | |
use Drupal\Core\Entity\ContentEntityConfirmFormBase; | |
use Drupal\Core\Form\FormStateInterface; | |
use Drupal\Core\Url; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Drupal\manage_inventory\Entity\Controller; | |
use Drupal\Core\Entity\EntityInterface; | |
use Drupal\Core\Entity\EntityListBuilder; | |
use Drupal\Core\Url; | |
/** | |
* Provides a list controller for content_entity_manage_inventory entity. | |
* |
OlderNewer