Completed
Push — develop ( 864a1a...718342 )
by
unknown
06:53
created
module/Behat/src/JobContext.php 3 patches
Indentation   +273 added lines, -273 removed lines patch added patch discarded remove patch
@@ -33,312 +33,312 @@
 block discarded – undo
33 33
  */
34 34
 class JobContext implements Context
35 35
 {
36
-	use CommonContextTrait;
36
+    use CommonContextTrait;
37 37
 	
38
-	/**
39
-	 * @var Select2Context
40
-	 */
41
-	private $select2Context;
38
+    /**
39
+     * @var Select2Context
40
+     */
41
+    private $select2Context;
42 42
 	
43
-	/**
44
-	 * @var Job
45
-	 */
46
-	private $currentJob;
43
+    /**
44
+     * @var Job
45
+     */
46
+    private $currentJob;
47 47
 	
48
-	/**
49
-	 * @var JobRepository
50
-	 */
51
-	static private $jobRepo;
48
+    /**
49
+     * @var JobRepository
50
+     */
51
+    static private $jobRepo;
52 52
 	
53
-	/**
54
-	 * @param User $user
55
-	 */
56
-	static public function removeJobByUser(User $user)
57
-	{
58
-		$repo = static::$jobRepo;
59
-		$results = $repo->findBy(['user' => $user]);
60
-		foreach($results as $result){
61
-			$repo->remove($result,true);
62
-		}
63
-	}
53
+    /**
54
+     * @param User $user
55
+     */
56
+    static public function removeJobByUser(User $user)
57
+    {
58
+        $repo = static::$jobRepo;
59
+        $results = $repo->findBy(['user' => $user]);
60
+        foreach($results as $result){
61
+            $repo->remove($result,true);
62
+        }
63
+    }
64 64
 	
65
-	/**
66
-	 * @BeforeScenario
67
-	 *
68
-	 * @param BeforeScenarioScope $scope
69
-	 */
70
-	public function beforeScenario(BeforeScenarioScope $scope)
71
-	{
72
-		$this->select2Context = $scope->getEnvironment()->getContext(Select2Context::class);
73
-		if(is_null(static::$jobRepo)){
74
-			$this->gatherContexts($scope);
75
-			static::$jobRepo = $this->getJobRepository();
76
-		}
77
-	}
65
+    /**
66
+     * @BeforeScenario
67
+     *
68
+     * @param BeforeScenarioScope $scope
69
+     */
70
+    public function beforeScenario(BeforeScenarioScope $scope)
71
+    {
72
+        $this->select2Context = $scope->getEnvironment()->getContext(Select2Context::class);
73
+        if(is_null(static::$jobRepo)){
74
+            $this->gatherContexts($scope);
75
+            static::$jobRepo = $this->getJobRepository();
76
+        }
77
+    }
78 78
 	
79
-	/**
80
-	 * @Given I go to job board page
81
-	 */
82
-	public function iGoToJobBoardPage()
83
-	{
84
-		$this->visit('/en/jobboard');
85
-	}
79
+    /**
80
+     * @Given I go to job board page
81
+     */
82
+    public function iGoToJobBoardPage()
83
+    {
84
+        $this->visit('/en/jobboard');
85
+    }
86 86
 	
87
-	/**
88
-	 * @Given I go to create job page
89
-	 */
90
-	public function iGoToMyOrganizationPage()
91
-	{
92
-		$this->visit('/en/jobs/edit');
93
-	}
87
+    /**
88
+     * @Given I go to create job page
89
+     */
90
+    public function iGoToMyOrganizationPage()
91
+    {
92
+        $this->visit('/en/jobs/edit');
93
+    }
94 94
 	
95
-	/**
96
-	 * @Given I go to job overview page
97
-	 */
98
-	public function iGoToJobOverviewPage()
99
-	{
100
-		$this->visit('/en/jobs');
101
-	}
95
+    /**
96
+     * @Given I go to job overview page
97
+     */
98
+    public function iGoToJobOverviewPage()
99
+    {
100
+        $this->visit('/en/jobs');
101
+    }
102 102
 	
103
-	/**
104
-	 * @Given I go to edit job draft with title :jobTitle
105
-	 * @param $jobTitle
106
-	 * @throws \Exception when job is not found
107
-	 */
108
-	public function iGoToEditJobWithTitle($jobTitle)
109
-	{
110
-		$job = $this->getJobRepository()->findOneBy(['title' => $jobTitle]);
111
-		if(!$job instanceof Job){
112
-			throw new \Exception(sprintf('Job with title "%s" is not found',$jobTitle));
113
-		}
114
-		$this->currentJob = $job;
115
-		$url = '/en/jobs/edit?id='.$job->getId();
116
-		$this->visit($url);
117
-	}
103
+    /**
104
+     * @Given I go to edit job draft with title :jobTitle
105
+     * @param $jobTitle
106
+     * @throws \Exception when job is not found
107
+     */
108
+    public function iGoToEditJobWithTitle($jobTitle)
109
+    {
110
+        $job = $this->getJobRepository()->findOneBy(['title' => $jobTitle]);
111
+        if(!$job instanceof Job){
112
+            throw new \Exception(sprintf('Job with title "%s" is not found',$jobTitle));
113
+        }
114
+        $this->currentJob = $job;
115
+        $url = '/en/jobs/edit?id='.$job->getId();
116
+        $this->visit($url);
117
+    }
118 118
 	
119
-	/**
120
-	 * @Given I don't have any classification data
121
-	 */
122
-	public function iDonTHaveAnyClassificationData()
123
-	{
124
-		$this->currentJob->setClassifications(new Classifications());
125
-		$this->getJobRepository()->store($this->currentJob);
126
-	}
119
+    /**
120
+     * @Given I don't have any classification data
121
+     */
122
+    public function iDonTHaveAnyClassificationData()
123
+    {
124
+        $this->currentJob->setClassifications(new Classifications());
125
+        $this->getJobRepository()->store($this->currentJob);
126
+    }
127 127
 	
128
-	/**
129
-	 * @When I don't have any posted job
130
-	 */
131
-	public function iDonTHaveAnyPostedJob()
132
-	{
133
-		/* @var $jobRepository JobRepository */
134
-		/* @var $job Job */
135
-		$user = $this->getCurrentUser();
136
-		$jobRepository = $this->getJobRepository();
137
-		$results = $jobRepository->getUserJobs($user->getId());
138
-		foreach($results as $job){
139
-			$jobRepository->remove($job,true);
140
-		}
141
-		$this->currentJob = null;
142
-	}
128
+    /**
129
+     * @When I don't have any posted job
130
+     */
131
+    public function iDonTHaveAnyPostedJob()
132
+    {
133
+        /* @var $jobRepository JobRepository */
134
+        /* @var $job Job */
135
+        $user = $this->getCurrentUser();
136
+        $jobRepository = $this->getJobRepository();
137
+        $results = $jobRepository->getUserJobs($user->getId());
138
+        foreach($results as $job){
139
+            $jobRepository->remove($job,true);
140
+        }
141
+        $this->currentJob = null;
142
+    }
143 143
 	
144
-	/**
145
-	 * @When I fill job location search with :search and choose :choice
146
-	 *
147
-	 */
148
-	public function iFillJobLocationAndChoose($search,$choice)
149
-	{
150
-		$select2 = $this->select2Context;
151
-		$select2->iFillInSelect2FieldWith('jobBase[geoLocation]',$search,$choice);
152
-	}
144
+    /**
145
+     * @When I fill job location search with :search and choose :choice
146
+     *
147
+     */
148
+    public function iFillJobLocationAndChoose($search,$choice)
149
+    {
150
+        $select2 = $this->select2Context;
151
+        $select2->iFillInSelect2FieldWith('jobBase[geoLocation]',$search,$choice);
152
+    }
153 153
 	
154
-	/**
155
-	 * @When I choose :value from :field
156
-	 */
157
-	public function iJobClassificationSelect($value,$field)
158
-	{
159
-		$field = Inflector::camelize($field);
154
+    /**
155
+     * @When I choose :value from :field
156
+     */
157
+    public function iJobClassificationSelect($value,$field)
158
+    {
159
+        $field = Inflector::camelize($field);
160 160
 		
161
-		$mapSelect2 = [
162
-			'professions' => '#classifications-professions-span .select2-container',
163
-			'industries'  => '#classifications-industries-span .select2-container',
164
-			'employmentTypes' => '#classifications-employmentTypes-span .select2-container',
165
-		];
161
+        $mapSelect2 = [
162
+            'professions' => '#classifications-professions-span .select2-container',
163
+            'industries'  => '#classifications-industries-span .select2-container',
164
+            'employmentTypes' => '#classifications-employmentTypes-span .select2-container',
165
+        ];
166 166
 		
167
-		$mapMultiple = [
168
-			'professions'       => "select#classifications-professions",
169
-			'industries'        => "select#classifications-industries",
170
-			'employmentTypes'    => "select#classifications-employmentTypes",
171
-		];
167
+        $mapMultiple = [
168
+            'professions'       => "select#classifications-professions",
169
+            'industries'        => "select#classifications-industries",
170
+            'employmentTypes'    => "select#classifications-employmentTypes",
171
+        ];
172 172
 		
173
-		if(!isset($mapSelect2[$field])){
174
-			throw new \Exception('Undefined field selection value "'.$field.'"');
175
-		}
173
+        if(!isset($mapSelect2[$field])){
174
+            throw new \Exception('Undefined field selection value "'.$field.'"');
175
+        }
176 176
 		
177
-		$multipleField = $mapMultiple[$field];
178
-		$page = $this->minkContext->getSession()->getPage();
179
-		$element = $page->find('css',$mapMultiple[$field]);
180
-		if(!is_null($element) && $element->getAttribute('multiple')=='multiple'){
181
-			$this->minkContext->selectOption($value,$multipleField);
182
-		}else{
183
-			$locator = $mapSelect2[$field];
184
-			$this->select2Context->iFillInSelect2Field($locator,$value);
185
-		}
186
-	}
177
+        $multipleField = $mapMultiple[$field];
178
+        $page = $this->minkContext->getSession()->getPage();
179
+        $element = $page->find('css',$mapMultiple[$field]);
180
+        if(!is_null($element) && $element->getAttribute('multiple')=='multiple'){
181
+            $this->minkContext->selectOption($value,$multipleField);
182
+        }else{
183
+            $locator = $mapSelect2[$field];
184
+            $this->select2Context->iFillInSelect2Field($locator,$value);
185
+        }
186
+    }
187 187
 	
188
-	/**
189
-	 * @return JobRepository
190
-	 */
191
-	public function getJobRepository()
192
-	{
193
-		return $this->getRepository('Jobs/Job');
194
-	}
188
+    /**
189
+     * @return JobRepository
190
+     */
191
+    public function getJobRepository()
192
+    {
193
+        return $this->getRepository('Jobs/Job');
194
+    }
195 195
 	
196
-	/**
197
-	 * @return CategoriesRepo
198
-	 */
199
-	public function getCategoriesRepository()
200
-	{
201
-		return $this->getRepository('Jobs/Category');
202
-	}
196
+    /**
197
+     * @return CategoriesRepo
198
+     */
199
+    public function getCategoriesRepository()
200
+    {
201
+        return $this->getRepository('Jobs/Category');
202
+    }
203 203
 	
204
-	/**
205
-	 * @When I have a :status job with the following:
206
-	 * @param TableNode $fields
207
-	 */
208
-	public function iHaveAJobWithTheFollowing($status,TableNode $fields)
209
-	{
210
-		$normalizedField = [
211
-			'template' => 'modern',
212
-		];
213
-		foreach($fields->getRowsHash() as $field => $value){
214
-			$field = Inflector::camelize($field);
215
-			if($field == 'professions' || $field == 'industries'){
216
-				$value = explode(',',$value);
217
-			}
218
-			$normalizedField[$field] = $value;
219
-		}
220
-		$jobRepo = $this->getJobRepository();
221
-		$job = $jobRepo->findOneBy(['title' => $normalizedField['title']]);
222
-		if(!$job instanceof Job){
223
-			$job = new Job();
224
-			$job->setTitle($normalizedField['title']);
225
-		}
226
-		if(isset($normalizedField['user'])){
227
-			/* @var $userRepo UserRepository */
228
-			$userRepo = $this->getRepository('Auth\Entity\User');
229
-			$user = $userRepo->findOneBy(['login' => $normalizedField['user']]);
230
-			if($user instanceof User){
231
-				$job->setUser($user);
232
-				$job->setOrganization($user->getOrganization()->getOrganization());
233
-			}else{
234
-				throw new \Exception('There is no user with this login:"'.$normalizedField['user'.'"']);
235
-			}
236
-		}
204
+    /**
205
+     * @When I have a :status job with the following:
206
+     * @param TableNode $fields
207
+     */
208
+    public function iHaveAJobWithTheFollowing($status,TableNode $fields)
209
+    {
210
+        $normalizedField = [
211
+            'template' => 'modern',
212
+        ];
213
+        foreach($fields->getRowsHash() as $field => $value){
214
+            $field = Inflector::camelize($field);
215
+            if($field == 'professions' || $field == 'industries'){
216
+                $value = explode(',',$value);
217
+            }
218
+            $normalizedField[$field] = $value;
219
+        }
220
+        $jobRepo = $this->getJobRepository();
221
+        $job = $jobRepo->findOneBy(['title' => $normalizedField['title']]);
222
+        if(!$job instanceof Job){
223
+            $job = new Job();
224
+            $job->setTitle($normalizedField['title']);
225
+        }
226
+        if(isset($normalizedField['user'])){
227
+            /* @var $userRepo UserRepository */
228
+            $userRepo = $this->getRepository('Auth\Entity\User');
229
+            $user = $userRepo->findOneBy(['login' => $normalizedField['user']]);
230
+            if($user instanceof User){
231
+                $job->setUser($user);
232
+                $job->setOrganization($user->getOrganization()->getOrganization());
233
+            }else{
234
+                throw new \Exception('There is no user with this login:"'.$normalizedField['user'.'"']);
235
+            }
236
+        }
237 237
 		
238
-		if($status == 'draft'){
239
-			$job->setIsDraft(true);
240
-		}elseif($status == 'published'){
241
-			$job->setIsDraft(false);
242
-			$job->setDatePublishStart(new \DateTime());
243
-		}
244
-		$job->setStatus(Status::ACTIVE);
238
+        if($status == 'draft'){
239
+            $job->setIsDraft(true);
240
+        }elseif($status == 'published'){
241
+            $job->setIsDraft(false);
242
+            $job->setDatePublishStart(new \DateTime());
243
+        }
244
+        $job->setStatus(Status::ACTIVE);
245 245
 		
246
-		if(isset($normalizedField['professions'])){
247
-			$this->addProfessions($job,$normalizedField['professions']);
248
-		}
246
+        if(isset($normalizedField['professions'])){
247
+            $this->addProfessions($job,$normalizedField['professions']);
248
+        }
249 249
 		
250
-		if(isset($normalizedField['industries'])){
251
-			$this->addIndustries($job,$normalizedField['industries']);
252
-		}
250
+        if(isset($normalizedField['industries'])){
251
+            $this->addIndustries($job,$normalizedField['industries']);
252
+        }
253 253
 		
254
-		if(isset($normalizedField['location'])){
255
-			$this->setLocation($job,$normalizedField['location']);
256
-		}
257
-		if(isset($normalizedField['employmentTypes'])){
258
-			$types = $this->getCategories([$normalizedField['employmentTypes']]);
259
-			$type = array_shift($types);
254
+        if(isset($normalizedField['location'])){
255
+            $this->setLocation($job,$normalizedField['location']);
256
+        }
257
+        if(isset($normalizedField['employmentTypes'])){
258
+            $types = $this->getCategories([$normalizedField['employmentTypes']]);
259
+            $type = array_shift($types);
260 260
 			
261
-			$job->getClassifications()->getEmploymentTypes()->getItems()->add($type);
262
-		}
263
-		if(isset($normalizedField['companyName'])){
264
-			$job->setCompany($normalizedField['companyName']);
265
-		}
261
+            $job->getClassifications()->getEmploymentTypes()->getItems()->add($type);
262
+        }
263
+        if(isset($normalizedField['companyName'])){
264
+            $job->setCompany($normalizedField['companyName']);
265
+        }
266 266
 		
267
-		$jobRepo->store($job);
268
-		$this->currentJob = $job;
269
-	}
267
+        $jobRepo->store($job);
268
+        $this->currentJob = $job;
269
+    }
270 270
 	
271
-	private function setLocation(Job $job, $term)
272
-	{
273
-		/* @var $client Photon */
274
-		$client = $this->coreContext->getServiceManager()->get('Geo/Client');
275
-		$result = $client->queryOne($term);
276
-		$location = new Location();
277
-		$serialized = Json::encode($result);
278
-		$location->fromString($serialized);
271
+    private function setLocation(Job $job, $term)
272
+    {
273
+        /* @var $client Photon */
274
+        $client = $this->coreContext->getServiceManager()->get('Geo/Client');
275
+        $result = $client->queryOne($term);
276
+        $location = new Location();
277
+        $serialized = Json::encode($result);
278
+        $location->fromString($serialized);
279 279
 		
280
-		$locations = $job->getLocations();
281
-		if(count($locations)){
282
-			$locations->clear();
283
-		}
284
-		$job->getLocations()->add($location);
285
-	}
280
+        $locations = $job->getLocations();
281
+        if(count($locations)){
282
+            $locations->clear();
283
+        }
284
+        $job->getLocations()->add($location);
285
+    }
286 286
 	
287
-	private function addProfessions(Job $job,$terms)
288
-	{
289
-		$professions = $this->getCategories($terms);
290
-		foreach($professions as $profession){
291
-			$job->getClassifications()->getProfessions()->getItems()->add($profession);
292
-		}
293
-	}
287
+    private function addProfessions(Job $job,$terms)
288
+    {
289
+        $professions = $this->getCategories($terms);
290
+        foreach($professions as $profession){
291
+            $job->getClassifications()->getProfessions()->getItems()->add($profession);
292
+        }
293
+    }
294 294
 	
295
-	private function addIndustries(Job $job, $terms)
296
-	{
297
-		$industries = $this->getCategories($terms);
298
-		foreach($industries as $industry){
299
-			$job->getClassifications()->getIndustries()->getItems()->add($industry);
300
-		}
301
-	}
295
+    private function addIndustries(Job $job, $terms)
296
+    {
297
+        $industries = $this->getCategories($terms);
298
+        foreach($industries as $industry){
299
+            $job->getClassifications()->getIndustries()->getItems()->add($industry);
300
+        }
301
+    }
302 302
 	
303
-	/**
304
-	 * @param array $categories
305
-	 *
306
-	 * @return mixed
307
-	 */
308
-	private function getCategories(array $categories)
309
-	{
310
-		$catRepo = $this->getCategoriesRepository();
303
+    /**
304
+     * @param array $categories
305
+     *
306
+     * @return mixed
307
+     */
308
+    private function getCategories(array $categories)
309
+    {
310
+        $catRepo = $this->getCategoriesRepository();
311 311
 		
312
-		// get a professions
313
-		$qb = $catRepo->createQueryBuilder()
314
-		              ->field('name')->in($categories)
315
-		              ->getQuery()
316
-		;
317
-		$results = $qb->execute();
318
-		return $results->toArray();
319
-	}
312
+        // get a professions
313
+        $qb = $catRepo->createQueryBuilder()
314
+                        ->field('name')->in($categories)
315
+                        ->getQuery()
316
+        ;
317
+        $results = $qb->execute();
318
+        return $results->toArray();
319
+    }
320 320
 	
321
-	/**
322
-	 * @return Job
323
-	 */
324
-	private function getCurrentUserJobDraft($jobTitle)
325
-	{
326
-		$repo = $this->getJobRepository();
327
-		$user = $this->getCurrentUser();
321
+    /**
322
+     * @return Job
323
+     */
324
+    private function getCurrentUserJobDraft($jobTitle)
325
+    {
326
+        $repo = $this->getJobRepository();
327
+        $user = $this->getCurrentUser();
328 328
 		
329
-		$job = $repo->findDraft($user);
329
+        $job = $repo->findDraft($user);
330 330
 		
331
-		if(is_null($job)){
332
-			$job = new Job();
333
-			$job
334
-				->setUser($user)
335
-				->setOrganization($user->getOrganization()->getOrganization())
336
-				->setStatus(StatusInterface::CREATED)
337
-			;
338
-			$job->setIsDraft(true);
339
-		}
340
-		$job->setTitle($jobTitle);
341
-		$repo->store($job);
342
-		return $job;
343
-	}
331
+        if(is_null($job)){
332
+            $job = new Job();
333
+            $job
334
+                ->setUser($user)
335
+                ->setOrganization($user->getOrganization()->getOrganization())
336
+                ->setStatus(StatusInterface::CREATED)
337
+            ;
338
+            $job->setIsDraft(true);
339
+        }
340
+        $job->setTitle($jobTitle);
341
+        $repo->store($job);
342
+        return $job;
343
+    }
344 344
 }
