Skip to content
Snippets Groups Projects

Resolve #3468898 "Entity usage autowire aliases"

7 unresolved threads

Closes #3468898

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
12 12 */
13 13 class BatchUpdateForm extends FormBase {
14 14
15 /**
16 * The EntityUsageBatchManager service.
17 *
18 * @var \Drupal\entity_usage\EntityUsageBatchManager
19 */
20 protected $batchManager;
21
22 15 /**
23 16 * BatchUpdateForm constructor.
  • 16 * The EntityUsageBatchManager service.
    17 *
    18 * @var \Drupal\entity_usage\EntityUsageBatchManager
    19 */
    20 protected $batchManager;
    21
    22 15 /**
    23 16 * BatchUpdateForm constructor.
    24 *
    25 * @param \Drupal\entity_usage\EntityUsageBatchManager $batch_manager
    26 * The entity usage batch manager.
    27 17 */
    28 public function __construct(EntityUsageBatchManager $batch_manager) {
    29 $this->batchManager = $batch_manager;
    18 final public function __construct(
    19 private EntityUsageBatchManager $batchManager,
  • 53 /**
    54 * Construct the EntityUsage object.
    55 *
    56 * @param \Drupal\Core\Database\Connection $connection
    57 * The database connection which will be used to store the entity usage
    58 * information.
    59 * @param \Symfony\Component\EventDispatcher\EventDispatcherInterface $event_dispatcher
    60 * An event dispatcher instance to use for events.
    61 * @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
    62 * The config factory.
    63 * @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
    64 * The ModuleHandler service.
    65 * @param string $table
    66 * (optional) The table to store the entity usage info. Defaults to
    67 * 'entity_usage'.
    19 * Construct the EntityUsage service.
  • 66 * (optional) The table to store the entity usage info. Defaults to
    67 * 'entity_usage'.
    19 * Construct the EntityUsage service.
    68 20 */
    69 public function __construct(Connection $connection, EventDispatcherInterface $event_dispatcher, ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, $table = 'entity_usage') {
    70 $this->connection = $connection;
    71 $this->tableName = $table;
    72 $this->eventDispatcher = $event_dispatcher;
    73 $this->moduleHandler = $module_handler;
    74 $this->config = $config_factory->get('entity_usage.settings');
    21 final public function __construct(
    22 private Connection $connection,
    23 private EventDispatcherInterface $eventDispatcher,
    24 private ConfigFactoryInterface $configFactory,
    25 private ModuleHandlerInterface $moduleHandler,
    26 private string $tableName,
  • 27 /**
    28 * The entity type manager.
    29 *
    30 * @var \Drupal\Core\Entity\EntityTypeManagerInterface
    31 */
    32 protected $entityTypeManager;
    33
    34 /**
    35 * The entity usage configuration.
    36 *
    37 * @var \Drupal\Core\Config\Config
    38 */
    39 protected $config;
    40
    41 28 /**
    42 29 * Creates a EntityUsageBatchManager object.
  • 30 /**
    31 * The entity type manager.
    32 *
    33 * @var \Drupal\Core\Entity\EntityTypeManagerInterface
    34 */
    35 protected $entityTypeManager;
    36
    37 /**
    38 * The entity usage configuration.
    39 *
    40 * @var \Drupal\Core\Config\Config
    41 */
    42 protected $config;
    43
    44 28 /**
    45 29 * Creates a EntityUsageQueueBatchManager object.
  • 1 1 name: Entity Usage
    2 2 type: module
    3 3 description: Track usage of entities referenced by other entities.
    4 core_version_requirement: ^10.1 || ^11
    4 core_version_requirement: ^10.2 || ^11
  • Marcos Cano added 4 commits

    added 4 commits

    • eb0e921f - 1 commit from branch project:8.x-2.x
    • 8946b3fe - autowire/autoconfigure/logger/containerinjection
    • d7a19b80 - fix event dispatcher autowiring, prefill tablename from service container...
    • d0de2307 - add interface and trait per https://www.drupal.org/node/3395436

    Compare with previous version

  • merged

  • Please register or sign in to reply
    Loading