@@ -16,24 +16,24 @@ |
||
16 | 16 | protected function configureContainer(ContainerConfigurator $container): void |
17 | 17 | { |
18 | 18 | $container->import('../../../config/{packages}/*.yaml'); |
19 | - $container->import('../../../config/{packages}/' . $this->environment . '/*.yaml'); |
|
19 | + $container->import('../../../config/{packages}/'.$this->environment.'/*.yaml'); |
|
20 | 20 | |
21 | - if (\is_file(\dirname(__DIR__, 3) . '/config/services.yaml')) { |
|
21 | + if (\is_file(\dirname(__DIR__, 3).'/config/services.yaml')) { |
|
22 | 22 | $container->import('../../../config/services.yaml'); |
23 | - $container->import('../../../config/{services}_' . $this->environment . '.yaml'); |
|
24 | - } elseif (\is_file($path = \dirname(__DIR__, 3) . '/config/services.php')) { |
|
23 | + $container->import('../../../config/{services}_'.$this->environment.'.yaml'); |
|
24 | + } elseif (\is_file($path = \dirname(__DIR__, 3).'/config/services.php')) { |
|
25 | 25 | (require $path)($container->withPath($path), $this); |
26 | 26 | } |
27 | 27 | } |
28 | 28 | |
29 | 29 | protected function configureRoutes(RoutingConfigurator $routes): void |
30 | 30 | { |
31 | - $routes->import('../../../config/{routes}/' . $this->environment . '/*.yaml'); |
|
31 | + $routes->import('../../../config/{routes}/'.$this->environment.'/*.yaml'); |
|
32 | 32 | $routes->import('../../../config/{routes}/*.yaml'); |
33 | 33 | |
34 | - if (\is_file(\dirname(__DIR__, 3) . '/config/routes.yaml')) { |
|
34 | + if (\is_file(\dirname(__DIR__, 3).'/config/routes.yaml')) { |
|
35 | 35 | $routes->import('../../../config/routes.yaml'); |
36 | - } elseif (\is_file($path = \dirname(__DIR__, 3) . '/config/routes.php')) { |
|
36 | + } elseif (\is_file($path = \dirname(__DIR__, 3).'/config/routes.php')) { |
|
37 | 37 | (require $path)($routes->withPath($path), $this); |
38 | 38 | } |
39 | 39 | } |
@@ -34,9 +34,9 @@ discard block |
||
34 | 34 | if (null !== $parent) { |
35 | 35 | $this->parent = $parent; |
36 | 36 | $this->parent->addChild($this); |
37 | - $this->path = $parent->slug() . ':' . $name->slugify(); |
|
37 | + $this->path = $parent->slug().':'.$name->slugify(); |
|
38 | 38 | if (null !== $this->parent->parent) { |
39 | - $this->path = $this->parent->parent->slug() . ':' . $this->parent->slug() . ':' . $name->slugify(); |
|
39 | + $this->path = $this->parent->parent->slug().':'.$this->parent->slug().':'.$name->slugify(); |
|
40 | 40 | } |
41 | 41 | } |
42 | 42 | } |
@@ -82,7 +82,7 @@ discard block |
||
82 | 82 | private function hasChildren(self $familyLog): ?array |
83 | 83 | { |
84 | 84 | if (null !== $familyLog->children) { |
85 | - return \array_map(static function (self $child) { |
|
85 | + return \array_map(static function(self $child) { |
|
86 | 86 | return $child->name; |
87 | 87 | }, $familyLog->children); |
88 | 88 | } |
@@ -43,7 +43,7 @@ |
||
43 | 43 | public static function fromPercent(string $name): self |
44 | 44 | { |
45 | 45 | \preg_match('/^(\d*)(,(\d*?)) %$/u', \trim($name), $str); |
46 | - $float = $str[1] . '.' . $str[3]; |
|
46 | + $float = $str[1].'.'.$str[3]; |
|
47 | 47 | |
48 | 48 | return new self((float) $float); |
49 | 49 | } |
@@ -51,7 +51,7 @@ |
||
51 | 51 | |
52 | 52 | public function getValue(): string |
53 | 53 | { |
54 | - return $this->address . "\n" . $this->zipCode . ' ' . $this->town . ', ' . $this->country; |
|
54 | + return $this->address."\n".$this->zipCode.' '.$this->town.', '.$this->country; |
|
55 | 55 | } |
56 | 56 | |
57 | 57 | public function address(): string |
@@ -31,14 +31,14 @@ |
||
31 | 31 | ->add('currency', ChoiceType::class, [ |
32 | 32 | 'constraints' => new NotNull(), |
33 | 33 | 'choices' => Currency::CURRENCY, |
34 | - 'choice_label' => function ($choice, $key, $value) { |
|
34 | + 'choice_label' => function($choice, $key, $value) { |
|
35 | 35 | return \ucfirst($value); |
36 | 36 | }, |
37 | 37 | ]) |
38 | 38 | ->add('locale', ChoiceType::class, [ |
39 | 39 | 'constraints' => new NotNull(), |
40 | 40 | 'choices' => Locale::LOCALE, |
41 | - 'choice_label' => function ($choice, $key, $value) { |
|
41 | + 'choice_label' => function($choice, $key, $value) { |
|
42 | 42 | return \strtoupper($value); |
43 | 43 | }, |
44 | 44 | ]) |
@@ -25,8 +25,8 @@ |
||
25 | 25 | public function __invoke(): BinaryFileResponse |
26 | 26 | { |
27 | 27 | $projectDir = $this->getParameter('kernel.project_dir'); |
28 | - $dataInventoryFolder = $projectDir . '/data/Inventory'; |
|
29 | - $prepareFile = new \SplFileInfo($dataInventoryFolder . '/prepare.pdf'); |
|
28 | + $dataInventoryFolder = $projectDir.'/data/Inventory'; |
|
29 | + $prepareFile = new \SplFileInfo($dataInventoryFolder.'/prepare.pdf'); |
|
30 | 30 | |
31 | 31 | return new BinaryFileResponse($prepareFile); |
32 | 32 | } |
@@ -94,7 +94,7 @@ |
||
94 | 94 | $result = $this->connection->executeQuery($query)->fetchAllAssociative(); |
95 | 95 | |
96 | 96 | return new Companies( |
97 | - ...\array_map(static function (array $company) { |
|
97 | + ...\array_map(static function(array $company) { |
|
98 | 98 | return new CompanyModel( |
99 | 99 | $company['uuid'], |
100 | 100 | $company['name'], |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | company.slug as slug |
51 | 51 | FROM company |
52 | 52 | WHERE uuid = :uuid |
53 | -SQL; |
|
53 | +sql; |
|
54 | 54 | $result = $this->connection->executeQuery($query, ['uuid' => $uuid])->fetchOne(); |
55 | 55 | |
56 | 56 | return new CompanyModel( |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | company.slug as slug |
91 | 91 | FROM company |
92 | 92 | ORDER BY name |
93 | -SQL; |
|
93 | +sql; |
|
94 | 94 | $result = $this->connection->executeQuery($query)->fetchAllAssociative(); |
95 | 95 | |
96 | 96 | return new Companies( |
@@ -104,7 +104,7 @@ |
||
104 | 104 | $result = $this->connection->executeQuery($query)->fetchAllAssociative(); |
105 | 105 | |
106 | 106 | return new Users( |
107 | - ...\array_map(static function (array $user) { |
|
107 | + ...\array_map(static function(array $user) { |
|
108 | 108 | return new UserReadModel( |
109 | 109 | $user['uuid'], |
110 | 110 | $user['username'], |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | user.roles as roles |
44 | 44 | FROM user |
45 | 45 | WHERE username = :username |
46 | -SQL; |
|
46 | +sql; |
|
47 | 47 | $result = $this->connection->executeQuery($query, ['username' => $username])->fetchAssociative(); |
48 | 48 | |
49 | 49 | if (false === $result) { |
@@ -72,7 +72,7 @@ discard block |
||
72 | 72 | user.roles as roles |
73 | 73 | FROM user |
74 | 74 | WHERE uuid = :uuid |
75 | -SQL; |
|
75 | +sql; |
|
76 | 76 | $result = $this->connection->executeQuery($query, ['uuid' => $uuid])->fetchAssociative(); |
77 | 77 | |
78 | 78 | if (false === $result) { |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | user.email as email, |
101 | 101 | user.roles as roles |
102 | 102 | FROM user |
103 | -SQL; |
|
103 | +sql; |
|
104 | 104 | $result = $this->connection->executeQuery($query)->fetchAllAssociative(); |
105 | 105 | |
106 | 106 | return new Users( |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | settings.currency as currency, |
40 | 40 | settings.locale as locale |
41 | 41 | FROM settings |
42 | -SQL; |
|
42 | +sql; |
|
43 | 43 | $result = $this->connection->executeQuery($query)->fetchAssociative(); |
44 | 44 | |
45 | 45 | if (false !== $result) { |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | settings.locale as locale |
62 | 62 | FROM settings |
63 | 63 | WHERE locale = :locale |
64 | -SQL; |
|
64 | +sql; |
|
65 | 65 | $result = $this->connection->executeQuery($query, ['locale' => $locale])->fetchAssociative(); |
66 | 66 | |
67 | 67 | if (false !== $result) { |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | settings.locale as locale |
84 | 84 | FROM settings |
85 | 85 | WHERE currency = :currency |
86 | -SQL; |
|
86 | +sql; |
|
87 | 87 | $result = $this->connection->executeQuery($query, ['currency' => $currency])->fetchAssociative(); |
88 | 88 | |
89 | 89 | if (false !== $result) { |