Completed
Pull Request — develop (#329)
by Carsten
07:08
created
module/Jobs/src/Jobs/Controller/AssignUserController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         $job = $this->repository->find($id);
63 63
 
64 64
         if (!$job) {
65
-            throw new \RuntimeException('No job found with id "' . $id . '"');
65
+            throw new \RuntimeException('No job found with id "'.$id.'"');
66 66
         }
67 67
 
68 68
         $this->acl($job, 'edit');
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Controller/ManageController.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
         if (empty($user->info->email)) {
171 171
             return $this->getErrorViewModel('no-parent', array('cause' => 'noEmail'));
172 172
         }
173
-        $userOrg            = $user->getOrganization();
173
+        $userOrg = $user->getOrganization();
174 174
         if (!$userOrg->hasAssociation()) {
175 175
             return $this->getErrorViewModel('no-parent', array('cause' => 'noCompany'));
176 176
         }
@@ -192,11 +192,11 @@  discard block
 block discarded – undo
192 192
         $instanceForm       = null;
193 193
         $formErrorMessages = array();
194 194
 
195
-        if (isset($formIdentifier) &&  $request->isPost()) {
195
+        if (isset($formIdentifier) && $request->isPost()) {
196 196
             // at this point the form get instantiated and immediately accumulated
197 197
             $instanceForm = $form->getForm($formIdentifier);
198 198
             if (!isset($instanceForm)) {
199
-                throw new \RuntimeException('No form found for "' . $formIdentifier . '"');
199
+                throw new \RuntimeException('No form found for "'.$formIdentifier.'"');
200 200
             }
201 201
             // the id may be part of the postData, but it never should be altered
202 202
             $postData = $request->getPost();
@@ -250,20 +250,20 @@  discard block
 block discarded – undo
250 250
             $jobValid = false;
251 251
             $errorMessage[] = $this->translator->translate('Accept the Terms');
252 252
         }
253
-        $result = $formEvents->trigger('ValidateJob', $this, [ 'form' => $form ]);
253
+        $result = $formEvents->trigger('ValidateJob', $this, ['form' => $form]);
254 254
         foreach ($result as $messages) {
255 255
             if (!$messages) {
256 256
                 continue;
257 257
             }
258 258
             if (!is_array($messages)) {
259
-                $messages = [ $messages ];
259
+                $messages = [$messages];
260 260
             }
261 261
 
262 262
             $errorMessage = array_merge($errorMessage, $messages);
263 263
             $jobValid = false;
264 264
         }
265 265
 
266
-        $errorMessage = '<br />' . implode('<br />', $errorMessage);
266
+        $errorMessage = '<br />'.implode('<br />', $errorMessage);
267 267
         if ($isAjax) {
268 268
             if ($instanceForm instanceof SummaryForm) {
269 269
                 $instanceForm->setRenderMode(SummaryForm::RENDER_SUMMARY);
@@ -271,7 +271,7 @@  discard block
 block discarded – undo
271 271
             } else {
272 272
                 $viewHelper = 'form';
273 273
             }
274
-            $viewHelperManager  = $serviceLocator->get('ViewHelperManager');
274
+            $viewHelperManager = $serviceLocator->get('ViewHelperManager');
275 275
             $content = $viewHelperManager->get($viewHelper)->__invoke($instanceForm);
276 276
             $viewModel = new JsonModel(
277 277
                 array(
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
                     }
295 295
                 }
296 296
             } else {
297
-                $formEvents->trigger('DisableElements', $this, [ 'form' => $form, 'job'=>$jobEntity ]);
297
+                $formEvents->trigger('DisableElements', $this, ['form' => $form, 'job'=>$jobEntity]);
298 298
                 // Job is deployed, some changes are now disabled
299 299
                 $form->enableAll();
300 300
             }
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
 
303 303
             $completionLink = $this->url()->fromRoute(
304 304
                 'lang/jobs/completion',
305
-                [ 'id' => $jobEntity->getId()]
305
+                ['id' => $jobEntity->getId()]
306 306
             );
307 307
 
308 308
             $viewModel = $this->getViewModel($form);
@@ -437,7 +437,7 @@  discard block
 block discarded – undo
437 437
         // array with differences between the last snapshot and the actual entity
438 438
         // is remains Null if there is no snapshot
439 439
         // it will be an empty array if the snapshot and the actual entity do not differ
440
-        $diff           = null;
440
+        $diff = null;
441 441
         // preliminary difference, contain all differences
442 442
         $prelDiff = $this->entitySnapshot()->diff($jobEntity);
443 443
         if (isset($prelDiff)) {
@@ -475,21 +475,21 @@  discard block
 block discarded – undo
475 475
             'lang/jobs/view',
476 476
             array(),
477 477
             array('query' =>
478
-                      array( 'id' => $jobEntity->getId()))
478
+                      array('id' => $jobEntity->getId()))
479 479
         );
480 480
 
481 481
         $approvalLink = $this->url()->fromRoute(
482 482
             'lang/jobs/approval',
483 483
             array('state' => 'approved'),
484 484
             array('query' =>
485
-                      array( 'id' => $jobEntity->getId()))
485
+                      array('id' => $jobEntity->getId()))
486 486
         );