345 345
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +39 added lines, -39 removed lines patch added patch discarded remove patch
@@ -57,8 +57,8 @@  discard block
 block discarded – undo
57 57
 	{
58 58
 		$repo = static::$jobRepo;
59 59
 		$results = $repo->findBy(['user' => $user]);
60
-		foreach($results as $result){
61
-			$repo->remove($result,true);
60
+		foreach ($results as $result) {
61
+			$repo->remove($result, true);
62 62
 		}
63 63
 	}
64 64
 	
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 	public function beforeScenario(BeforeScenarioScope $scope)
71 71
 	{
72 72
 		$this->select2Context = $scope->getEnvironment()->getContext(Select2Context::class);
73
-		if(is_null(static::$jobRepo)){
73
+		if (is_null(static::$jobRepo)) {
74 74
 			$this->gatherContexts($scope);
75 75
 			static::$jobRepo = $this->getJobRepository();
76 76
 		}
@@ -108,8 +108,8 @@  discard block
 block discarded – undo
108 108
 	public function iGoToEditJobWithTitle($jobTitle)
109 109
 	{
110 110
 		$job = $this->getJobRepository()->findOneBy(['title' => $jobTitle]);
111
-		if(!$job instanceof Job){
112
-			throw new \Exception(sprintf('Job with title "%s" is not found',$jobTitle));
111
+		if (!$job instanceof Job) {
112
+			throw new \Exception(sprintf('Job with title "%s" is not found', $jobTitle));
113 113
 		}
114 114
 		$this->currentJob = $job;
115 115
 		$url = '/en/jobs/edit?id='.$job->getId();
@@ -135,8 +135,8 @@  discard block
 block discarded – undo
135 135
 		$user = $this->getCurrentUser();
136 136
 		$jobRepository = $this->getJobRepository();
137 137
 		$results = $jobRepository->getUserJobs($user->getId());
138
-		foreach($results as $job){
139
-			$jobRepository->remove($job,true);
138
+		foreach ($results as $job) {
139
+			$jobRepository->remove($job, true);
140 140
 		}
141 141
 		$this->currentJob = null;
142 142
 	}
@@ -145,16 +145,16 @@  discard block
 block discarded – undo
145 145
 	 * @When I fill job location search with :search and choose :choice
146 146
 	 *
147 147
 	 */
148
-	public function iFillJobLocationAndChoose($search,$choice)
148
+	public function iFillJobLocationAndChoose($search, $choice)
149 149
 	{
150 150
 		$select2 = $this->select2Context;
151
-		$select2->iFillInSelect2FieldWith('jobBase[geoLocation]',$search,$choice);
151
+		$select2->iFillInSelect2FieldWith('jobBase[geoLocation]', $search, $choice);
152 152
 	}
153 153
 	
154 154
 	/**
155 155
 	 * @When I choose :value from :field
156 156
 	 */
157
-	public function iJobClassificationSelect($value,$field)
157
+	public function iJobClassificationSelect($value, $field)
158 158
 	{
159 159
 		$field = Inflector::camelize($field);
160 160
 		
@@ -170,18 +170,18 @@  discard block
 block discarded – undo
170 170
 			'employmentTypes'    => "select#classifications-employmentTypes",
171 171
 		];
172 172
 		
173
-		if(!isset($mapSelect2[$field])){
173
+		if (!isset($mapSelect2[$field])) {
174 174
 			throw new \Exception('Undefined field selection value "'.$field.'"');
175 175
 		}
176 176
 		
177 177
 		$multipleField = $mapMultiple[$field];
178 178
 		$page = $this->minkContext->getSession()->getPage();
179
-		$element = $page->find('css',$mapMultiple[$field]);
180
-		if(!is_null($element) && $element->getAttribute('multiple')=='multiple'){
181
-			$this->minkContext->selectOption($value,$multipleField);
182
-		}else{
179
+		$element = $page->find('css', $mapMultiple[$field]);
180
+		if (!is_null($element) && $element->getAttribute('multiple') == 'multiple') {
181
+			$this->minkContext->selectOption($value, $multipleField);
182
+		} else {
183 183
 			$locator = $mapSelect2[$field];
184
-			$this->select2Context->iFillInSelect2Field($locator,$value);
184
+			$this->select2Context->iFillInSelect2Field($locator, $value);
185 185
 		}
186 186
 	}
187 187
 	
@@ -205,62 +205,62 @@  discard block
 block discarded – undo
205 205
 	 * @When I have a :status job with the following:
206 206
 	 * @param TableNode $fields
207 207
 	 */
208
-	public function iHaveAJobWithTheFollowing($status,TableNode $fields)
208
+	public function iHaveAJobWithTheFollowing($status, TableNode $fields)
209 209
 	{
210 210
 		$normalizedField = [
211 211
 			'template' => 'modern',
212 212
 		];
213
-		foreach($fields->getRowsHash() as $field => $value){
213
+		foreach ($fields->getRowsHash() as $field => $value) {
214 214
 			$field = Inflector::camelize($field);
215
-			if($field == 'professions' || $field == 'industries'){
216
-				$value = explode(',',$value);
215
+			if ($field == 'professions' || $field == 'industries') {
216
+				$value = explode(',', $value);
217 217
 			}
218 218
 			$normalizedField[$field] = $value;
219 219
 		}
220 220
 		$jobRepo = $this->getJobRepository();
221 221
 		$job = $jobRepo->findOneBy(['title' => $normalizedField['title']]);
222
-		if(!$job instanceof Job){
222
+		if (!$job instanceof Job) {
223 223
 			$job = new Job();
224 224
 			$job->setTitle($normalizedField['title']);
225 225
 		}
226
-		if(isset($normalizedField['user'])){
226
+		if (isset($normalizedField['user'])) {
227 227
 			/* @var $userRepo UserRepository */
228 228
 			$userRepo = $this->getRepository('Auth\Entity\User');
229 229
 			$user = $userRepo->findOneBy(['login' => $normalizedField['user']]);
230
-			if($user instanceof User){
230
+			if ($user instanceof User) {
231 231
 				$job->setUser($user);
232 232
 				$job->setOrganization($user->getOrganization()->getOrganization());
233
-			}else{
233
+			} else {
234 234
 				throw new \Exception('There is no user with this login:"'.$normalizedField['user'.'"']);
235 235
 			}
236 236
 		}
237 237
 		
238
-		if($status == 'draft'){
238
+		if ($status == 'draft') {
239 239
 			$job->setIsDraft(true);
240
-		}elseif($status == 'published'){
240
+		}elseif ($status == 'published') {
241 241
 			$job->setIsDraft(false);
242 242
 			$job->setDatePublishStart(new \DateTime());
243 243
 		}
244 244
 		$job->setStatus(Status::ACTIVE);
245 245
 		
246
-		if(isset($normalizedField['professions'])){
247
-			$this->addProfessions($job,$normalizedField['professions']);
246
+		if (isset($normalizedField['professions'])) {
247
+			$this->addProfessions($job, $normalizedField['professions']);
248 248
 		}
249 249
 		
250
-		if(isset($normalizedField['industries'])){
251
-			$this->addIndustries($job,$normalizedField['industries']);
250
+		if (isset($normalizedField['industries'])) {
251
+			$this->addIndustries($job, $normalizedField['industries']);
252 252
 		}
253 253
 		
254
-		if(isset($normalizedField['location'])){
255
-			$this->setLocation($job,$normalizedField['location']);
254
+		if (isset($normalizedField['location'])) {
255
+			$this->setLocation($job, $normalizedField['location']);
256 256
 		}
257
-		if(isset($normalizedField['employmentTypes'])){
257
+		if (isset($normalizedField['employmentTypes'])) {
258 258
 			$types = $this->getCategories([$normalizedField['employmentTypes']]);
259 259
 			$type = array_shift($types);
260 260
 			
261 261
 			$job->getClassifications()->getEmploymentTypes()->getItems()->add($type);
262 262
 		}
263
-		if(isset($normalizedField['companyName'])){
263
+		if (isset($normalizedField['companyName'])) {
264 264
 			$job->setCompany($normalizedField['companyName']);
265 265
 		}
266 266
 		
@@ -278,16 +278,16 @@  discard block
 block discarded – undo
278 278
 		$location->fromString($serialized);
279 279
 		
280 280
 		$locations = $job->getLocations();
281
-		if(count($locations)){
281
+		if (count($locations)) {
282 282
 			$locations->clear();
283 283
 		}
284 284
 		$job->getLocations()->add($location);
285 285
 	}
286 286
 	
287
-	private function addProfessions(Job $job,$terms)
287
+	private function addProfessions(Job $job, $terms)
288 288
 	{
289 289
 		$professions = $this->getCategories($terms);
290
-		foreach($professions as $profession){
290
+		foreach ($professions as $profession) {
291 291
 			$job->getClassifications()->getProfessions()->getItems()->add($profession);
292 292
 		}
293 293
 	}
@@ -295,7 +295,7 @@  discard block
 block discarded – undo
295 295
 	private function addIndustries(Job $job, $terms)
296 296
 	{
297 297
 		$industries = $this->getCategories($terms);
298
-		foreach($industries as $industry){
298
+		foreach ($industries as $industry) {
299 299
 			$job->getClassifications()->getIndustries()->getItems()->add($industry);
300 300
 		}
301 301
 	}
@@ -328,7 +328,7 @@  discard block
 block discarded – undo
328 328
 		
329 329
 		$job = $repo->findDraft($user);
330 330
 		
331
-		if(is_null($job)){
331
+		if (is_null($job)) {
332 332
 			$job = new Job();
333 333
 			$job
334 334
 				->setUser($user)
Please login to merge, or discard this patch.
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 		$element = $page->find('css',$mapMultiple[$field]);
180 180
 		if(!is_null($element) && $element->getAttribute('multiple')=='multiple'){
181 181
 			$this->minkContext->selectOption($value,$multipleField);
182
-		}else{
182
+		} else{
183 183
 			$locator = $mapSelect2[$field];
184 184
 			$this->select2Context->iFillInSelect2Field($locator,$value);
185 185
 		}
@@ -230,14 +230,14 @@  discard block
 block discarded – undo
230 230
 			if($user instanceof User){
231 231
 				$job->setUser($user);
232 232
 				$job->setOrganization($user->getOrganization()->getOrganization());
233
-			}else{
233
+			} else{
234 234
 				throw new \Exception('There is no user with this login:"'.$normalizedField['user'.'"']);
235 235
 			}
236 236
 		}
237 237
 		
238 238
 		if($status == 'draft'){
239 239
 			$job->setIsDraft(true);
240
-		}elseif($status == 'published'){
240
+		} elseif($status == 'published'){
241 241
 			$job->setIsDraft(false);
242 242
 			$job->setDatePublishStart(new \DateTime());
243 243
 		}
Please login to merge, or discard this patch.
module/Behat/src/ApplicationContext.php 2 patches
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -22,26 +22,26 @@
 block discarded – undo
22 22
  */
23 23
 class ApplicationContext implements Context
24 24
 {
25
-	use CommonContextTrait;
25
+    use CommonContextTrait;
26 26
 	
27
-	/**
28
-	 * @Given I apply for :title job
29
-	 *
30
-	 * @param string $title
31
-	 * @throws \Exception when the titled job not exists
32
-	 */
33
-	public function iApplyAJob($title)
34
-	{
35
-		/* @var $repo JobRepository */
36
-		$repo = $this->getRepository('Jobs/Job');
37
-		$job = $repo->findOneBy(['title' => $title]);
38
-		if(!$job instanceof Job){
39
-			throw new \Exception('There is no job titled: "'.$title.'"');
40
-		}
41
-		$job->setApplyId($job->getId());
42
-		$repo->store($job);
27
+    /**
28
+     * @Given I apply for :title job
29
+     *
30
+     * @param string $title
31
+     * @throws \Exception when the titled job not exists
32
+     */
33
+    public function iApplyAJob($title)
34
+    {
35
+        /* @var $repo JobRepository */
36
+        $repo = $this->getRepository('Jobs/Job');
37
+        $job = $repo->findOneBy(['title' => $title]);
38
+        if(!$job instanceof Job){
39
+            throw new \Exception('There is no job titled: "'.$title.'"');
40
+        }
41
+        $job->setApplyId($job->getId());
42
+        $repo->store($job);
43 43
 		
44
-		$url = '/en/apply/'.$job->getApplyId();
45
-		$this->visit($url);
46
-	}
44
+        $url = '/en/apply/'.$job->getApplyId();
45
+        $this->visit($url);
46
+    }
47 47
 }
48 48
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
 		/* @var $repo JobRepository */
36 36
 		$repo = $this->getRepository('Jobs/Job');
37 37
 		$job = $repo->findOneBy(['title' => $title]);
38
-		if(!$job instanceof Job){
38
+		if (!$job instanceof Job) {
39 39
 			throw new \Exception('There is no job titled: "'.$title.'"');
40 40
 		}
41 41
 		$job->setApplyId($job->getId());
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Listener/Publisher.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -171,13 +171,13 @@
 block discarded – undo
171 171
                     $response_externalIdUpdate = $decodedBody->applyIdUpdate;
172 172
 
173 173
                     if ($publisher->externalId != $response_externalIdUpdate || $publisher->reference != $response_referenceUpdate) {
174
-                    	$logInfo = 'RestCall changed externalID ['
175
-	                               . var_export($publisher->externalId, true)
176
-	                               . ' => '
177
-	                               . var_export($response_externalIdUpdate, true) . '], reference  ['
178
-	                               . var_export($publisher->reference, true)
179
-	                               . ' => '
180
-	                               . var_export($response_referenceUpdate, true) . ']';
174
+                        $logInfo = 'RestCall changed externalID ['
175
+                                    . var_export($publisher->externalId, true)
176
+                                    . ' => '
177
+                                    . var_export($response_externalIdUpdate, true) . '], reference  ['
178
+                                    . var_export($publisher->reference, true)
179
+                                    . ' => '
180
+                                    . var_export($response_referenceUpdate, true) . ']';
181 181
                         $log->info($logInfo);
182 182
                         $publisher->reference = $response_referenceUpdate;
183 183
                         $publisher->externalId = $response_externalIdUpdate;
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
      * @param EventManagerInterface $events
47 47
      * @return $this
48 48
      */
49
-    public function attach(EventManagerInterface $events, $priority=1)
49
+    public function attach(EventManagerInterface $events, $priority = 1)
50 50
     {
51 51
         return $this;
52 52
     }
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
                 $jsonLastError = json_last_error();
165 165
                 if (json_last_error() != JSON_ERROR_NONE) {
166 166
                     // not able to decode json
167
-                    $log->info('RestCall Response not Json [errorCode: ' . $jsonLastError . ']: ' . var_export($body, true));
167
+                    $log->info('RestCall Response not Json [errorCode: '.$jsonLastError.']: '.var_export($body, true));
168 168
                 } else {
169 169
                     // does the provider want to have an own ID for Identification ?
170 170
                     $response_referenceUpdate = $decodedBody->referenceUpdate;
@@ -174,10 +174,10 @@  discard block
 block discarded – undo
174 174
                     	$logInfo = 'RestCall changed externalID ['
175 175
 	                               . var_export($publisher->externalId, true)
176 176
 	                               . ' => '
177
-	                               . var_export($response_externalIdUpdate, true) . '], reference  ['
177
+	                               . var_export($response_externalIdUpdate, true).'], reference  ['
178 178
 	                               . var_export($publisher->reference, true)
179 179
 	                               . ' => '
180
-	                               . var_export($response_referenceUpdate, true) . ']';
180
+	                               . var_export($response_referenceUpdate, true).']';
181 181
                         $log->info($logInfo);
182 182
                         $publisher->reference = $response_referenceUpdate;
183 183
                         $publisher->externalId = $response_externalIdUpdate;
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Listener/MailSender.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
      */
107 107
     public function onJobAccepted(JobEvent $e)
108 108
     {
109
-    	$target = $e->getTarget();
109
+        $target = $e->getTarget();
110 110
     	
111 111
         $this->sendMail(
112 112
             $target->getJobEntity(),
@@ -141,13 +141,13 @@  discard block
 block discarded – undo
141 141
     {
142 142
         $mail = $this->mailer->get('htmltemplate');
143 143
         $mail->setTemplate($template)
144
-             ->setSubject($subject)
145
-             ->setVariables(
146
-                 array(
144
+                ->setSubject($subject)
145
+                ->setVariables(
146
+                    array(
147 147
                                 'job'      => $job,
148 148
                                 'siteName' => $this->options['siteName'],
149 149
                             )
150
-             );
150
+                );
151 151
 
152 152
         if ($adminMail) {
153 153
             $mail->setTo($this->options['adminEmail']);
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         $this->options = array_merge($this->options, $options);
63 63
     }
64 64
 
65
-    public function attach(EventManagerInterface $events, $priority=1)
65
+    public function attach(EventManagerInterface $events, $priority = 1)
66 66
     {
67 67
         $this->listeners[] = $events->attach(JobEvent::EVENT_JOB_CREATED, array($this, 'onJobCreated'));
68 68
         $this->listeners[] = $events->attach(JobEvent::EVENT_JOB_ACCEPTED, array($this, 'onJobAccepted'));
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/Filter/ViewModelTemplateFilterFactory.php 2 patches
Indentation   +47 added lines, -47 removed lines patch added patch discarded remove patch
@@ -31,54 +31,54 @@
 block discarded – undo
31 31
  */
32 32
 class ViewModelTemplateFilterFactory implements FactoryInterface
33 33
 {
34
-	/**
35
-	 * @var ServiceLocatorInterface
36
-	 */
37
-	protected $service;
34
+    /**
35
+     * @var ServiceLocatorInterface
36
+     */
37
+    protected $service;
38 38
 	
39
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
40
-	{
41
-		$this->service = $container;
42
-		return $this;
43
-	}
39
+    public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
40
+    {
41
+        $this->service = $container;
42
+        return $this;
43
+    }
44 44
 	
45
-	/**
46
-	 * @param $element
47
-	 * @return \Zend\View\Model\ViewModel
48
-	 * @throws \InvalidArgumentException
49
-	 * @TODO: [ZF3] renamed this method into getModel because conflict with FactoryInterface::__invoke() method
50
-	 */
51
-	public function getModel($element)
52
-	{
53
-		$filter = null;
54
-		if ($element instanceof EntityInterface) {
55
-			$filter = new ViewModelTemplateFilterJob;
56
-		}
57
-		if ($element instanceof Element) {
58
-			$filter = new ViewModelTemplateFilterForm;
59
-			$viewHelperManager = $this->service->get('ViewHelperManager');
60
-			$viewHelperForm = $viewHelperManager->get('formSimple');
61
-			$filter->setViewHelperForm($viewHelperForm);
62
-		}
63
-		if (!isset($filter)) {
64
-			throw new \InvalidArgumentException(get_class($element) . ' cannot be used to initialize a template');
65
-		}
66
-		$viewManager = $this->service->get('ViewHelperManager');
67
-		$basePathHelper = $viewManager->get('basePath');
68
-		$serverUrlHelper = $viewManager->get('serverUrl');
69
-		$imageFileCacheHelper = $this->service->get('Organizations\ImageFileCache\Manager');
70
-		$filter->setBasePathHelper($basePathHelper);
71
-		$filter->setImageFileCacheHelper($imageFileCacheHelper);
72
-		$filter->setServerUrlHelper($serverUrlHelper);
45
+    /**
46
+     * @param $element
47
+     * @return \Zend\View\Model\ViewModel
48
+     * @throws \InvalidArgumentException
49
+     * @TODO: [ZF3] renamed this method into getModel because conflict with FactoryInterface::__invoke() method
50
+     */
51
+    public function getModel($element)
52
+    {
53
+        $filter = null;
54
+        if ($element instanceof EntityInterface) {
55
+            $filter = new ViewModelTemplateFilterJob;
56
+        }
57
+        if ($element instanceof Element) {
58
+            $filter = new ViewModelTemplateFilterForm;
59
+            $viewHelperManager = $this->service->get('ViewHelperManager');
60
+            $viewHelperForm = $viewHelperManager->get('formSimple');
61
+            $filter->setViewHelperForm($viewHelperForm);
62
+        }
63
+        if (!isset($filter)) {
64
+            throw new \InvalidArgumentException(get_class($element) . ' cannot be used to initialize a template');
65
+        }
66
+        $viewManager = $this->service->get('ViewHelperManager');
67
+        $basePathHelper = $viewManager->get('basePath');
68
+        $serverUrlHelper = $viewManager->get('serverUrl');
69
+        $imageFileCacheHelper = $this->service->get('Organizations\ImageFileCache\Manager');
70
+        $filter->setBasePathHelper($basePathHelper);
71
+        $filter->setImageFileCacheHelper($imageFileCacheHelper);
72
+        $filter->setServerUrlHelper($serverUrlHelper);
73 73
 		
74
-		if($filter instanceof ViewModelTemplateFilterJob || method_exists($filter,'setJsonLdHelper')){
75
-			$jsonLdHelper = $viewManager->get(JsonLd::class);
76
-			$filter->setJsonLdHelper($jsonLdHelper);
77
-		}
78
-		$urlPlugin = $this->service->get('ControllerPluginManager')->get('url');
79
-		$filter->setUrlPlugin($urlPlugin);
80
-		$options = $this->service->get('Jobs/Options');
81
-		$filter->setConfig($options);
82
-		return $filter->filter($element);
83
-	}
74
+        if($filter instanceof ViewModelTemplateFilterJob || method_exists($filter,'setJsonLdHelper')){
75
+            $jsonLdHelper = $viewManager->get(JsonLd::class);
76
+            $filter->setJsonLdHelper($jsonLdHelper);
77
+        }
78
+        $urlPlugin = $this->service->get('ControllerPluginManager')->get('url');
79
+        $filter->setUrlPlugin($urlPlugin);
80
+        $options = $this->service->get('Jobs/Options');
81
+        $filter->setConfig($options);
82
+        return $filter->filter($element);
83
+    }
84 84
 }
85 85
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 	 */
37 37
 	protected $service;
38 38
 	
39
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
39
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
40 40
 	{
41 41
 		$this->service = $container;
42 42
 		return $this;
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
 			$filter->setViewHelperForm($viewHelperForm);
62 62
 		}
63 63
 		if (!isset($filter)) {
64
-			throw new \InvalidArgumentException(get_class($element) . ' cannot be used to initialize a template');
64
+			throw new \InvalidArgumentException(get_class($element).' cannot be used to initialize a template');
65 65
 		}
66 66
 		$viewManager = $this->service->get('ViewHelperManager');
67 67
 		$basePathHelper = $viewManager->get('basePath');
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 		$filter->setImageFileCacheHelper($imageFileCacheHelper);
72 72
 		$filter->setServerUrlHelper($serverUrlHelper);
73 73
 		
74
-		if($filter instanceof ViewModelTemplateFilterJob || method_exists($filter,'setJsonLdHelper')){
74
+		if ($filter instanceof ViewModelTemplateFilterJob || method_exists($filter, 'setJsonLdHelper')) {
75 75
 			$jsonLdHelper = $viewManager->get(JsonLd::class);
76 76
 			$filter->setJsonLdHelper($jsonLdHelper);
77 77
 		}
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/View/Helper/JobUrlFactory.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -47,10 +47,10 @@
 block discarded – undo
47 47
         $params    = $viewHelper->get('params');
48 48
         $serverUrl = $viewHelper->get('serverUrl');
49 49
 	
50
-	    $helper    = new JobUrl();
50
+        $helper    = new JobUrl();
51 51
         $helper->setUrlHelper($url)
52
-               ->setParamsHelper($params)
53
-               ->setServerUrlHelper($serverUrl);
52
+                ->setParamsHelper($params)
53
+                ->setServerUrlHelper($serverUrl);
54 54
         return $helper;
55 55
     }
56 56
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@
 block discarded – undo
47 47
         $params    = $viewHelper->get('params');
48 48
         $serverUrl = $viewHelper->get('serverUrl');
49 49
 	
50
-	    $helper    = new JobUrl();
50
+	    $helper = new JobUrl();
51 51
         $helper->setUrlHelper($url)
52 52
                ->setParamsHelper($params)
53 53
                ->setServerUrlHelper($serverUrl);
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/View/Helper/ApplyUrlFactory.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -44,11 +44,11 @@
 block discarded – undo
44 44
         $params    = $viewHelper->get('params');
45 45
         $serverUrl = $viewHelper->get('serverUrl');
46 46
         
47
-	    $helper    = new ApplyUrl();
47
+        $helper    = new ApplyUrl();
48 48
         $helper->setUrlHelper($url)
49
-               ->setTranslateHelper($translate)
50
-               ->setParamsHelper($params)
51
-               ->setServerUrlHelper($serverUrl);
49
+                ->setTranslateHelper($translate)
50
+                ->setParamsHelper($params)
51
+                ->setServerUrlHelper($serverUrl);
52 52
         return $helper;
53 53
     }
54 54
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
         $params    = $viewHelper->get('params');
45 45
         $serverUrl = $viewHelper->get('serverUrl');
46 46
         
47
-	    $helper    = new ApplyUrl();
47
+	    $helper = new ApplyUrl();
48 48
         $helper->setUrlHelper($url)
49 49
                ->setTranslateHelper($translate)
50 50
                ->setParamsHelper($params)
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/Controller/TemplateControllerFactory.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -33,17 +33,17 @@
 block discarded – undo
33 33
          */
34 34
         $jobRepository = $container->get('repositories')->get('Jobs/Job');
35 35
         $options = $container->get('Jobs/Options');
36
-		$viewModelTemplateFilter = $container->get('Jobs/ViewModelTemplateFilter');
37
-		$translator = $container->get('translator');
38
-		$viewHelper = $container->get('ViewHelperManager');
39
-		$formManager = $container->get('FormElementManager');
36
+        $viewModelTemplateFilter = $container->get('Jobs/ViewModelTemplateFilter');
37
+        $translator = $container->get('translator');
38
+        $viewHelper = $container->get('ViewHelperManager');
39
+        $formManager = $container->get('FormElementManager');
40 40
         return new TemplateController(
41
-        	$jobRepository,
42
-	        $viewModelTemplateFilter,
43
-	        $translator,
44
-	        $options,
45
-	        $viewHelper,
46
-	        $formManager
41
+            $jobRepository,
42
+            $viewModelTemplateFilter,
43
+            $translator,
44
+            $options,
45
+            $viewHelper,
46
+            $formManager
47 47
         );
48 48
     }
49 49
 }
Please login to merge, or discard this patch.
module/Jobs/src/Jobs/Factory/Controller/ManageControllerFactory.php 2 patches
Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -45,17 +45,17 @@
 block discarded – undo
45 45
         $jobEvents = $container->get('Jobs/Events');
46 46
         $jobEvent = $container->get('Jobs/Event');
47 47
         return new ManageController(
48
-        	$auth,
49
-	        $repositoryService,
50
-	        $translator,
51
-	        $filterManager,
52
-	        $jobFormEvents,
53
-	        $formManager,
54
-	        $options,
55
-	        $viewHelper,
56
-	        $validatorManager,
57
-	        $jobEvents,
58
-	        $jobEvent
48
+            $auth,
49
+            $repositoryService,
50
+            $translator,
51
+            $filterManager,
52
+            $jobFormEvents,
53
+            $formManager,
54
+            $options,
55
+            $viewHelper,
56
+            $validatorManager,
57
+            $jobEvents,
58
+            $jobEvent
59 59
         );
60 60
     }
61 61
 }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,8 +33,8 @@
 block discarded – undo
33 33
     {
34 34
         $auth = $container->get('AuthenticationService');
35 35
         /* @var RepositoryService     $repositoryService */
36
-        $repositoryService =    $container->get('repositories');
37
-        $translator =    $container->get('translator');
36
+        $repositoryService = $container->get('repositories');
37
+        $translator = $container->get('translator');
38 38
         $filterManager = $container->get('FilterManager');
39 39
         $jobFormEvents = $container->get('Jobs/JobContainer/Events');
40 40
         $formManager = $container->get('FormElementManager');
Please login to merge, or discard this patch.