@@ -20,7 +20,7 @@ |
||
20 | 20 | return redirect('/'); |
21 | 21 | } |
22 | 22 | |
23 | - if (! $request->user()->can($permission)) { |
|
23 | + if (!$request->user()->can($permission)) { |
|
24 | 24 | abort(403); |
25 | 25 | } |
26 | 26 |
@@ -20,11 +20,11 @@ |
||
20 | 20 | return redirect('/'); |
21 | 21 | } |
22 | 22 | |
23 | - if (! $request->user()->hasRole($role)) { |
|
23 | + if (!$request->user()->hasRole($role)) { |
|
24 | 24 | abort(403); |
25 | 25 | } |
26 | 26 | |
27 | - if (! $request->user()->can($permission)) { |
|
27 | + if (!$request->user()->can($permission)) { |
|
28 | 28 | abort(403); |
29 | 29 | } |
30 | 30 |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php include(__DIR__ . '/../_partials/header.php'); ?> |
|
1 | +<?php include(__DIR__.'/../_partials/header.php'); ?> |
|
2 | 2 | |
3 | 3 | <section class="column stack-l typography" id="typography"> |
4 | 4 | <h1>Typography</h1> |
@@ -62,4 +62,4 @@ discard block |
||
62 | 62 | |
63 | 63 | </section> |
64 | 64 | |
65 | -<?php include(__DIR__ . '/../_partials/footer.php'); ?> |
|
65 | +<?php include(__DIR__.'/../_partials/footer.php'); ?> |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php include(__DIR__ . '/../_partials/header.php'); ?> |
|
1 | +<?php include(__DIR__.'/../_partials/header.php'); ?> |
|
2 | 2 | |
3 | 3 | <section class="column stack-l color-scheme" id="colorscheme"> |
4 | 4 | <h1>Color Scheme</h1> |
@@ -205,4 +205,4 @@ discard block |
||
205 | 205 | </div> |
206 | 206 | </section> |
207 | 207 | |
208 | -<?php include(__DIR__ . '/../_partials/footer.php'); ?> |
|
209 | 208 | \ No newline at end of file |
209 | +<?php include(__DIR__.'/../_partials/footer.php'); ?> |
|
210 | 210 | \ No newline at end of file |
@@ -2,11 +2,11 @@ |
||
2 | 2 | |
3 | 3 | // Normally field is a single string value representing the name of the input. |
4 | 4 | // For multiple fields in the same formgroup we allow to add an array of fields as well. |
5 | - $fields = (array) $field; |
|
5 | + $fields = (array)$field; |
|
6 | 6 | |
7 | 7 | $hasErrors = false; |
8 | - foreach($fields as $field){ |
|
9 | - if($errors->has($field)) $hasErrors = true; |
|
8 | + foreach ($fields as $field) { |
|
9 | + if ($errors->has($field)) $hasErrors = true; |
|
10 | 10 | } |
11 | 11 | |
12 | 12 | ?> |
@@ -6,7 +6,9 @@ |
||
6 | 6 | |
7 | 7 | $hasErrors = false; |
8 | 8 | foreach($fields as $field){ |
9 | - if($errors->has($field)) $hasErrors = true; |
|
9 | + if($errors->has($field)) { |
|
10 | + $hasErrors = true; |
|
11 | + } |
|
10 | 12 | } |
11 | 13 | |
12 | 14 | ?> |
@@ -15,21 +15,21 @@ discard block |
||
15 | 15 | { |
16 | 16 | $tableNames = config('permission.table_names'); |
17 | 17 | |
18 | - Schema::create($tableNames['permissions'], function (Blueprint $table) { |
|
18 | + Schema::create($tableNames['permissions'], function(Blueprint $table) { |
|
19 | 19 | $table->increments('id'); |
20 | 20 | $table->string('name'); |
21 | 21 | $table->string('guard_name'); |
22 | 22 | $table->timestamps(); |
23 | 23 | }); |
24 | 24 | |
25 | - Schema::create($tableNames['roles'], function (Blueprint $table) { |
|
25 | + Schema::create($tableNames['roles'], function(Blueprint $table) { |
|
26 | 26 | $table->increments('id'); |
27 | 27 | $table->string('name'); |
28 | 28 | $table->string('guard_name'); |
29 | 29 | $table->timestamps(); |
30 | 30 | }); |
31 | 31 | |
32 | - Schema::create($tableNames['model_has_permissions'], function (Blueprint $table) use ($tableNames) { |
|
32 | + Schema::create($tableNames['model_has_permissions'], function(Blueprint $table) use ($tableNames) { |
|
33 | 33 | $table->unsignedInteger('permission_id'); |
34 | 34 | $table->morphs('model'); |
35 | 35 | |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | $table->primary(['permission_id', 'model_id', 'model_type']); |
42 | 42 | }); |
43 | 43 | |
44 | - Schema::create($tableNames['model_has_roles'], function (Blueprint $table) use ($tableNames) { |
|
44 | + Schema::create($tableNames['model_has_roles'], function(Blueprint $table) use ($tableNames) { |
|
45 | 45 | $table->unsignedInteger('role_id'); |
46 | 46 | $table->morphs('model'); |
47 | 47 | |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | $table->primary(['role_id', 'model_id', 'model_type']); |
54 | 54 | }); |
55 | 55 | |
56 | - Schema::create($tableNames['role_has_permissions'], function (Blueprint $table) use ($tableNames) { |
|
56 | + Schema::create($tableNames['role_has_permissions'], function(Blueprint $table) use ($tableNames) { |
|
57 | 57 | $table->unsignedInteger('permission_id'); |
58 | 58 | $table->unsignedInteger('role_id'); |
59 | 59 |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | } |
57 | 57 | return redirect()->route('chief.back.permissions.index') |
58 | 58 | ->with('flash_message', |
59 | - 'Permission'. $permission->name.' added!'); |
|
59 | + 'Permission'.$permission->name.' added!'); |
|
60 | 60 | } |
61 | 61 | /** |
62 | 62 | * Display the specified resource. |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | $permission->fill($input)->save(); |
99 | 99 | return redirect()->route('chief.back.permissions.index') |
100 | 100 | ->with('flash_message', |
101 | - 'Permission'. $permission->name.' updated!'); |
|
101 | + 'Permission'.$permission->name.' updated!'); |
|
102 | 102 | } |
103 | 103 | /** |
104 | 104 | * Remove the specified resource from storage. |
@@ -42,7 +42,7 @@ |
||
42 | 42 | $role->givePermissionTo($request->permission_names); |
43 | 43 | |
44 | 44 | return redirect()->route('chief.back.roles.index') |
45 | - ->with('messages.success', 'Rol '. $role->name.' is toegevoegd.'); |
|
45 | + ->with('messages.success', 'Rol '. $role->name.' is toegevoegd.'); |
|
46 | 46 | } |
47 | 47 | |
48 | 48 | public function edit($id) |
@@ -42,7 +42,7 @@ discard block |
||
42 | 42 | $role->givePermissionTo($request->permission_names); |
43 | 43 | |
44 | 44 | return redirect()->route('chief.back.roles.index') |
45 | - ->with('messages.success', 'Rol '. $role->name.' is toegevoegd.'); |
|
45 | + ->with('messages.success', 'Rol '.$role->name.' is toegevoegd.'); |
|
46 | 46 | } |
47 | 47 | |
48 | 48 | public function edit($id) |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | $role->syncPermissions($request->permission_names); |
72 | 72 | |
73 | 73 | return redirect()->route('chief.back.roles.index') |
74 | - ->with('messages.success', 'Rol '. $role->name.' is aangepast.'); |
|
74 | + ->with('messages.success', 'Rol '.$role->name.' is aangepast.'); |
|
75 | 75 | } |
76 | 76 | |
77 | 77 | public function destroy($id) |
@@ -82,6 +82,6 @@ discard block |
||
82 | 82 | $role->delete(); |
83 | 83 | |
84 | 84 | return redirect()->route('chief.back.roles.index') |
85 | - ->with('messages.success', 'Rol '. $role->name.' is verwijderd.'); |
|
85 | + ->with('messages.success', 'Rol '.$role->name.' is verwijderd.'); |
|
86 | 86 | } |
87 | 87 | } |
@@ -17,7 +17,7 @@ |
||
17 | 17 | app(InviteUser::class)->handle($user, auth()->guard('chief')->user()); |
18 | 18 | |
19 | 19 | return redirect()->route('chief.back.users.index') |
20 | - ->with('messages.success', $user->fullname. ' is opnieuw een uitnodiging verstuurd.'); |
|
20 | + ->with('messages.success', $user->fullname.' is opnieuw een uitnodiging verstuurd.'); |
|
21 | 21 | } |
22 | 22 | |
23 | 23 | } |