public function MigrationFormBase::__construct in Migrate Tools 8
Same name and namespace in other branches
- 8.2 src/Form/MigrationFormBase.php \Drupal\migrate_tools\Form\MigrationFormBase::__construct()
- 8.3 src/Form/MigrationFormBase.php \Drupal\migrate_tools\Form\MigrationFormBase::__construct()
- 8.4 src/Form/MigrationFormBase.php \Drupal\migrate_tools\Form\MigrationFormBase::__construct()
Construct the MigrationGroupFormBase.
For simple entity forms, there's no need for a constructor. Our migration form base, however, requires an entity query factory to be injected into it from the container. We later use this query factory to build an entity query for the exists() method.
Parameters
\Drupal\Core\Entity\Query\QueryFactory $query_factory: An entity query factory for the migration group entity type.
File
- src/
Form/ MigrationFormBase.php, line 42 - Contains Drupal\migrate_tools\Form\MigrationFormBase.
Class
- MigrationFormBase
- Class MigrationFormBase.
Namespace
Drupal\migrate_tools\FormCode
public function __construct(QueryFactory $query_factory) {
$this->entityQueryFactory = $query_factory;
}