487 487
 
488 488
         $declineLink = $this->url()->fromRoute(
489 489
             'lang/jobs/approval',
490 490
             array('state' => 'declined'),
491 491
             array('query' =>
492
-                      array( 'id' => $jobEntity->getId()))
492
+                      array('id' => $jobEntity->getId()))
493 493
         );
494 494
 
495 495
         return array('job' => $jobEntity,
@@ -506,7 +506,7 @@  discard block
 block discarded – undo
506 506
      */
507 507
     public function deactivateAction()
508 508
     {
509
-        $user           = $this->auth->getUser();
509
+        $user = $this->auth->getUser();
510 510
 
511 511
         $jobEntity = $this->initializeJob()->get($this->params());
512 512
 
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/Form/MultipostingSelectFactory.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         $helpers = $services->get('ViewHelperManager');
37 37
        // $headScript = $helpers->get('headScript');
38 38
        /// $basePath  = $helpers->get('basePath');
39
-        $currencyFormat  = $helpers->get('currencyFormat');
39
+        $currencyFormat = $helpers->get('currencyFormat');
40 40
 
41 41
         $channels = $services->get('Jobs/Options/Provider');
42 42
 
@@ -55,11 +55,11 @@  discard block
 block discarded – undo
55 55
 
56 56
             $link = $router->assemble($channel->getParams(), array('name' => $channel->getRoute()));
57 57
             $groups[$category]['options'][$channel->getKey()] =
58
-                              $channel->getLabel() . '|'
59
-                            . $channel->getHeadLine() . '|'
60
-                            . $channel->getDescription() . '|'
61
-                            . $channel->getLinkText() . '|'
62
-                            . $link . '|' . $channel->getPublishDuration() . '|'
58
+                              $channel->getLabel().'|'
59
+                            . $channel->getHeadLine().'|'
60
+                            . $channel->getDescription().'|'
61
+                            . $channel->getLinkText().'|'
62
+                            . $link.'|'.$channel->getPublishDuration().'|'
63 63
                             . $channel->getLogo();
64 64
         }
65 65
 
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/Filter/ViewModelTemplateFilterFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -58,7 +58,7 @@
 block discarded – undo
58 58
             $filter->setViewHelperForm($viewHelperForm);
59 59
         }
60 60
         if (!isset($filter)) {
61
-            throw new \InvalidArgumentException(get_class($element) . ' cannot be used to initialize a template');
61
+            throw new \InvalidArgumentException(get_class($element).' cannot be used to initialize a template');
62 62
         }
63 63
         $viewManager = $this->service->get('viewHelperManager');
64 64
         $basePathHelper = $viewManager->get('basePath');
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/Service/JobsPublisherFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
         if (!array_key_exists('path', $config)) {
40 40
             throw new \RuntimeException('path is missing', 500);
41 41
         }
42
-        return $config['scheme'] . '://' . $config['host'] . '/' . $config['path'];
42
+        return $config['scheme'].'://'.$config['host'].'/'.$config['path'];
43 43
     }
44 44
 
