mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 07:03:49 +00:00
cs: Fix code-style (using PHPCSFixer and PHPCS).
This commit is contained in:
@@ -26,6 +26,7 @@ use Symfony\Component\HttpKernel\Exception\UnauthorizedHttpException;
|
||||
use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface;
|
||||
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
|
||||
use UnexpectedValueException;
|
||||
|
||||
use function array_key_exists;
|
||||
use function count;
|
||||
use function get_class;
|
||||
@@ -122,8 +123,10 @@ class ExportManager
|
||||
public function &getFiltersApplyingOn(ExportInterface $export, ?array $centers = null)
|
||||
{
|
||||
foreach ($this->filters as $alias => $filter) {
|
||||
if (in_array($filter->applyOn(), $export->supportsModifiers(), true)
|
||||
&& $this->isGrantedForElement($filter, $export, $centers)) {
|
||||
if (
|
||||
in_array($filter->applyOn(), $export->supportsModifiers(), true)
|
||||
&& $this->isGrantedForElement($filter, $export, $centers)
|
||||
) {
|
||||
yield $alias => $filter;
|
||||
}
|
||||
}
|
||||
@@ -143,8 +146,10 @@ class ExportManager
|
||||
}
|
||||
|
||||
foreach ($this->aggregators as $alias => $aggregator) {
|
||||
if (in_array($aggregator->applyOn(), $export->supportsModifiers(), true)
|
||||
&& $this->isGrantedForElement($aggregator, $export, $centers)) {
|
||||
if (
|
||||
in_array($aggregator->applyOn(), $export->supportsModifiers(), true)
|
||||
&& $this->isGrantedForElement($aggregator, $export, $centers)
|
||||
) {
|
||||
yield $alias => $aggregator;
|
||||
}
|
||||
}
|
||||
|
@@ -20,6 +20,7 @@ use Symfony\Component\Form\Extension\Core\Type\FormType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Contracts\Translation\TranslatorInterface;
|
||||
|
||||
use function array_key_exists;
|
||||
use function array_slice;
|
||||
use function call_user_func;
|
||||
|
@@ -19,6 +19,7 @@ use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Translation\TranslatorInterface;
|
||||
|
||||
use function array_key_exists;
|
||||
use function array_keys;
|
||||
use function array_map;
|
||||
@@ -198,7 +199,9 @@ class CSVListFormatter implements FormatterInterface
|
||||
|
||||
foreach ($keys as $key) {
|
||||
// get an array with all values for this key if possible
|
||||
$values = array_map(static function ($v) use ($key) { return $v[$key]; }, $this->result);
|
||||
$values = array_map(static function ($v) use ($key) {
|
||||
return $v[$key];
|
||||
}, $this->result);
|
||||
// store the label in the labelsCache property
|
||||
$this->labelsCache[$key] = $export->getLabels($key, $values, $this->exportData);
|
||||
}
|
||||
|
@@ -18,6 +18,7 @@ use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Translation\TranslatorInterface;
|
||||
|
||||
use function array_map;
|
||||
use function count;
|
||||
|
||||
@@ -186,7 +187,9 @@ class CSVPivotedListFormatter implements FormatterInterface
|
||||
|
||||
foreach ($keys as $key) {
|
||||
// get an array with all values for this key if possible
|
||||
$values = array_map(static function ($v) use ($key) { return $v[$key]; }, $this->result);
|
||||
$values = array_map(static function ($v) use ($key) {
|
||||
return $v[$key];
|
||||
}, $this->result);
|
||||
// store the label in the labelsCache property
|
||||
$this->labelsCache[$key] = $export->getLabels($key, $values, $this->exportData);
|
||||
}
|
||||
|
@@ -20,6 +20,7 @@ use Symfony\Component\Form\Extension\Core\Type\FormType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Translation\TranslatorInterface;
|
||||
|
||||
use function array_map;
|
||||
use function array_merge;
|
||||
use function array_multisort;
|
||||
|
@@ -24,6 +24,7 @@ use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Translation\TranslatorInterface;
|
||||
|
||||
use function array_key_exists;
|
||||
use function array_keys;
|
||||
use function array_map;
|
||||
@@ -257,7 +258,9 @@ class SpreadsheetListFormatter implements FormatterInterface
|
||||
|
||||
foreach ($keys as $key) {
|
||||
// get an array with all values for this key if possible
|
||||
$values = array_map(static function ($v) use ($key) { return $v[$key]; }, $this->result);
|
||||
$values = array_map(static function ($v) use ($key) {
|
||||
return $v[$key];
|
||||
}, $this->result);
|
||||
// store the label in the labelsCache property
|
||||
$this->labelsCache[$key] = $export->getLabels($key, $values, $this->exportData);
|
||||
}
|
||||
|
Reference in New Issue
Block a user