Passed
Push — bugfix/random-ui-stuff ( 310aaf...d6d2ab )
by Josh
60:17 queued 49:01
created
app/Http/ViewComposers/ManagerPortalComposer.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -13,10 +13,10 @@
 block discarded – undo
13 13
      * @param  View  $view
14 14
      * @return void
15 15
      */
16
-    public function compose(View $view)
16
+    public function compose (View $view)
17 17
     {
18
-        $show_demo_notification = Auth::user() !== null && Auth::user()->isDemoManager();
19
-        $view->with([
18
+        $show_demo_notification = Auth::user () !== null && Auth::user ()->isDemoManager ();
19
+        $view->with ([
20 20
             'show_demo_notification' => $show_demo_notification,
21 21
         ]);
22 22
     }
Please login to merge, or discard this patch.
app/Http/ViewComposers/RelativeComposer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,8 +13,8 @@
 block discarded – undo
13 13
      * @param  View  $view
14 14
      * @return void
15 15
      */
16
-    public function compose(View $view)
16
+    public function compose (View $view)
17 17
     {
18
-        $view->with('relative_template', Lang::get('common/relatives'));
18
+        $view->with ('relative_template', Lang::get ('common/relatives'));
19 19
     }
20 20
 }
Please login to merge, or discard this patch.
app/Http/ViewComposers/ApplicationTrackerComposer.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -14,27 +14,27 @@
 block discarded – undo
14 14
      * @param  View  $view
15 15
      * @return void
16 16
      */
17
-    public function compose(View $view)
17
+    public function compose (View $view)
18 18
     {
19
-        $app_tracker = Lang::get('applicant/application_tracker');
19
+        $app_tracker = Lang::get ('applicant/application_tracker');
20 20
 
21 21
 
22
-        $app_tracker['items']['basics']['url'] = route('job.application.edit.1', $view->getData()['job']);
23
-        $app_tracker['items']['experience']['url'] = route('job.application.edit.2', $view->getData()['job']);
24
-        $app_tracker['items']['essential_skills']['url'] = route('job.application.edit.3', $view->getData()['job']);
25
-        $app_tracker['items']['asset_skills']['url'] = route('job.application.edit.4', $view->getData()['job']);
26
-        $app_tracker['items']['preview']['url'] = route('job.application.edit.5', $view->getData()['job']);
27
-        $app_tracker['items']['confirm']['url'] = route('job.application.edit.6', $view->getData()['job']);
22
+        $app_tracker['items']['basics']['url'] = route ('job.application.edit.1', $view->getData ()['job']);
23
+        $app_tracker['items']['experience']['url'] = route ('job.application.edit.2', $view->getData ()['job']);
24
+        $app_tracker['items']['essential_skills']['url'] = route ('job.application.edit.3', $view->getData ()['job']);
25
+        $app_tracker['items']['asset_skills']['url'] = route ('job.application.edit.4', $view->getData ()['job']);
26
+        $app_tracker['items']['preview']['url'] = route ('job.application.edit.5', $view->getData ()['job']);
27
+        $app_tracker['items']['confirm']['url'] = route ('job.application.edit.6', $view->getData ()['job']);
28 28
 
29 29
         //TODO: all these checks shouldn't be neccessary when controllers are properly set up
30
-        if (isset($view->getData()['job_application'])) {
31
-            $job_application = $view->getData()['job_application'];
30
+        if (isset($view->getData ()['job_application'])) {
31
+            $job_application = $view->getData ()['job_application'];
32 32
             if ($job_application != null && $job_application instanceof JobApplication) {
33
-                foreach($app_tracker['items'] as $key => $value) {
34
-                    $app_tracker['items'][$key]['status'] = $job_application->getSectionStatus($key);
33
+                foreach ($app_tracker['items'] as $key => $value) {
34
+                    $app_tracker['items'][$key]['status'] = $job_application->getSectionStatus ($key);
35 35
                 }
36 36
             }
37 37
         }
38
-        $view->with('application_tracker', $app_tracker);
38
+        $view->with ('application_tracker', $app_tracker);
39 39
     }
40 40
 }
Please login to merge, or discard this patch.
app/Http/ViewComposers/ReferenceComposer.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -20,13 +20,13 @@
 block discarded – undo
20 20
      *
21 21
      * @return void
22 22
      */
23
-    public function compose(View $view) : void
23
+    public function compose (View $view) : void
24 24
     {
25 25
         if (!$this->relationships) {
26
-            $this->relationships = Relationship::all();
26
+            $this->relationships = Relationship::all ();
27 27
         }
28 28
 
29
-        $view->with('relationships', $this->relationships);
30
-        $view->with('reference_template', Lang::get('common/references'));
29
+        $view->with ('relationships', $this->relationships);
30
+        $view->with ('reference_template', Lang::get ('common/references'));
31 31
     }
32 32
 }
Please login to merge, or discard this patch.
app/Http/ViewComposers/CourseComposer.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -20,13 +20,13 @@
 block discarded – undo
20 20
      *
21 21
      * @return void
22 22
      */
23
-    public function compose(View $view) : void
23
+    public function compose (View $view) : void
24 24
     {
25 25
         if (!$this->courseStatuses) {
26
-            $this->courseStatuses = CourseStatus::all();
26
+            $this->courseStatuses = CourseStatus::all ();
27 27
         }
28 28
 
29
-        $view->with('course_status', $this->courseStatuses);
30
-        $view->with('course_template', Lang::get('common/course'));
29
+        $view->with ('course_status', $this->courseStatuses);
30
+        $view->with ('course_template', Lang::get ('common/course'));
31 31
     }
32 32
 }