45 45
     /**
Please login to merge, or discard this patch.
module/Jobs/Module.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
      */
39 39
     public function getConfig()
40 40
     {
41
-        return ModuleConfigLoader::load(__DIR__ . '/config');
41
+        return ModuleConfigLoader::load(__DIR__.'/config');
42 42
     }
43 43
 
44 44
     /**
@@ -51,8 +51,8 @@  discard block
 block discarded – undo
51 51
         return array(
52 52
             'Zend\Loader\StandardAutoloader' => array(
53 53
                 'namespaces' => array(
54
-                    __NAMESPACE__ => __DIR__ . '/src/' . __NAMESPACE__,
55
-                    __NAMESPACE__ . 'Test' => __DIR__ . '/test/' . __NAMESPACE__ . 'Test',
54
+                    __NAMESPACE__ => __DIR__.'/src/'.__NAMESPACE__,
55
+                    __NAMESPACE__.'Test' => __DIR__.'/test/'.__NAMESPACE__.'Test',
56 56
                 ),
57 57
             ),
58 58
         );
Please login to merge, or discard this patch.
module/Orders/config/view.config.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -6,12 +6,12 @@
 block discarded – undo
6 6
  * @license MIT
7 7
  * @copyright  2013 - 2016 Cross Solution <http://cross-solution.de>
8 8
  */
9
-$dir = realpath(__DIR__ . '/../view');
9
+$dir = realpath(__DIR__.'/../view');
10 10
 
