Your project controllers should only contains actions as public methods 2

More information: https://insight.symfony.com/what-we-analyse/symfony.controller.non_action_public_method_in_controller_class

  1. use EasyCorp\Bundle\EasyAdminBundle\Field\IdField;
  2. use EasyCorp\Bundle\EasyAdminBundle\Field\TextField;
  3. abstract class CountryCrudController extends AbstractCrudController
  4. {
  5. public function configureCrud(Crud $crud): Crud

    Non-action public method found in controller class

    Time to fix: about 1 hour
    Read doc Open Issue Permalink
    Last edited by Damien Lagae
  6. {
  7. return $crud
  8. ->setEntityLabelInSingular('enabel_partner_countries.admin.menu.country')
  9. ->setEntityLabelInPlural('enabel_partner_countries.admin.menu.countries')
  10. ->setPageTitle('index', '%entity_label_plural%')
  • damienlagae

    ok for me
    => because EasyAdmin
  1. }
  2. /**
  3. * @return iterable<FieldInterface>
  4. */
  5. public function configureFields(string $pageName): iterable

    Non-action public method found in controller class

    Time to fix: about 1 hour
    Read doc Open Issue Permalink
    Last edited by Damien Lagae
  6. {
  7. $id = IdField::new('id', 'enabel_partner_countries.admin.form.id');
  8. $country = CountryField::new('alpha2code', 'enabel_partner_countries.admin.form.country');
  9. $code2 = TextField::new('alpha2code', 'enabel_partner_countries.admin.form.alpha2code');
  10. $code3 = TextField::new('alpha3code', 'enabel_partner_countries.admin.form.alpha3code');
  • damienlagae

    ok for me
    => because EasyAdmin