@@ -25,7 +25,7 @@ |
||
25 | 25 | $authManager = ($user->isManager() && |
26 | 26 | $jobApplication->job_poster->manager->user->is($user)); |
27 | 27 | |
28 | - return $authApplicant||$authManager; |
|
28 | + return $authApplicant || $authManager; |
|
29 | 29 | } |
30 | 30 | |
31 | 31 | /** |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | |
61 | 61 | factory(JobPoster::class, 3)->state('published')->create([ |
62 | 62 | 'manager_id' => $managerUser->manager->id |
63 | - ])->each(function ($job) : void { |
|
63 | + ])->each(function($job) : void { |
|
64 | 64 | $job->job_applications()->saveMany(factory(JobApplication::class, 5))->create([ |
65 | 65 | 'job_poster_id' => $job->id |
66 | 66 | ]); |
@@ -74,7 +74,7 @@ discard block |
||
74 | 74 | }); |
75 | 75 | factory(JobPoster::class, 3)->state('closed')->create([ |
76 | 76 | 'manager_id' => $managerUser->manager->id |
77 | - ])->each(function ($job) : void { |
|
77 | + ])->each(function($job) : void { |
|
78 | 78 | $job->job_applications()->saveMany(factory(JobApplication::class, 5))->create([ |
79 | 79 | 'job_poster_id' => $job->id |
80 | 80 | ]); |
@@ -9,7 +9,7 @@ |
||
9 | 9 | 'prefix' => config('backpack.base.route_prefix', 'admin'), |
10 | 10 | 'middleware' => ['web', config('backpack.base.middleware_key', 'admin')], |
11 | 11 | 'namespace' => 'App\Http\Controllers\Admin', |
12 | -], function () : void { |
|
12 | +], function() : void { |
|
13 | 13 | // Custom admin routes. |
14 | 14 | Route::crud('skill', 'SkillCrudController'); |
15 | 15 | Route::crud('job-poster', 'JobPosterCrudController'); |
@@ -12,11 +12,11 @@ |
||
12 | 12 | class CriteriaController extends Controller |
13 | 13 | { |
14 | 14 | /** |
15 | - * Converts a Criteria to the shape sent and recieved by the api. |
|
16 | - * |
|
17 | - * @param Criteria $model |
|
18 | - * @return void |
|
19 | - */ |
|
15 | + * Converts a Criteria to the shape sent and recieved by the api. |
|
16 | + * |
|
17 | + * @param Criteria $model |
|
18 | + * @return void |
|
19 | + */ |
|
20 | 20 | public function toApiArray(Criteria $model) |
21 | 21 | { |
22 | 22 | return array_merge($model->toArray(), $model->getTranslationsArray()); |
@@ -62,7 +62,7 @@ |
||
62 | 62 | } |
63 | 63 | } |
64 | 64 | |
65 | - $isUnsaved = function ($criteria, $savedIds): bool { |
|
65 | + $isUnsaved = function($criteria, $savedIds): bool { |
|
66 | 66 | return !array_key_exists('id', $criteria) || !in_array($criteria['id'], $savedIds); |
67 | 67 | }; |
68 | 68 |
@@ -190,10 +190,10 @@ discard block |
||
190 | 190 | } |
191 | 191 | |
192 | 192 | /** |
193 | - * Check if the user has the specified role. |
|
194 | - * @param string $role This may be either 'applicant', 'manager', 'hr_advisor' or 'admin'. |
|
195 | - * @return boolean |
|
196 | - */ |
|
193 | + * Check if the user has the specified role. |
|
194 | + * @param string $role This may be either 'applicant', 'manager', 'hr_advisor' or 'admin'. |
|
195 | + * @return boolean |
|
196 | + */ |
|
197 | 197 | public function hasRole($role) |
198 | 198 | { |
199 | 199 | switch ($role) { |
@@ -214,8 +214,8 @@ discard block |
||
214 | 214 | * Set this user to the specified role. |
215 | 215 | * |
216 | 216 | * @param string $role Must be either 'applicant', 'manager', 'hr_advisor' or 'admin'. |
217 | - * @return void |
|
218 | - */ |
|
217 | + * @return void |
|
218 | + */ |
|
219 | 219 | public function setRole(string $role): void |
220 | 220 | { |
221 | 221 | $this->user_role()->associate(UserRole::where('name', $role)->firstOrFail()); |
@@ -250,7 +250,7 @@ discard block |
||
250 | 250 | * Returns a user's full name. |
251 | 251 | * |
252 | 252 | * @return string |
253 | - */ |
|
253 | + */ |
|
254 | 254 | public function getFullNameAttribute(): string |
255 | 255 | { |
256 | 256 | return $this->first_name . ' ' . $this->last_name; |
@@ -234,6 +234,6 @@ |
||
234 | 234 | */ |
235 | 235 | public function getFullNameAttribute(): string |
236 | 236 | { |
237 | - return $this->first_name . ' ' . $this->last_name; |
|
237 | + return $this->first_name.' '.$this->last_name; |
|
238 | 238 | } |
239 | 239 | } |
@@ -238,12 +238,12 @@ |
||
238 | 238 | 'logout_link' => route('hr_advisor.logout'), |
239 | 239 | ]; |
240 | 240 | } elseif (WhichPortal::isAdminPortal()) { |
241 | - $loginModals = [ |
|
241 | + $loginModals = [ |
|
242 | 242 | 'modals' => Lang::get('common/login_modals'), |
243 | 243 | 'register_link' => route('register'), |
244 | 244 | 'login_link' => backpack_url('login'), |
245 | 245 | 'logout_link' => backpack_url('logout'), |
246 | - ]; |
|
246 | + ]; |
|
247 | 247 | } else { |
248 | 248 | $loginModals = [ |
249 | 249 | 'modals' => Lang::get('common/login_modals'), |
@@ -366,7 +366,7 @@ discard block |
||
366 | 366 | */ |
367 | 367 | public function submitted_applications() // phpcs:ignore |
368 | 368 | { |
369 | - return $this->hasMany(\App\Models\JobApplication::class)->whereDoesntHave('application_status', function ($query): void { |
|
369 | + return $this->hasMany(\App\Models\JobApplication::class)->whereDoesntHave('application_status', function($query): void { |
|
370 | 370 | $query->where('name', 'draft'); |
371 | 371 | }); |
372 | 372 | } |
@@ -555,7 +555,7 @@ discard block |
||
555 | 555 | public function getClassificationMessageAttribute() |
556 | 556 | { |
557 | 557 | if ($this->classification_id !== null && $this->classification_level !== null) { |
558 | - return $this->classification->key . '-0' . $this->classification_level; |
|
558 | + return $this->classification->key.'-0'.$this->classification_level; |
|
559 | 559 | } |
560 | 560 | return null; |
561 | 561 | } |
@@ -187,7 +187,7 @@ |
||
187 | 187 | public function getFullNameAttribute(): string |
188 | 188 | { |
189 | 189 | if ($this->user !== null) { |
190 | - return $this->user->first_name . ' ' . $this->user->last_name; |
|
190 | + return $this->user->first_name.' '.$this->user->last_name; |
|
191 | 191 | } |
192 | 192 | return ''; |
193 | 193 | } |
@@ -38,7 +38,7 @@ |
||
38 | 38 | } |
39 | 39 | |
40 | 40 | //Log when application is first created |
41 | - if($application->wasRecentlyCreated) { |
|
41 | + if ($application->wasRecentlyCreated) { |
|
42 | 42 | $applicationText = "{id=".$application->id.", status=".$application->application_status->name."}"; |
43 | 43 | |
44 | 44 | Log::notice("Application created: application ".$applicationText." has been created by user ".$userText); |