11
-return [ 'view_manager' => [ 'template_map' => [
11
+return ['view_manager' => ['template_map' => [
12 12
 
13
-    'orders/list/index' => $dir . '/orders/list/index.phtml',
14
-    'orders/list/index.ajax' => $dir . '/orders/list/index.ajax.phtml',
15
-    'orders/list/view' => $dir . '/orders/list/view.phtml',
13
+    'orders/list/index' => $dir.'/orders/list/index.phtml',
14
+    'orders/list/index.ajax' => $dir.'/orders/list/index.ajax.phtml',
15
+    'orders/list/view' => $dir.'/orders/list/view.phtml',
16 16
 
17 17
 ]]];
18 18
\ No newline at end of file
Please login to merge, or discard this patch.
module/Orders/src/View/Helper/FormatInvoiceAddress.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -31,16 +31,16 @@
 block discarded – undo
31 31
         $translate = $this->getView()->plugin('translate');
32 32
         $title = $address->getGender();
33 33
         $name = $address->getName();
34
-        $fullname = ($title ? "$title " : '') . "<strong>$name</strong>";
34
+        $fullname = ($title ? "$title " : '')."<strong>$name</strong>";
35 35
         $company = $address->getCompany();
36 36
         $street = $address->getStreet();
37
-        $city = $address->getZipCode() . ' ' . $address->getCity();
37
+        $city = $address->getZipCode().' '.$address->getCity();
38 38
         $region = $address->getRegion();
39 39
         $country = $address->getCountry();
40
-        $location = ($region ? "$region / " : '') . $country;
41
-        $vatId = '<em>' . $translate('VAT ID') . '</em>: ' . $address->getVatIdNumber();
40
+        $location = ($region ? "$region / " : '').$country;
41
+        $vatId = '<em>'.$translate('VAT ID').'</em>: '.$address->getVatIdNumber();
42 42
         $email = $address->getEmail();
43
-        $email = $email ? '<i class="fa fa-envelope"></i> ' . $this->getView()->plugin('link')->__invoke($email) : '';
43
+        $email = $email ? '<i class="fa fa-envelope"></i> '.$this->getView()->plugin('link')->__invoke($email) : '';
44 44
 
45 45
 
46 46
         $markup = "<address>$fullname<br>$company<br><br>$street<br>$city<br>$location<br><br>$email<br><br>$vatId</address>";
Please login to merge, or discard this patch.
module/Orders/src/autoload_classmap.php 1 patch
Spacing   +29 added lines, -29 removed lines patch added patch discarded remove patch
@@ -1,33 +1,33 @@
 block discarded – undo
1 1
 <?php
2 2
 // Generated by ZF2's ./bin/classmap_generator.php
3 3
 return array(
4
-    'Orders\Repository\Filter\PaginationQuery'                               => __DIR__ . '/Repository/Filter/PaginationQuery.php',
5
-    'Orders\Repository\Orders'                                               => __DIR__ . '/Repository/Orders.php',
6
-    'Orders\Options\ModuleOptions'                                           => __DIR__ . '/Options/ModuleOptions.php',
7
-    'Orders\View\Helper\FormatInvoiceAddress'                                => __DIR__ . '/View/Helper/FormatInvoiceAddress.php',
8
-    'Orders\Form\InvoiceAddress'                                             => __DIR__ . '/Form/InvoiceAddress.php',
9
-    'Orders\Form\Listener\ValidateJobInvoiceAddress'                         => __DIR__ . '/Form/Listener/ValidateJobInvoiceAddress.php',
10
-    'Orders\Form\Listener\InjectInvoiceAddressInJobContainer'                => __DIR__ . '/Form/Listener/InjectInvoiceAddressInJobContainer.php',
11
-    'Orders\Form\InvoiceAddressSettingsFieldset'                             => __DIR__ . '/Form/InvoiceAddressSettingsFieldset.php',
12
-    'Orders\Form\InvoiceAddressFieldset'                                     => __DIR__ . '/Form/InvoiceAddressFieldset.php',
13
-    'Orders\Entity\Order'                                                    => __DIR__ . '/Entity/Order.php',
14
-    'Orders\Entity\ProductInterface'                                         => __DIR__ . '/Entity/ProductInterface.php',
15
-    'Orders\Entity\SettingsContainer'                                        => __DIR__ . '/Entity/SettingsContainer.php',
16
-    'Orders\Entity\InvoiceAddressSettings'                                   => __DIR__ . '/Entity/InvoiceAddressSettings.php',
17
-    'Orders\Entity\InvoiceAddress'                                           => __DIR__ . '/Entity/InvoiceAddress.php',
18
-    'Orders\Entity\OrderInterface'                                           => __DIR__ . '/Entity/OrderInterface.php',
19
-    'Orders\Entity\Snapshot\SnapshotTrait'                                   => __DIR__ . '/Entity/Snapshot/SnapshotTrait.php',
20
-    'Orders\Entity\Snapshot\BuilderInterface'                                => __DIR__ . '/Entity/Snapshot/BuilderInterface.php',
21
-    'Orders\Entity\Snapshot\SnapshotInterface'                               => __DIR__ . '/Entity/Snapshot/SnapshotInterface.php',
22
-    'Orders\Entity\Snapshot\Job\JobSnapshot'                                 => __DIR__ . '/Entity/Snapshot/Job/JobSnapshot.php',
23
-    'Orders\Entity\Snapshot\Job\Builder'                                     => __DIR__ . '/Entity/Snapshot/Job/Builder.php',
24
-    'Orders\Entity\InvoiceAddressInterface'                                  => __DIR__ . '/Entity/InvoiceAddressInterface.php',
25
-    'Orders\Entity\Product'                                                  => __DIR__ . '/Entity/Product.php',
26
-    'Orders\Entity\OrderNumberCounter'                                       => __DIR__ . '/Entity/OrderNumberCounter.php',
27
-    'Orders\Controller\ListController'                                       => __DIR__ . '/Controller/ListController.php',
28
-    'Orders\Listener\CreateJobOrder'                                         => __DIR__ . '/Listener/CreateJobOrder.php',
29
-    'Orders\Factory\Form\JobInvoiceAddressFactory'                           => __DIR__ . '/Factory/Form/JobInvoiceAddressFactory.php',
30
-    'Orders\Factory\Form\Listener\InjectInvoiceAddressInJobContainerFactory' => __DIR__ . '/Factory/Form/Listener/InjectInvoiceAddressInJobContainerFactory.php',
31
-    'Orders\Factory\Entity\JobInvoiceAddressFactory'                         => __DIR__ . '/Factory/Entity/JobInvoiceAddressFactory.php',
32
-    'Orders\Factory\Listener\CreateJobOrderFactory'                          => __DIR__ . '/Factory/Listener/CreateJobOrderFactory.php',
4
+    'Orders\Repository\Filter\PaginationQuery'                               => __DIR__.'/Repository/Filter/PaginationQuery.php',
5
+    'Orders\Repository\Orders'                                               => __DIR__.'/Repository/Orders.php',
6
+    'Orders\Options\ModuleOptions'                                           => __DIR__.'/Options/ModuleOptions.php',
7
+    'Orders\View\Helper\FormatInvoiceAddress'                                => __DIR__.'/View/Helper/FormatInvoiceAddress.php',
8
+    'Orders\Form\InvoiceAddress'                                             => __DIR__.'/Form/InvoiceAddress.php',
9
+    'Orders\Form\Listener\ValidateJobInvoiceAddress'                         => __DIR__.'/Form/Listener/ValidateJobInvoiceAddress.php',
10
+    'Orders\Form\Listener\InjectInvoiceAddressInJobContainer'                => __DIR__.'/Form/Listener/InjectInvoiceAddressInJobContainer.php',
11
+    'Orders\Form\InvoiceAddressSettingsFieldset'                             => __DIR__.'/Form/InvoiceAddressSettingsFieldset.php',
12
+    'Orders\Form\InvoiceAddressFieldset'                                     => __DIR__.'/Form/InvoiceAddressFieldset.php',
13
+    'Orders\Entity\Order'                                                    => __DIR__.'/Entity/Order.php',
14
+    'Orders\Entity\ProductInterface'                                         => __DIR__.'/Entity/ProductInterface.php',
15
+    'Orders\Entity\SettingsContainer'                                        => __DIR__.'/Entity/SettingsContainer.php',
16
+    'Orders\Entity\InvoiceAddressSettings'                                   => __DIR__.'/Entity/InvoiceAddressSettings.php',
17
+    'Orders\Entity\InvoiceAddress'                                           => __DIR__.'/Entity/InvoiceAddress.php',
18
+    'Orders\Entity\OrderInterface'                                           => __DIR__.'/Entity/OrderInterface.php',
19
+    'Orders\Entity\Snapshot\SnapshotTrait'                                   => __DIR__.'/Entity/Snapshot/SnapshotTrait.php',
20
+    'Orders\Entity\Snapshot\BuilderInterface'                                => __DIR__.'/Entity/Snapshot/BuilderInterface.php',
21
+    'Orders\Entity\Snapshot\SnapshotInterface'                               => __DIR__.'/Entity/Snapshot/SnapshotInterface.php',
22
+    'Orders\Entity\Snapshot\Job\JobSnapshot'                                 => __DIR__.'/Entity/Snapshot/Job/JobSnapshot.php',
23
+    'Orders\Entity\Snapshot\Job\Builder'                                     => __DIR__.'/Entity/Snapshot/Job/Builder.php',
24
+    'Orders\Entity\InvoiceAddressInterface'                                  => __DIR__.'/Entity/InvoiceAddressInterface.php',
25
+    'Orders\Entity\Product'                                                  => __DIR__.'/Entity/Product.php',
26
+    'Orders\Entity\OrderNumberCounter'                                       => __DIR__.'/Entity/OrderNumberCounter.php',
27
+    'Orders\Controller\ListController'                                       => __DIR__.'/Controller/ListController.php',
28
+    'Orders\Listener\CreateJobOrder'                                         => __DIR__.'/Listener/CreateJobOrder.php',
29
+    'Orders\Factory\Form\JobInvoiceAddressFactory'                           => __DIR__.'/Factory/Form/JobInvoiceAddressFactory.php',
30
+    'Orders\Factory\Form\Listener\InjectInvoiceAddressInJobContainerFactory' => __DIR__.'/Factory/Form/Listener/InjectInvoiceAddressInJobContainerFactory.php',
31
+    'Orders\Factory\Entity\JobInvoiceAddressFactory'                         => __DIR__.'/Factory/Entity/JobInvoiceAddressFactory.php',
32
+    'Orders\Factory\Listener\CreateJobOrderFactory'                          => __DIR__.'/Factory/Listener/CreateJobOrderFactory.php',
33 33
 );
Please login to merge, or discard this patch.