mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
DX: fix type hinting, code and some dev stuffs
This commit is contained in:
parent
5dbfb98906
commit
c7de95c635
@ -22,6 +22,7 @@ use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
|
|||||||
use Symfony\Component\Form\Extension\Core\Type\FormType;
|
use Symfony\Component\Form\Extension\Core\Type\FormType;
|
||||||
use Symfony\Component\Form\Extension\Core\Type\SubmitType;
|
use Symfony\Component\Form\Extension\Core\Type\SubmitType;
|
||||||
use Symfony\Component\Form\FormFactoryInterface;
|
use Symfony\Component\Form\FormFactoryInterface;
|
||||||
|
use Symfony\Component\Form\FormInterface;
|
||||||
use Symfony\Component\HttpFoundation\Request;
|
use Symfony\Component\HttpFoundation\Request;
|
||||||
use Symfony\Component\HttpFoundation\Response;
|
use Symfony\Component\HttpFoundation\Response;
|
||||||
use Symfony\Component\HttpFoundation\Session\SessionInterface;
|
use Symfony\Component\HttpFoundation\Session\SessionInterface;
|
||||||
@ -191,18 +192,12 @@ class ExportController extends AbstractController
|
|||||||
case 'export':
|
case 'export':
|
||||||
return $this->exportFormStep($request, $export, $alias);
|
return $this->exportFormStep($request, $export, $alias);
|
||||||
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'formatter':
|
case 'formatter':
|
||||||
return $this->formatterFormStep($request, $export, $alias);
|
return $this->formatterFormStep($request, $export, $alias);
|
||||||
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'generate':
|
case 'generate':
|
||||||
return $this->forwardToGenerate($request, $export, $alias);
|
return $this->forwardToGenerate($request, $export, $alias);
|
||||||
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
default:
|
||||||
throw $this->createNotFoundException("The given step '{$step}' is invalid");
|
throw $this->createNotFoundException("The given step '{$step}' is invalid");
|
||||||
}
|
}
|
||||||
@ -214,10 +209,8 @@ class ExportController extends AbstractController
|
|||||||
* @param string $alias
|
* @param string $alias
|
||||||
* @param array $data the data from previous step. Required for steps 'formatter' and 'generate_formatter'
|
* @param array $data the data from previous step. Required for steps 'formatter' and 'generate_formatter'
|
||||||
* @param mixed $step
|
* @param mixed $step
|
||||||
*
|
|
||||||
* @return \Symfony\Component\Form\Form
|
|
||||||
*/
|
*/
|
||||||
protected function createCreateFormExport($alias, $step, $data = [])
|
protected function createCreateFormExport($alias, $step, $data = []): FormInterface
|
||||||
{
|
{
|
||||||
/** @var \Chill\MainBundle\Export\ExportManager $exportManager */
|
/** @var \Chill\MainBundle\Export\ExportManager $exportManager */
|
||||||
$exportManager = $this->exportManager;
|
$exportManager = $this->exportManager;
|
||||||
@ -475,8 +468,6 @@ class ExportController extends AbstractController
|
|||||||
* @param \Chill\MainBundle\Export\DirectExportInterface|\Chill\MainBundle\Export\ExportInterface $export
|
* @param \Chill\MainBundle\Export\DirectExportInterface|\Chill\MainBundle\Export\ExportInterface $export
|
||||||
* @param string $alias
|
* @param string $alias
|
||||||
*
|
*
|
||||||
* @throws type
|
|
||||||
*
|
|
||||||
* @return Response
|
* @return Response
|
||||||
*/
|
*/
|
||||||
protected function selectCentersStep(Request $request, $export, $alias)
|
protected function selectCentersStep(Request $request, $export, $alias)
|
||||||
@ -543,6 +534,8 @@ class ExportController extends AbstractController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user