Passed
Pull Request — master (#273)
by
unknown
07:48
created
app/Models/Fee.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -73,10 +73,10 @@
 block discarded – undo
73 73
     {
74 74
         if (config('app.currency_position') === 'before')
75 75
         {
76
-            return config('app.currency_symbol') . " ". $this->price;
76
+            return config('app.currency_symbol')." ".$this->price;
77 77
         }
78 78
 
79
-        return $this->price . " " . config('app.currency_symbol');
79
+        return $this->price." ".config('app.currency_symbol');
80 80
     }
81 81
 
82 82
     public function getTypeAttribute()
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/ScheduledPaymentCrudController.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
     public function setup()
31 31
     {
32 32
         CRUD::setModel(\App\Models\ScheduledPayment::class);
33
-        CRUD::setRoute(config('backpack.base.route_prefix') . '/scheduled-payment');
33
+        CRUD::setRoute(config('backpack.base.route_prefix').'/scheduled-payment');
34 34
         CRUD::setEntityNameStrings(__('scheduled payment'), __('scheduled payments'));
35 35
         CRUD::enableExportButtons();
36 36
     }
@@ -49,9 +49,9 @@  discard block
 block discarded – undo
49 49
             'attribute' => 'lastname',
50 50
             'label' => __('Last Name'),
51 51
             'type' => 'relationship',
52
-            'searchLogic' => function ($query, $column, $searchTerm) {
53
-                $query->orWhereHas('enrollment', function ($q) use ($searchTerm) {
54
-                    $q->whereHas('user', function ($q) use ($searchTerm) {
52
+            'searchLogic' => function($query, $column, $searchTerm) {
53
+                $query->orWhereHas('enrollment', function($q) use ($searchTerm) {
54
+                    $q->whereHas('user', function($q) use ($searchTerm) {
55 55
                         $q->where('lastname', 'like', '%'.$searchTerm.'%');
56 56
                     });
57 57
                 });
@@ -64,9 +64,9 @@  discard block
 block discarded – undo
64 64
             'attribute' => 'firstname',
65 65
             'label' => __('First Name'),
66 66
             'type' => 'relationship',
67
-            'searchLogic' => function ($query, $column, $searchTerm) {
68
-                $query->orWhereHas('enrollment', function ($q) use ($searchTerm) {
69
-                    $q->whereHas('user', function ($q) use ($searchTerm) {
67
+            'searchLogic' => function($query, $column, $searchTerm) {
68
+                $query->orWhereHas('enrollment', function($q) use ($searchTerm) {
69
+                    $q->whereHas('user', function($q) use ($searchTerm) {
70 70
                         $q->where('firstname', 'like', '%'.$searchTerm.'%');
71 71
                     });
72 72
                 });
@@ -80,9 +80,9 @@  discard block
 block discarded – undo
80 80
             'attribute' => 'email',
81 81
             'label' => __('Email'),
82 82
             'type' => 'relationship',
83
-            'searchLogic' => function ($query, $column, $searchTerm) {
84
-                $query->orWhereHas('enrollment', function ($q) use ($searchTerm) {
85
-                    $q->whereHas('user', function ($q) use ($searchTerm) {
83
+            'searchLogic' => function($query, $column, $searchTerm) {
84
+                $query->orWhereHas('enrollment', function($q) use ($searchTerm) {
85
+                    $q->whereHas('user', function($q) use ($searchTerm) {
86 86
                         $q->where('email', 'like', '%'.$searchTerm.'%');
87 87
                     });
88 88
                 });
@@ -112,13 +112,13 @@  discard block
 block discarded – undo
112 112
             'name' => 'status_id',
113 113
             'type' => 'select2',
114 114
             'label'=> __('Status'),
115
-        ], function () {
115
+        ], function() {
116 116
             return [
117 117
                 1 => __('Pending'),
118 118
                 2 => __('Paid'),
119 119
             ];
120 120
         },
121
-            function ($value) { // if the filter is active
121
+            function($value) { // if the filter is active
122 122
                 CRUD::addClause('status', $value);
123 123
             });
124 124
     }
Please login to merge, or discard this patch.
app/Models/ScheduledPayment.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 
63 63
     public function scopeStatus(Builder $query, $status)
64 64
     {
65
-        return match ($status) {
65
+        return match($status) {
66 66
             "2" => $query->where('status', 2)->orWhereHas('invoices'),
67 67
             "1" => $query->where('status', 1)->orWhereDoesntHave('invoices'),
68 68
             default => $query,
@@ -111,10 +111,10 @@  discard block
 block discarded – undo
111 111
     {
112 112
         if (config('app.currency_position') === 'before')
113 113
         {
114
-            return config('app.currency_symbol') . " ". $this->value;
114
+            return config('app.currency_symbol')." ".$this->value;
115 115
         }
116 116
 
117
-        return $this->value . " " . config('app.currency_symbol');
117
+        return $this->value." ".config('app.currency_symbol');
118 118
     }
119 119
 
120 120
     function getDateForHumansAttribute()
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 
141 141
     public function identifiableAttribute()
142 142
     {
143
-        return $this->date . " (" . $this->value_with_currency . ")";
143
+        return $this->date." (".$this->value_with_currency.")";
144 144
     }
145 145
 
146 146
     public function getStatusTypeNameAttribute()
Please login to merge, or discard this patch.
app/Http/Controllers/CourseSkillEvaluationController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@
 block discarded – undo
69 69
 
70 70
         $course = Course::with('evaluationType')->find($enrollment->course_id);
71 71
         
72
-        $skills = $course->skills->map(function ($skill, $key) use ($student_skills) {
72
+        $skills = $course->skills->map(function($skill, $key) use ($student_skills) {
73 73
             $skill['status'] = $student_skills->where('skill_id', $skill->id)->first()->skill_scale_id ?? null;
74 74
             return $skill;
75 75
         })->groupBy('skill_type_id');
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/Operations/ShowStudentPhotoRosterOperation.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
         $this->crud->allowAccess(['showstudentphotoroster']);
33 33
         $this->crud->setOperationSetting('setFromDb', true);
34 34
 
35
-        $this->crud->operation('showstudentphotoroster', function () {
35
+        $this->crud->operation('showstudentphotoroster', function() {
36 36
             $this->crud->loadDefaultOperationSettingsFromConfig();
37 37
         });
38 38
 
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/SkillCrudController.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
     protected function setupListOperation()
34 34
     {
35 35
         CRUD::setColumns([
36
-            [ // skill type
36
+            [// skill type
37 37
                 'label'     => 'Type', // Table column heading
38 38
                 'type'      => 'select',
39 39
                 'name'      => 'skill_type', // the method that defines the relationship in your Model
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
                 'type' => 'text',
47 47
                 'name' => 'name',
48 48
             ],
49
-            [ // skill level
49
+            [// skill level
50 50
                 'label'     => 'Level', // Table column heading
51 51
                 'type'      => 'select',
52 52
                 'name'      => 'level', // the method that defines the relationship in your Model
@@ -58,23 +58,23 @@  discard block
 block discarded – undo
58 58
 
59 59
         CRUD::enableExportButtons();
60 60
 
61
-        CRUD::addFilter([ // select2 filter
61
+        CRUD::addFilter([// select2 filter
62 62
             'name' => 'level_id',
63 63
             'type' => 'select2',
64 64
             'label'=> 'Level',
65
-        ], function () {
65
+        ], function() {
66 66
             return Level::all()->pluck('name', 'id')->toArray();
67
-        }, function ($value) { // if the filter is active
67
+        }, function($value) { // if the filter is active
68 68
             CRUD::addClause('where', 'level_id', $value);
69 69
         });
70 70
 
71
-        CRUD::addFilter([ // select2 filter
71
+        CRUD::addFilter([// select2 filter
72 72
             'name' => 'skill_type_id',
73 73
             'type' => 'select2',
74 74
             'label'=> 'Type',
75
-        ], function () {
75
+        ], function() {
76 76
             return SkillType::all()->pluck('name', 'id')->toArray();
77
-        }, function ($value) { // if the filter is active
77
+        }, function($value) { // if the filter is active
78 78
             CRUD::addClause('where', 'skill_type_id', $value);
79 79
         });
80 80
     }
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
     {
84 84
         CRUD::setValidation(StoreRequest::class);
85 85
         CRUD::addFields([
86
-            [ // skill type
86
+            [// skill type
87 87
                 'label'     => 'Type', // Table column heading
88 88
                 'type' => 'select',
89 89
                 'name' => 'skill_type_id', // the db column for the foreign key
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
                 'type' => 'text',
97 97
                 'name' => 'name',
98 98
             ],
99
-            [ // skill level
99
+            [// skill level
100 100
                 'label'     => 'Level', // Table column heading
101 101
                 'type' => 'select',
102 102
                 'name' => 'level_id', // the db column for the foreign key
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
                 'type' => "relationship",
110 110
                 'name' => 'skill_type', // the method on your model that defines the relationship
111 111
                 'ajax' => true,
112
-                'inline_create' => [ // specify the entity in singular
112
+                'inline_create' => [// specify the entity in singular
113 113
                     'entity' => 'skilltype', // the entity in singular
114 114
                     // OPTIONALS
115 115
                     'force_select' => true, // should the inline-created entry be immediately selected?
Please login to merge, or discard this patch.
app/Http/Controllers/Admin/EvaluationTypeCrudController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -15,8 +15,8 @@  discard block
 block discarded – undo
15 15
 class EvaluationTypeCrudController extends CrudController
16 16
 {
17 17
     use ListOperation;
18
-    use CreateOperation {store as traitStore;}
19
-    use UpdateOperation {update as traitUpdate;}
18
+    use CreateOperation {store as traitStore; }
19
+    use UpdateOperation {update as traitUpdate; }
20 20
     use DeleteOperation;
21 21
 
22 22
     public function setup()
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
     {
36 36
         CRUD::addField(['name' => 'name', 'label' => 'Name', 'type' => 'text']);
37 37
 
38
-        CRUD::addField([    // Select2Multiple = n-n relationship (with pivot table)
38
+        CRUD::addField([// Select2Multiple = n-n relationship (with pivot table)
39 39
             'label'     => __('Grade Types'),
40 40
             'type'      => 'select2_multiple',
41 41
             'name'      => 'gradeTypes', // the method that defines the relationship in your Model
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
             'select_all' => true, // show Select All and Clear buttons?
49 49
         ]);
50 50
 
51
-        CRUD::addField([    // Select2Multiple = n-n relationship (with pivot table)
51
+        CRUD::addField([// Select2Multiple = n-n relationship (with pivot table)
52 52
             'label'     => __('Skills'),
53 53
             'type'      => 'select2_multiple',
54 54
             'name'      => 'skills', // the method that defines the relationship in your Model
Please login to merge, or discard this patch.
app/Events/LeadStatusUpdatedEvent.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -18,10 +18,9 @@
 block discarded – undo
18 18
     public $lastname;
19 19
     public $listId;
20 20
 
21
-    public function __construct(Student|Contact $user, $listId = null)
21
+    public function __construct(Student | Contact $user, $listId = null)
22 22
     {
23
-        $listId = $listId ? $listId :
24
-        $this->email = $user->email;
23
+        $listId = $listId ? $listId : $this->email = $user->email;
25 24
         $this->name = $user->firstname;
26 25
         $this->lastname = $user->lastname;
27 26
         $this->listId = $listId;
Please login to merge, or discard this patch.