Please login to merge, or discard this patch.
app/Http/ViewComposers/GocComposer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,8 +13,8 @@
 block discarded – undo
13 13
      * @param  View  $view
14 14
      * @return void
15 15
      */
16
-    public function compose(View $view)
16
+    public function compose (View $view)
17 17
     {
18
-        $view->with('goc', Lang::get('common/goc'));
18
+        $view->with ('goc', Lang::get ('common/goc'));
19 19
     }
20 20
 }
Please login to merge, or discard this patch.
app/Http/Controllers/ApplicationReviewController.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -17,31 +17,31 @@
 block discarded – undo
17 17
      * @param  \App\Models\JobApplication $application Incoming Application.
18 18
      * @return \Illuminate\Http\Response
19 19
      */
20
-    public function updateForApplication(Request $request, JobApplication $application)
20
+    public function updateForApplication (Request $request, JobApplication $application)
21 21
     {
22
-        $request->validate([
22
+        $request->validate ([
23 23
             'review_status_id' => [
24 24
                 'nullable',
25
-                Rule::in(ReviewStatus::all()->pluck('id')->toArray())
25
+                Rule::in (ReviewStatus::all ()->pluck ('id')->toArray ())
26 26
             ],
27 27
             'notes' => 'nullable|string'
28 28
         ]);
29 29
 
30 30
         $review = $application->application_review;
31 31
         if ($review === null) {
32
-            $review = new ApplicationReview();
33
-            $review->job_application()->associate($application);
32
+            $review = new ApplicationReview ();
33
+            $review->job_application ()->associate ($application);
34 34
         }
35
-        $review->fill([
36
-            'review_status_id' => $request->input('review_status_id'),
37
-            'notes' => $request->input('notes'),
35
+        $review->fill ([
36
+            'review_status_id' => $request->input ('review_status_id'),
37
+            'notes' => $request->input ('notes'),
38 38
         ]);
39
-        $review->save();
39
+        $review->save ();
40 40
 
41
-        if ($request->ajax()) {
42
-            return $review->fresh()->toJson();
41
+        if ($request->ajax ()) {
42
+            return $review->fresh ()->toJson ();
43 43
         }
44 44
 
45
-        return redirect()->back();
45
+        return redirect ()->back ();
46 46
     }
47 47
 }
Please login to merge, or discard this patch.
app/Http/Controllers/FaqController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -12,13 +12,13 @@
 block discarded – undo
12 12
      *
13 13
      * @return View
14 14
      */
15
-    public function __invoke()
15
+    public function __invoke ()
16 16
     {
17
-        return view(
17
+        return view (
18 18
             'applicant/static_faq',
19 19
             [
20
-                'faq' => Lang::get('applicant/faq'),
21
-                'breadcrumb_home' => route('home'),
20
+                'faq' => Lang::get ('applicant/faq'),
21
+                'breadcrumb_home' => route ('home'),
22 22
                 'applicant_sidebar_active' => 'active',
23 23
             ]
24 24
         );
Please login to merge, or discard this patch.
app/Http/Controllers/AssessmentPlanController.php 1 patch
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -20,41 +20,41 @@
 block discarded – undo
20 20
      * @param  \App\Models\JobPoster $jobPoster Job Poster to retrieve assessment plan for.
21 21
      * @return mixed[]
22 22
      */
23
-    public function getForJob(JobPoster $jobPoster)
23
+    public function getForJob (JobPoster $jobPoster)
24 24
     {
25
-        if (Gate::denies('view-assessment-plan', $jobPoster)) {
26
-            abort(403);
25
+        if (Gate::denies ('view-assessment-plan', $jobPoster)) {
26
+            abort (403);
27 27
         }
28 28
 
29
-        $criteria = Criteria::where('job_poster_id', $jobPoster->id)->get();
29
+        $criteria = Criteria::where ('job_poster_id', $jobPoster->id)->get ();
30 30
         $criteriaTranslated = [];
31 31
         foreach ($criteria as $criterion) {
32 32
             // TODO: getTranslationsArray probably makes DB calls every loop. Find a way to profile & optimize.
33
-            $criteriaTranslated[] = array_merge($criterion->toArray(), $criterion->getTranslationsArray());
33
+            $criteriaTranslated[] = array_merge ($criterion->toArray (), $criterion->getTranslationsArray ());
34 34
         }
35
-        $criteriaIds = $criteria->pluck('id');
36
-        $assessments = Assessment::whereIn('criterion_id', $criteriaIds)->get();
35
+        $criteriaIds = $criteria->pluck ('id');
36
+        $assessments = Assessment::whereIn ('criterion_id', $criteriaIds)->get ();
37 37
         // Check for newly created assessment plan, and initialize any empty criteria to have the
38 38
         // "Narrative Review" option set.
39
-        $assessmentCriteriaIds = $assessments->pluck('criterion_id');
40
-        $emptyAssessments = array_diff($criteriaIds->toArray(), $assessmentCriteriaIds->toArray());
39
+        $assessmentCriteriaIds = $assessments->pluck ('criterion_id');
40
+        $emptyAssessments = array_diff ($criteriaIds->toArray (), $assessmentCriteriaIds->toArray ());
41 41
         if (!empty($emptyAssessments)) {
42
-            $narrativeReview = AssessmentType::where('key', 'narrative_assessment')->first();
42
+            $narrativeReview = AssessmentType::where ('key', 'narrative_assessment')->first ();
43 43
             foreach ($emptyAssessments as $criterionId) {
44
-                Assessment::create([
44
+                Assessment::create ([
45 45
                     'criterion_id' => $criterionId,
46 46
                     'assessment_type_id' => $narrativeReview->id
47 47
                 ]);
48 48
             }
49
-            $assessments = Assessment::whereIn('criterion_id', $criteriaIds)->get();
49
+            $assessments = Assessment::whereIn ('criterion_id', $criteriaIds)->get ();
50 50
         }
51
-        $questions = RatingGuideQuestion::where('job_poster_id', $jobPoster->id)->get();
52
-        $answers = RatingGuideAnswer::whereIn('rating_guide_question_id', $questions->pluck('id'))->get();
51
+        $questions = RatingGuideQuestion::where ('job_poster_id', $jobPoster->id)->get ();
52
+        $answers = RatingGuideAnswer::whereIn ('rating_guide_question_id', $questions->pluck ('id'))->get ();
53 53
         return [
54 54
             'criteria' => $criteriaTranslated,
55
-            'assessments' => $assessments->toArray(),
56
-            'rating_guide_questions' => $questions->toArray(),
57
-            'rating_guide_answers' => $answers->toArray()
55
+            'assessments' => $assessments->toArray (),
56
+            'rating_guide_questions' => $questions->toArray (),
57
+            'rating_guide_answers' => $answers->toArray ()
58 58
         ];
59 59
     }
60 60
 }
Please login to merge, or discard this patch.