@@ -89,7 +89,7 @@ |
||
89 | 89 | * @Route("/{id}/clone", name="label_profile_clone") |
90 | 90 | * @Route("/") |
91 | 91 | */ |
92 | - public function new(Request $request, EntityManagerInterface $em, EntityImporter $importer, ?AttachmentType $entity = null): Response |
|
92 | + public function new(Request $request, EntityManagerInterface $em, EntityImporter $importer, ?AttachmentType $entity = null) : Response |
|
93 | 93 | { |
94 | 94 | return $this->_new($request, $em, $importer, $entity); |
95 | 95 | } |
@@ -89,7 +89,7 @@ |
||
89 | 89 | * @Route("/{id}/clone", name="category_clone") |
90 | 90 | * @Route("/") |
91 | 91 | */ |
92 | - public function new(Request $request, EntityManagerInterface $em, EntityImporter $importer, ?Category $entity = null): Response |
|
92 | + public function new(Request $request, EntityManagerInterface $em, EntityImporter $importer, ?Category $entity = null) : Response |
|
93 | 93 | { |
94 | 94 | return $this->_new($request, $em, $importer, $entity); |
95 | 95 | } |
@@ -99,7 +99,7 @@ |
||
99 | 99 | ]); |
100 | 100 | |
101 | 101 | //Add pricedetails after we know the data, so we can set the default currency |
102 | - $builder->addEventListener(FormEvents::PRE_SET_DATA, function (FormEvent $event) use ($options): void { |
|
102 | + $builder->addEventListener(FormEvents::PRE_SET_DATA, function(FormEvent $event) use ($options): void { |
|
103 | 103 | /** @var Orderdetail $orderdetail */ |
104 | 104 | $orderdetail = $event->getData(); |
105 | 105 |
@@ -64,7 +64,7 @@ |
||
64 | 64 | |
65 | 65 | public function buildForm(FormBuilderInterface $builder, array $options): void |
66 | 66 | { |
67 | - $builder->addEventListener(FormEvents::PRE_SET_DATA, function (FormEvent $event): void { |
|
67 | + $builder->addEventListener(FormEvents::PRE_SET_DATA, function(FormEvent $event): void { |
|
68 | 68 | $form = $event->getForm(); |
69 | 69 | /** @var User $user */ |
70 | 70 | $user = $event->getData(); |
@@ -169,7 +169,7 @@ discard block |
||
169 | 169 | ], |
170 | 170 | ]); |
171 | 171 | |
172 | - $builder->addEventListener(FormEvents::POST_SUBMIT, function (FormEvent $event): void { |
|
172 | + $builder->addEventListener(FormEvents::POST_SUBMIT, function(FormEvent $event): void { |
|
173 | 173 | $form = $event->getForm(); |
174 | 174 | $attachment = $form->getData(); |
175 | 175 | |
@@ -188,7 +188,7 @@ discard block |
||
188 | 188 | //Check the secure file checkbox, if file is in securefile location |
189 | 189 | $builder->get('secureFile')->addEventListener( |
190 | 190 | FormEvents::PRE_SET_DATA, |
191 | - function (FormEvent $event): void { |
|
191 | + function(FormEvent $event): void { |
|
192 | 192 | $attachment = $event->getForm()->getParent()->getData(); |
193 | 193 | if ($attachment instanceof Attachment) { |
194 | 194 | $event->setData($attachment->isSecure()); |
@@ -65,8 +65,8 @@ discard block |
||
65 | 65 | 'class' => 'selectpicker', |
66 | 66 | 'title' => 'selectpicker.nothing_selected', |
67 | 67 | ], |
68 | - 'choice_attr' => function (Options $options) { |
|
69 | - return function ($choice, $key, $value) use ($options) { |
|
68 | + 'choice_attr' => function(Options $options) { |
|
69 | + return function($choice, $key, $value) use ($options) { |
|
70 | 70 | /** @var Attachment $choice */ |
71 | 71 | $tmp = ['data-subtext' => $choice->getFilename() ?? 'URL']; |
72 | 72 | |
@@ -80,8 +80,8 @@ discard block |
||
80 | 80 | }; |
81 | 81 | }, |
82 | 82 | 'choice_label' => 'name', |
83 | - 'choice_loader' => function (Options $options) { |
|
84 | - return new CallbackChoiceLoader(function () use ($options) { |
|
83 | + 'choice_loader' => function(Options $options) { |
|
84 | + return new CallbackChoiceLoader(function() use ($options) { |
|
85 | 85 | $entity = $options['entity']; |
86 | 86 | if (!$entity instanceof AttachmentContainingDBElement) { |
87 | 87 | throw new \RuntimeException('$entity must have Attachments! (be of type AttachmentContainingDBElement)'); |
@@ -124,7 +124,7 @@ |
||
124 | 124 | ], |
125 | 125 | 'choice_translation_domain' => false, |
126 | 126 | 'choices' => User::AVAILABLE_THEMES, |
127 | - 'choice_label' => function ($entity, $key, $value) { |
|
127 | + 'choice_label' => function($entity, $key, $value) { |
|
128 | 128 | return $value; |
129 | 129 | }, |
130 | 130 | 'placeholder' => 'user_settings.theme.placeholder', |
@@ -174,7 +174,7 @@ |
||
174 | 174 | ->add('theme', ChoiceType::class, [ |
175 | 175 | 'required' => false, |
176 | 176 | 'choices' => User::AVAILABLE_THEMES, |
177 | - 'choice_label' => function ($entity, $key, $value) { |
|
177 | + 'choice_label' => function($entity, $key, $value) { |
|
178 | 178 | return $value; |
179 | 179 | }, |
180 | 180 | 'attr' => [ |
@@ -83,7 +83,7 @@ |
||
83 | 83 | 'label_options.barcode_type.code93' => 'code93', |
84 | 84 | 'label_options.barcode_type.datamatrix' => 'datamatrix', |
85 | 85 | ], |
86 | - 'group_by' => function ($choice, $key, $value) { |
|
86 | + 'group_by' => function($choice, $key, $value) { |
|
87 | 87 | if (in_array($choice, ['qr', 'datamatrix'], true)) { |
88 | 88 | return 'label_options.barcode_type.2D'; |
89 | 89 | } |