Completed
Pull Request — develop (#440)
by Carsten
09:45
created
module/Core/src/Core/Form/Container.php 4 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -98,7 +98,7 @@
 block discarded – undo
98 98
     /**
99 99
      * Gets an iterator to iterate over the enabled formulars.
100 100
      *
101
-     * @return \ArrayIterator
101
+     * @return PriorityList
102 102
      * @see IteratorAggregate::getIterator()
103 103
      */
104 104
     public function getIterator()
Please login to merge, or discard this patch.
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -328,11 +328,11 @@
 block discarded – undo
328 328
         }
329 329
 
330 330
         // @TODO: [ZF3] which one is correct? $form[options][label] or $form[options]
331
-	    if(isset($form['label'])){
332
-		    $formLabel = $form['label'];
333
-	    }elseif(isset($form['options']['label'])){
334
-		    $formLabel = $form['options']['label'];
335
-	    }
331
+        if(isset($form['label'])){
332
+            $formLabel = $form['label'];
333
+        }elseif(isset($form['options']['label'])){
334
+            $formLabel = $form['options']['label'];
335
+        }
336 336
 	    
337 337
         if (isset($formLabel)) {
338 338
             $formInstance->setLabel($formLabel);
Please login to merge, or discard this patch.
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -312,7 +312,7 @@  discard block
 block discarded – undo
312 312
 	    
313 313
         //@TODO: [ZF3] Passing options in $formElementManager->get is not working need to do manually set options
314 314
         $formInstance = $this->formElementManager->get($form['type'], $options);
315
-        $formInstance->setOptions(array_merge($formInstance->getOptions(),$options));
315
+        $formInstance->setOptions(array_merge($formInstance->getOptions(), $options));
316 316
         $formInstance->setParent($this);
317 317
         
318 318
         if (isset($form['attributes'])) {
@@ -324,13 +324,13 @@  discard block
 block discarded – undo
324 324
         $formAction = $formInstance->getAttribute('action');
325 325
 
326 326
         if (empty($formAction)) {
327
-            $formInstance->setAttribute('action', '?form=' . $formName);
327
+            $formInstance->setAttribute('action', '?form='.$formName);
328 328
         }
329 329
 
330 330
         // @TODO: [ZF3] which one is correct? $form[options][label] or $form[options]
331
-	    if(isset($form['label'])){
331
+	    if (isset($form['label'])) {
332 332
 		    $formLabel = $form['label'];
333
-	    }elseif(isset($form['options']['label'])){
333
+	    }elseif (isset($form['options']['label'])) {
334 334
 		    $formLabel = $form['options']['label'];
335 335
 	    }
336 336
 	    
@@ -396,7 +396,7 @@  discard block
 block discarded – undo
396 396
                 $spec->setParent($this);
397 397
             }
398 398
 
399
-            $spec = [ '__instance__' => $spec, 'name' => $key, 'entity' => '*' ];
399
+            $spec = ['__instance__' => $spec, 'name' => $key, 'entity' => '*'];
400 400
         }
401 401
 
402 402
         if (!is_array($spec)) {
@@ -515,7 +515,7 @@  discard block
 block discarded – undo
515 515
         }
516 516
         $this->activeForms = array_filter(
517 517
             $this->activeForms,
518
-            function ($item) use ($key) {
518
+            function($item) use ($key) {
519 519
                 return !in_array($item, $key);
520 520
             }
521 521
         );
@@ -529,7 +529,7 @@  discard block
 block discarded – undo
529 529
      * @throws \InvalidArgumentException
530 530
      * @return Container
531 531
      */
532
-    public function setEntity($entity, $key='*')
532
+    public function setEntity($entity, $key = '*')
533 533
     {
534 534
         if (!$entity instanceof EntityInterface)
535 535
         {
@@ -552,7 +552,7 @@  discard block
 block discarded – undo
552 552
      *
553 553
      * @return \Core\Entity\EntityInterface
554 554
      */
555
-    public function getEntity($key='*')
555
+    public function getEntity($key = '*')
556 556
     {
557 557
         return isset($this->entities[$key]) ? $this->entities[$key] : null;
558 558
     }
@@ -754,10 +754,10 @@  discard block
 block discarded – undo
754 754
         $actualKey = $this->getActiveFormActual();
755 755
         if (isset($actualKey)) {
756 756
             $forms = array_keys($this->forms);
757
-            $formsFlip =  array_flip($forms);
757
+            $formsFlip = array_flip($forms);
758 758
             $index = $formsFlip[$actualKey];
759 759
             if (0 < $index) {
760
-                $key = $forms[$index-1];
760
+                $key = $forms[$index - 1];
761 761
             }
762 762
         }
763 763
         return $key;
@@ -774,10 +774,10 @@  discard block
 block discarded – undo
774 774
         $actualKey = $this->getActiveFormActual();
775 775
         if (isset($actualKey)) {
776 776
             $forms = array_keys($this->forms);
777
-            $formsFlip =  array_flip($forms);
777
+            $formsFlip = array_flip($forms);
778 778
             $index = $formsFlip[$actualKey];
779 779
             if ($index < count($forms) - 1) {
780
-                $key = $forms[$index+1];
780
+                $key = $forms[$index + 1];
781 781
             }
782 782
         }
783 783
         return $key;
@@ -791,7 +791,7 @@  discard block
 block discarded – undo
791 791
      */
792 792
     public function formatAction($name)
793 793
     {
794
-        return sprintf('%s%s', $this->hasParent() ? $this->getName() . '.' : '', $name);
794
+        return sprintf('%s%s', $this->hasParent() ? $this->getName().'.' : '', $name);
795 795
     }
796 796
 
797 797
     /**
@@ -801,7 +801,7 @@  discard block
 block discarded – undo
801 801
     public function getActionFor($key)
802 802
     {
803 803
         if (isset($this->forms[$key])) {
804
-            return '?form=' . $this->formatAction($this->forms[$key]['name']);
804
+            return '?form='.$this->formatAction($this->forms[$key]['name']);
805 805
         }
806 806
     }
807 807
 }
808 808
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -330,7 +330,7 @@
 block discarded – undo
330 330
         // @TODO: [ZF3] which one is correct? $form[options][label] or $form[options]
331 331
 	    if(isset($form['label'])){
332 332
 		    $formLabel = $form['label'];
333
-	    }elseif(isset($form['options']['label'])){
333
+	    } elseif(isset($form['options']['label'])){
334 334
 		    $formLabel = $form['options']['label'];
335 335
 	    }
336 336
 	    
Please login to merge, or discard this patch.
module/Organizations/src/Organizations/Entity/WorkflowSettingsInterface.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
      * @param bool $acceptApplicationByDepartmentManager
18 18
      * @return WorkflowSettings
19 19
      */
20
-    public function setAcceptApplicationByDepartmentManager( $acceptApplicationByDepartmentManager );
20
+    public function setAcceptApplicationByDepartmentManager($acceptApplicationByDepartmentManager);
21 21
 
22 22
     /**
23 23
      * Gets AcceptApplicationByDepartmentManager
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
      * @param bool $assignDepartmentManagersToJobs
33 33
      * @return WorkflowSettings
34 34
      */
35
-    public function setAssignDepartmentManagersToJobs( $assignDepartmentManagersToJobs );
35
+    public function setAssignDepartmentManagersToJobs($assignDepartmentManagersToJobs);
36 36
 
37 37
     /**
38 38
      * Gets AssignDepartmentManagersToJobs
Please login to merge, or discard this patch.
module/Organizations/src/Organizations/Entity/WorkflowSettings.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -40,9 +40,9 @@  discard block
 block discarded – undo
40 40
      * @param bool $acceptApplicationByDepartmentManager
41 41
      * @return WorkflowSettings
42 42
      */
43
-    public function setAcceptApplicationByDepartmentManager( $acceptApplicationByDepartmentManager )
43
+    public function setAcceptApplicationByDepartmentManager($acceptApplicationByDepartmentManager)
44 44
     {
45
-        $this->acceptApplicationByDepartmentManager= $acceptApplicationByDepartmentManager;
45
+        $this->acceptApplicationByDepartmentManager = $acceptApplicationByDepartmentManager;
46 46
         return $this;
47 47
     }
48 48
     
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
      * @param bool $assignDepartmentManagersToJobs
63 63
      * @return WorkflowSettings
64 64
      */
65
-    public function setAssignDepartmentManagersToJobs( $assignDepartmentManagersToJobs )
65
+    public function setAssignDepartmentManagersToJobs($assignDepartmentManagersToJobs)
66 66
     {
67 67
         $this->assignDepartmentManagersToJobs = $assignDepartmentManagersToJobs;
68 68
         return $this;
Please login to merge, or discard this patch.
module/Applications/src/Applications/Entity/Settings.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -142,7 +142,7 @@
 block discarded – undo
142 142
     /**
143 143
      * @return bool
144 144
      */
145
-    public function getAutoConfirmMail(){
145
+    public function getAutoConfirmMail() {
146 146
         return $this->autoConfirmMail;
147 147
     }
148 148
 }
Please login to merge, or discard this patch.
module/Applications/src/Applications/Listener/Events/ApplicationEvent.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -30,17 +30,17 @@  discard block
 block discarded – undo
30 30
     /**
31 31
      * Event is fired when a new application is saved.
32 32
      */
33
-    const EVENT_APPLICATION_POST_CREATE   = 'application.post.create';
33
+    const EVENT_APPLICATION_POST_CREATE = 'application.post.create';
34 34
 
35 35
     /**
36 36
      * Event is fired when a users deleted application
37 37
      */
38
-    const EVENT_APPLICATION_PRE_DELETE   = 'application.pre.delete';
38
+    const EVENT_APPLICATION_PRE_DELETE = 'application.pre.delete';
39 39
 
40 40
     /**
41 41
      * Event is fired when the status of an application is changed
42 42
      */
43
-    const EVENT_APPLICATION_STATUS_CHANGE   = 'application.status.change';
43
+    const EVENT_APPLICATION_STATUS_CHANGE = 'application.status.change';
44 44
 
45 45
     /**
46 46
      * @var Application $application
@@ -233,12 +233,12 @@  discard block
 block discarded – undo
233 233
             $this->setApplicationEntity($params->application);
234 234
         }
235 235
 
236
-        if(is_array($params) && isset($params['user'])) {
236
+        if (is_array($params) && isset($params['user'])) {
237 237
             $this->setUser($params['user']);
238 238
             unset($params['user']);
239 239
         }
240 240
 
241
-        if(is_array($params) && isset($params['status'])) {
241
+        if (is_array($params) && isset($params['status'])) {
242 242
             $this->setStatus($params['status']);
243 243
             unset($params['status']);
244 244
         }
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
     }
169 169
 
170 170
     /**
171
-     * @return mixed
171
+     * @return string
172 172
      */
173 173
     public function getStatus()
174 174
     {
@@ -176,7 +176,7 @@  discard block
 block discarded – undo
176 176
     }
177 177
 
178 178
     /**
179
-     * @return mixed
179
+     * @return boolean
180 180
      */
181 181
     public function isPostRequest()
182 182
     {
Please login to merge, or discard this patch.
module/Applications/src/Applications/Controller/IndexController.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
             $params->set('by', 'me');
41 41
         }
42 42
 
43
-         //default sorting
43
+            //default sorting
44 44
         if (!isset($params['sort'])) {
45 45
             $params['sort']="-date";
46 46
         }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,10 +42,10 @@
 block discarded – undo
42 42
 
43 43
          //default sorting
44 44
         if (!isset($params['sort'])) {
45
-            $params['sort']="-date";
45
+            $params['sort'] = "-date";
46 46
         }
47 47
         $params->count = 5;
48
-        $params->pageRange=5;
48
+        $params->pageRange = 5;
49 49
 
50 50
         $this->paginationParams()->setParams('Applications\Index', $params);
51 51
 
Please login to merge, or discard this patch.
module/Core/src/Core/Form/LocalizationSettingsFieldset.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
             )
47 47
         );
48 48
 
49
-        $timezones=array_merge(
49
+        $timezones = array_merge(
50 50
             \DateTimeZone::listIdentifiers(\DateTimeZone::AFRICA),
51 51
             \DateTimeZone::listIdentifiers(\DateTimeZone::AMERICA),
52 52
             \DateTimeZone::listIdentifiers(\DateTimeZone::ASIA),
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/View/Helper/ApplyButtons.php 2 patches
Indentation   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
             'sendImmediately' => false
72 72
         ], $options);
73 73
         $view = $this->view;
74
-		$currentTemplate = $view->viewModel()
74
+        $currentTemplate = $view->viewModel()
75 75
             ->getCurrent()
76 76
             ->getTemplate();
77 77
         $partial = dirname($currentTemplate) . '/' . $options['partial'];
@@ -87,10 +87,10 @@  discard block
 block discarded – undo
87 87
             $label = $options['oneClickLabel'] ?: $view->translate('Apply with %s');
88 88
             
89 89
             foreach ($data['oneClickProfiles'] as $network) {
90
-				$variables['oneClick'][] = [
90
+                $variables['oneClick'][] = [
91 91
                     'label' => sprintf($label, $network),
92 92
                     'url' => $view->url('lang/apply-one-click', ['applyId' => $data['applyId'], 'network' => $network, 'immediately' => $options['sendImmediately'] ?: null], ['force_canonical' => true]),
93
-				    'network' => $network
93
+                    'network' => $network
94 94
                 ];
95 95
             }
96 96
         }
@@ -98,22 +98,22 @@  discard block
 block discarded – undo
98 98
         return $view->partial($partial, $variables);
99 99
     }
100 100
     
101
-	/**
102
-	 * @return string
103
-	 */
104
-	public function getPartial()
105
-	{
106
-		return $this->partial;
107
-	}
101
+    /**
102
+     * @return string
103
+     */
104
+    public function getPartial()
105
+    {
106
+        return $this->partial;
107
+    }
108 108
 
109
-	/**
110
-	 * @param string $partial
111
-	 * @return ApplyButtons
112
-	 */
113
-	public function setPartial($partial)
114
-	{
115
-		$this->partial = $partial;
109
+    /**
110
+     * @param string $partial
111
+     * @return ApplyButtons
112
+     */
113
+    public function setPartial($partial)
114
+    {
115
+        $this->partial = $partial;
116 116
 		
117
-		return $this;
118
-	}
117
+        return $this;
118
+    }
119 119
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@
 block discarded – undo
74 74
 		$currentTemplate = $view->viewModel()
75 75
             ->getCurrent()
76 76
             ->getTemplate();
77
-        $partial = dirname($currentTemplate) . '/' . $options['partial'];
77
+        $partial = dirname($currentTemplate).'/'.$options['partial'];
78 78
         
79 79
         if (!$options['oneClickOnly'] && $data['uri']) {
80 80
             $variables['default'] = [
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Entity/AtsMode.php 2 patches
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -208,13 +208,13 @@  discard block
 block discarded – undo
208 208
         return $this->email;
209 209
     }
210 210
 
211
-	/**
212
-	 * @return bool
213
-	 */
214
-	public function getOneClickApply()
215
-	{
216
-		return $this->oneClickApply;
217
-	}
211
+    /**
212
+     * @return bool
213
+     */
214
+    public function getOneClickApply()
215
+    {
216
+        return $this->oneClickApply;
217
+    }
218 218
 
219 219
 
220 220
     /**
@@ -222,29 +222,29 @@  discard block
 block discarded – undo
222 222
      *
223 223
      * @return $this
224 224
      */
225
-	public function setOneClickApply($oneClickApply)
226
-	{
227
-		$this->oneClickApply = (bool)$oneClickApply;
225
+    public function setOneClickApply($oneClickApply)
226
+    {
227
+        $this->oneClickApply = (bool)$oneClickApply;
228 228
 		
229
-		return $this;
230
-	}
231
-
232
-	/**
233
-	 * @return array
234
-	 */
235
-	public function getOneClickApplyProfiles()
236
-	{
237
-		return $this->oneClickApplyProfiles;
238
-	}
239
-
240
-	/**
241
-	 * @param array $oneClickApplyProfiles
242
-	 * @return AtsMode
243
-	 */
244
-	public function setOneClickApplyProfiles(array $oneClickApplyProfiles)
245
-	{
246
-		$this->oneClickApplyProfiles = $oneClickApplyProfiles;
229
+        return $this;
230
+    }
231
+
232
+    /**
233
+     * @return array
234
+     */
235
+    public function getOneClickApplyProfiles()
236
+    {
237
+        return $this->oneClickApplyProfiles;
238
+    }
239
+
240
+    /**
241
+     * @param array $oneClickApplyProfiles
242
+     * @return AtsMode
243
+     */
244
+    public function setOneClickApplyProfiles(array $oneClickApplyProfiles)
245
+    {
246
+        $this->oneClickApplyProfiles = $oneClickApplyProfiles;
247 247
 		
248
-		return $this;
249
-	}
248
+        return $this;
249
+    }
250 250
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -224,7 +224,7 @@
 block discarded – undo
224 224
      */
225 225
 	public function setOneClickApply($oneClickApply)
226 226
 	{
227
-		$this->oneClickApply = (bool)$oneClickApply;
227
+		$this->oneClickApply = (bool) $oneClickApply;
228 228
 		
229 229
 		return $this;
230 230
 	}
Please login to merge, or discard this patch.