mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-02 21:13:57 +00:00
update php-cs-fixer and rector + fix rules
This commit is contained in:
@@ -121,7 +121,7 @@ class CustomFieldController extends AbstractController
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$entity = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomField::class)->find($id);
|
||||
$entity = $em->getRepository(CustomField::class)->find($id);
|
||||
|
||||
if (!$entity) {
|
||||
throw $this->createNotFoundException('Unable to find CustomField entity.');
|
||||
|
@@ -37,7 +37,10 @@ class CustomFieldsGroupController extends AbstractController
|
||||
* CustomFieldsGroupController constructor.
|
||||
*/
|
||||
public function __construct(
|
||||
private readonly CustomFieldProvider $customFieldProvider, private readonly TranslatorInterface $translator, private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry) {}
|
||||
private readonly CustomFieldProvider $customFieldProvider,
|
||||
private readonly TranslatorInterface $translator,
|
||||
private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Creates a new CustomFieldsGroup entity.
|
||||
@@ -79,7 +82,7 @@ class CustomFieldsGroupController extends AbstractController
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$entity = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsGroup::class)->find($id);
|
||||
$entity = $em->getRepository(CustomFieldsGroup::class)->find($id);
|
||||
|
||||
if (!$entity) {
|
||||
throw $this->createNotFoundException('Unable to find CustomFieldsGroup entity.');
|
||||
@@ -102,7 +105,7 @@ class CustomFieldsGroupController extends AbstractController
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$cfGroups = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsGroup::class)->findAll();
|
||||
$cfGroups = $em->getRepository(CustomFieldsGroup::class)->findAll();
|
||||
$defaultGroups = $this->getDefaultGroupsId();
|
||||
|
||||
$makeDefaultFormViews = [];
|
||||
@@ -134,13 +137,13 @@ class CustomFieldsGroupController extends AbstractController
|
||||
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$cFGroup = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsGroup::class)->findOneById($cFGroupId);
|
||||
$cFGroup = $em->getRepository(CustomFieldsGroup::class)->findOneById($cFGroupId);
|
||||
|
||||
if (!$cFGroup) {
|
||||
throw $this->createNotFoundException('customFieldsGroup not found with '."id {$cFGroupId}");
|
||||
}
|
||||
|
||||
$cFDefaultGroup = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsDefaultGroup::class)
|
||||
$cFDefaultGroup = $em->getRepository(CustomFieldsDefaultGroup::class)
|
||||
->findOneByEntity($cFGroup->getEntity());
|
||||
|
||||
if ($cFDefaultGroup) {
|
||||
@@ -195,7 +198,7 @@ class CustomFieldsGroupController extends AbstractController
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$entity = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsGroup::class)->find($id);
|
||||
$entity = $em->getRepository(CustomFieldsGroup::class)->find($id);
|
||||
|
||||
if (!$entity) {
|
||||
throw $this->createNotFoundException('Unable to find CustomFieldsGroups entity.');
|
||||
@@ -239,7 +242,7 @@ class CustomFieldsGroupController extends AbstractController
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$entity = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsGroup::class)->find($id);
|
||||
$entity = $em->getRepository(CustomFieldsGroup::class)->find($id);
|
||||
|
||||
if (!$entity) {
|
||||
throw $this->createNotFoundException('Unable to find CustomFieldsGroup entity.');
|
||||
@@ -263,7 +266,7 @@ class CustomFieldsGroupController extends AbstractController
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
||||
$entity = $em->getRepository(\Chill\CustomFieldsBundle\Entity\CustomFieldsGroup::class)->find($id);
|
||||
$entity = $em->getRepository(CustomFieldsGroup::class)->find($id);
|
||||
|
||||
if (!$entity) {
|
||||
throw $this->createNotFoundException('Unable to find CustomFieldsGroup entity.');
|
||||
|
Reference in New Issue
Block a user