Passed
Pull Request — dev5 (#82)
by
unknown
08:35
created
database/migrations/2019_11_30_195012_create_user_role_types_table.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -35,8 +35,7 @@
 block discarded – undo
35 35
         //  Update the users table to include the 'user_role' column
36 36
         if(!Schema::hasColumn('users', 'role_id'))
37 37
         {
38
-            Schema::table('users', function(Blueprint $table)
39
-            {
38
+            Schema::table('users', function(Blueprint $table) {
40 39
                 $table->integer('role_id')->unsigned()->after('user_id')->default(4);
41 40
                 $table->foreign('role_id')->references('role_id')->on('user_role_types')->onUpdate('cascade');
42 41
             });
Please login to merge, or discard this patch.
config/filesystems.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -33,12 +33,12 @@
 block discarded – undo
33 33
     ],
34 34
     'paths' => [
35 35
         'default'    => env('DFLT_FOLDER', DIRECTORY_SEPARATOR.'default'),
36
-        'systems'    => env('SYS_FOLDER',  DIRECTORY_SEPARATOR.'systems'),
36
+        'systems'    => env('SYS_FOLDER', DIRECTORY_SEPARATOR.'systems'),
37 37
         'customers'  => env('CUST_FOLDER', DIRECTORY_SEPARATOR.'customers'),
38 38
         'users'      => env('USER_FOLDER', DIRECTORY_SEPARATOR.'users'),
39
-        'tips'       => env('TIP_FOLDER',  DIRECTORY_SEPARATOR.'tips'),
39
+        'tips'       => env('TIP_FOLDER', DIRECTORY_SEPARATOR.'tips'),
40 40
         'links'      => env('LINK_FOLDER', DIRECTORY_SEPARATOR.'links'),
41 41
         'company'    => env('COMP_FOLDER', DIRECTORY_SEPARATOR.'company'),
42
-        'max_size'   => env('MAX_UPLOAD',  1600),    //  Megabytes = Default = 1600 - 2GB
42
+        'max_size'   => env('MAX_UPLOAD', 1600), //  Megabytes = Default = 1600 - 2GB
43 43
     ],
44 44
 ];
Please login to merge, or discard this patch.
app/Providers/FormGroupServiceProvider.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -25,14 +25,14 @@
 block discarded – undo
25 25
     public function boot()
26 26
     {
27 27
         //  Service provider to customize form inputs
28
-        Form::component('bsText',     'components.form.text',     ['name', 'label', 'value' => null, 'attributes' => []]);
28
+        Form::component('bsText', 'components.form.text', ['name', 'label', 'value' => null, 'attributes' => []]);
29 29
         Form::component('bsPassword', 'components.form.password', ['name', 'label', 'value' => null, 'attributes' => []]);
30
-        Form::component('bsNumber',   'components.form.number',   ['name', 'label', 'value' => null, 'attributes' => []]);
31
-        Form::component('bsEmail',    'components.form.email',    ['name', 'label', 'value' => null, 'attributes' => []]);
32
-        Form::component('bsDate',     'components.form.date',     ['name', 'label', 'value' => null, 'attributes' => []]);
30
+        Form::component('bsNumber', 'components.form.number', ['name', 'label', 'value' => null, 'attributes' => []]);
31
+        Form::component('bsEmail', 'components.form.email', ['name', 'label', 'value' => null, 'attributes' => []]);
32
+        Form::component('bsDate', 'components.form.date', ['name', 'label', 'value' => null, 'attributes' => []]);
33 33
         Form::component('bsTextarea', 'components.form.textarea', ['name', 'label', 'value' => null, 'attributes' => []]);
34 34
         Form::component('bsCheckbox', 'components.form.checkbox', ['name', 'label', 'value' => 'on', 'checked' => false, 'attributes' => []]);
35
-        Form::component('bsSelect',   'components.form.select',   ['name', 'label', 'list', 'selected' => null, 'attributes' => []]);
35
+        Form::component('bsSelect', 'components.form.select', ['name', 'label', 'list', 'selected' => null, 'attributes' => []]);
36 36
         //  Custom Submit button
37 37
         Form::component('bsSubmit', 'components.form.submit', ['name']);
38 38
         //  List of all states in a dropdown box
Please login to merge, or discard this patch.
app/Http/Controllers/Customers/CustomerSystemsController.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
     //  Get the possible system types that can be assigned to the customer
25 25
     public function index()
26 26
     {
27
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
27
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
28 28
         $sysList = new CategoriesCollection(SystemCategories::with('SystemTypes')->with('SystemTypes.SystemDataFields.SystemDataFieldTypes')->get());
29 29
 
30 30
         return $sysList;
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
     //  Store a new system for the customer
34 34
     public function store(Request $request)
35 35
     {
36
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name.'. Submitted Data - ', $request->toArray());
36
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name.'. Submitted Data - ', $request->toArray());
37 37
 
38 38
         $request->validate([
39 39
             'cust_id' => 'required',
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
     //  Get the list of systems attached to the customer
77 77
     public function show($id)
78 78
     {
79
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
79
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
80 80
 
81 81
         $sysList = CustomerSystems::where('cust_id', $id)
82 82
                     ->with('SystemTypes')
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
     // Update the customers system data
106 106
     public function update(Request $request, $id)
107 107
     {
108
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name.'. Submitted Data - ', $request->toArray());
108
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name.'. Submitted Data - ', $request->toArray());
109 109
 
110 110
         $request->validate([
111 111
             'cust_id'    => 'required',
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
 
125 125
         foreach($fields as $data)
126 126
         {
127
-            $fieldName = 'field_' . $data->field_id;
127
+            $fieldName = 'field_'.$data->field_id;
128 128
             if(isset($request->$fieldName))
129 129
             {
130 130
                 Log::debug($request->$fieldName);
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
     //  Delete a system attached to a customer
143 143
     public function destroy($id)
144 144
     {
145
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
145
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
146 146
 
147 147
         // return response('deleted '.$id);
148 148
         $system = CustomerSystems::find($id);
Please login to merge, or discard this patch.
database/factories/NotificationsFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@
 block discarded – undo
4 4
 
5 5
 use Faker\Generator as Faker;
6 6
 
7
-$factory->define(Illuminate\Notifications\DatabaseNotification::class, function (Faker $faker) {
7
+$factory->define(Illuminate\Notifications\DatabaseNotification::class, function(Faker $faker) {
8 8
     return [
9 9
         'id' => $faker->uuid,
10 10
     ];
Please login to merge, or discard this patch.
app/Policies/GatePolicy.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -37,13 +37,13 @@  discard block
 block discarded – undo
37 37
     //  Determine if a user can see the Administration Nav Link
38 38
     public function seeAdminLink(User $user)
39 39
     {
40
-        if ($this->isInstaller($user))
40
+        if($this->isInstaller($user))
41 41
         {
42 42
             return true;
43 43
         }
44 44
 
45 45
         $data = UserRolePermissions::with('UserRolePermissionTypes')
46
-            ->whereHas('UserRolePermissionTypes', function ($query) {
46
+            ->whereHas('UserRolePermissionTypes', function($query) {
47 47
                 $query->where('description', 'Manage Users')
48 48
                     ->orWhere('description', 'Manage User Roles')
49 49
                     ->orWhere('description', 'Manage Customers')
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
             ->get();
55 55
 
56 56
         $allow = $data->isEmpty() ? 'Denied' : 'Allowed';
57
-        Log::debug('User ' . $user->full_name . ' is trying to see admin link.  Result - ' . $allow);
57
+        Log::debug('User '.$user->full_name.' is trying to see admin link.  Result - '.$allow);
58 58
 
59 59
         return  $data->isEmpty() ? false : true;
60 60
     }
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
         }
70 70
 
71 71
         $data = UserRolePermissions::with('UserRolePermissionTypes')
72
-            ->whereHas('UserRolePermissionTypes', function ($query) use ($task) {
72
+            ->whereHas('UserRolePermissionTypes', function($query) use ($task) {
73 73
                 $query->where('description', $task);
74 74
             })
75 75
             ->where('role_id', $user->role_id)
@@ -77,10 +77,10 @@  discard block
 block discarded – undo
77 77
             ->get();
78 78
 
79 79
         $allow = $data->isEmpty() ? 'false' : 'true';
80
-        Log::debug('User '.$user->full_name.' is trying to access '.$task.'.  Result - ' . $allow);
81
-        if ($allow === 'Denied')
80
+        Log::debug('User '.$user->full_name.' is trying to access '.$task.'.  Result - '.$allow);
81
+        if($allow === 'Denied')
82 82
         {
83
-            Log::alert('User ' . $user->full_name . ' was denied from accessing '.$task.' link.');
83
+            Log::alert('User '.$user->full_name.' was denied from accessing '.$task.' link.');
84 84
         }
85 85
 
86 86
         return  $data->isEmpty() ? false : true;
Please login to merge, or discard this patch.
app/Console/Commands/updateRun.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,7 +22,8 @@  discard block
 block discarded – undo
22 22
         $this->line('');
23 23
         //  Select which update file to use
24 24
         $updateFile = $this->checkForUpdate();
25
-        if($updateFile) {
25
+        if($updateFile)
26
+        {
26 27
             //  Open up the file and verify it is at least the same version as the current setup
27 28
             $valid = $this->openUpdate($updateFile);
28 29
 
@@ -80,7 +81,8 @@  discard block
 block discarded – undo
80 81
             $this->line('');
81 82
 
82 83
             $anticipate = [];
83
-            foreach($updateList as $key => $up) {
84
+            foreach($updateList as $key => $up)
85
+            {
84 86
                 $opt = $key + 1;
85 87
                 $anticipate[$opt] = $up;
86 88
                 $this->line('['.$opt.'] '.$up);
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/InitializeUserController.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,7 +25,8 @@  discard block
 block discarded – undo
25 25
         //  Validate the hash token
26 26
         $user = UserInitialize::where('token', $hash)->get();
27 27
 
28
-        if($user->isEmpty()) {
28
+        if($user->isEmpty())
29
+        {
29 30
             Log::warning('Visitor at IP Address '.\Request::ip().' tried to access invalid initialize hash - '.$hash);
30 31
             return abort(404);
31 32
         }
@@ -43,7 +44,8 @@  discard block
 block discarded – undo
43 44
 
44 45
         //  Verify that the link matches the assigned email address
45 46
         $valid = UserInitialize::where('token', $hash)->first();
46
-        if(empty($valid)) {
47
+        if(empty($valid))
48
+        {
47 49
             Log::warning('Visitor at IP Address '.\Request::ip().' tried to submit an invalid User Initialization link - '.$hash);
48 50
             return abort(404);
49 51
         }
Please login to merge, or discard this patch.
app/Http/Controllers/DashboardController.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@  discard block
 block discarded – undo
30 30
         $totalLinks  = FileLinks::where('user_id', Auth::user()->user_id)->count();
31 31
 
32 32
         //  Debug Data
33
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
33
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
34 34
         Log::debug('Customer Favorites for '.Auth::user()->full_name.': ', $custFavs->toArray());
35
-        Log::debug('Tech Tip Favorites for ' . Auth::user()->full_name . ': ', $tipFavs->toArray());
35
+        Log::debug('Tech Tip Favorites for '.Auth::user()->full_name.': ', $tipFavs->toArray());
36 36
 
37 37
         return view('dashboard', [
38 38
             'custFavs'    => $custFavs,
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     //  About page
48 48
     public function about()
49 49
     {
50
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
50
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
51 51
 
52 52
         return view('about', [
53 53
             'branch' => 'latest'
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     public function getNotifications()
59 59
     {
60 60
         //  Debug Data
61
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
61
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
62 62
         Log::debug('Notifications for '.Auth::user()->full_name.':', Auth::user()->notifications->toArray());
63 63
 
64 64
         return Auth::user()->notifications;
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
     //  Mark a notification as read
68 68
     public function markNotification($id)
69 69
     {
70
-        Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name);
70
+        Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name);
71 71
 
72 72
         $notification = Auth::user()->notifications()->where('id', $id)->where('notifiable_id', Auth::user()->user_id)->first();
73 73
         if(!$notification)
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
         }
94 94
         else
95 95
         {
96
-            Log::error('User ' . Auth::user()->full_name . ' tried to delete an invalid notification as read.  Notification ID: ' . $id);
96
+            Log::error('User '.Auth::user()->full_name.' tried to delete an invalid notification as read.  Notification ID: '.$id);
97 97
             return abort(404);
98 98
         }
99 99
 
Please login to merge, or discard this patch.