Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

31 lines
981B

  1. <?php
  2. namespace Lc\PietroBundle\Controller\Workshop;
  3. use EasyCorp\Bundle\EasyAdminBundle\Config\Action;
  4. use EasyCorp\Bundle\EasyAdminBundle\Config\Actions;
  5. use EasyCorp\Bundle\EasyAdminBundle\Config\Crud;
  6. use Lc\PietroBundle\Controller\AbstractAdminController;
  7. use Lc\PietroBundle\Model\Workshop\EntryInterface;
  8. use Lc\SovBundle\Generator\CsvGenerator;
  9. use Lc\SovBundle\Repository\RepositoryQueryInterface;
  10. use Symfony\Component\HttpFoundation\Request;
  11. abstract class SolutionAdminController extends AbstractAdminController
  12. {
  13. public function createEntity(string $entityFqcn)
  14. {
  15. return $this->getSolutionContainer()->getFactory()->create();
  16. }
  17. public function getRepositoryQuery(): RepositoryQueryInterface
  18. {
  19. return $this->getSolutionContainer()->getRepositoryQuery();
  20. }
  21. public function configureFields(string $pageName): iterable
  22. {
  23. return $this->getSolutionContainer()->getFieldDefinition()->getFields($pageName);
  24. }
  25. }