@@ -144,7 +144,7 @@ public function index(AdminContext $context)
144144 }
145145
146146 $ entities = $ this ->container ->get (EntityFactory::class)->createCollection ($ context ->getEntity (), $ paginator ->getResults ());
147- $ this ->container ->get (EntityFactory::class)->processFieldsForAll ($ entities , $ fields );
147+ $ this ->container ->get (EntityFactory::class)->processFieldsForAll ($ entities , $ fields, Crud:: PAGE_INDEX );
148148 $ procesedFields = $ entities ->first ()?->getFields() ?? FieldCollection::new ([]);
149149 $ context ->getCrud ()->setFieldAssets ($ this ->getFieldAssets ($ procesedFields ));
150150 $ actions = $ this ->container ->get (EntityFactory::class)->processActionsForAll ($ entities , $ context ->getCrud ()->getActionsConfig ());
@@ -184,7 +184,7 @@ public function detail(AdminContext $context)
184184 throw new InsufficientEntityPermissionException ($ context );
185185 }
186186
187- $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), FieldCollection::new ($ this ->configureFields (Crud::PAGE_DETAIL )));
187+ $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), FieldCollection::new ($ this ->configureFields (Crud::PAGE_DETAIL )), Crud:: PAGE_DETAIL );
188188 $ context ->getCrud ()->setFieldAssets ($ this ->getFieldAssets ($ context ->getEntity ()->getFields ()));
189189 $ this ->container ->get (EntityFactory::class)->processActions ($ context ->getEntity (), $ context ->getCrud ()->getActionsConfig ());
190190
@@ -219,7 +219,7 @@ public function edit(AdminContext $context)
219219 throw new InsufficientEntityPermissionException ($ context );
220220 }
221221
222- $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), FieldCollection::new ($ this ->configureFields (Crud::PAGE_EDIT )));
222+ $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), FieldCollection::new ($ this ->configureFields (Crud::PAGE_EDIT )), Crud:: PAGE_EDIT );
223223 $ context ->getCrud ()->setFieldAssets ($ this ->getFieldAssets ($ context ->getEntity ()->getFields ()));
224224 $ this ->container ->get (EntityFactory::class)->processActions ($ context ->getEntity (), $ context ->getCrud ()->getActionsConfig ());
225225 /** @var TEntity $entityInstance */
@@ -305,7 +305,7 @@ public function new(AdminContext $context)
305305 /** @var class-string<TEntity> $entityFqcn */
306306 $ entityFqcn = $ context ->getEntity ()->getFqcn ();
307307 $ context ->getEntity ()->setInstance ($ this ->createEntity ($ entityFqcn ));
308- $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), FieldCollection::new ($ this ->configureFields (Crud::PAGE_NEW )));
308+ $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), FieldCollection::new ($ this ->configureFields (Crud::PAGE_NEW )), Crud:: PAGE_NEW );
309309 $ context ->getCrud ()->setFieldAssets ($ this ->getFieldAssets ($ context ->getEntity ()->getFields ()));
310310 $ this ->container ->get (EntityFactory::class)->processActions ($ context ->getEntity (), $ context ->getCrud ()->getActionsConfig ());
311311
@@ -495,7 +495,7 @@ public function createIndexQueryBuilder(SearchDto $searchDto, EntityDto $entityD
495495 public function renderFilters (AdminContext $ context ): KeyValueStore
496496 {
497497 $ fields = FieldCollection::new ($ this ->configureFields (Crud::PAGE_INDEX ));
498- $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), $ fields );
498+ $ this ->container ->get (EntityFactory::class)->processFields ($ context ->getEntity (), $ fields, Crud:: PAGE_INDEX );
499499 $ filters = $ this ->container ->get (FilterFactory::class)->create ($ context ->getCrud ()->getFiltersConfig (), $ context ->getEntity ()->getFields (), $ context ->getEntity ());
500500
501501 /** @var FormInterface&FiltersFormType $filtersForm */
0 commit comments