Completed
Push — master ( 3be3c4...3816c0 )
by Song
33s queued 11s
created
src/Controllers/UserController.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -35,14 +35,14 @@  discard block
 block discarded – undo
35 35
         $grid->column('created_at', trans('admin.created_at'));
36 36
         $grid->column('updated_at', trans('admin.updated_at'));
37 37
 
38
-        $grid->actions(function (Grid\Displayers\Actions $actions) {
38
+        $grid->actions(function(Grid\Displayers\Actions $actions) {
39 39
             if ($actions->getKey() == 1) {
40 40
                 $actions->disableDelete();
41 41
             }
42 42
         });
43 43
 
44
-        $grid->tools(function (Grid\Tools $tools) {
45
-            $tools->batch(function (Grid\Tools\BatchActions $actions) {
44
+        $grid->tools(function(Grid\Tools $tools) {
45
+            $tools->batch(function(Grid\Tools\BatchActions $actions) {
46 46
                 $actions->disableDelete();
47 47
             });
48 48
         });
@@ -66,10 +66,10 @@  discard block
 block discarded – undo
66 66
         $show->field('id', 'ID');
67 67
         $show->field('username', trans('admin.username'));
68 68
         $show->field('name', trans('admin.name'));
69
-        $show->field('roles', trans('admin.roles'))->as(function ($roles) {
69
+        $show->field('roles', trans('admin.roles'))->as(function($roles) {
70 70
             return $roles->pluck('name');
71 71
         })->label();
72
-        $show->field('permissions', trans('admin.permissions'))->as(function ($permission) {
72
+        $show->field('permissions', trans('admin.permissions'))->as(function($permission) {
73 73
             return $permission->pluck('name');
74 74
         })->label();
75 75
         $show->field('created_at', trans('admin.created_at'));
@@ -103,7 +103,7 @@  discard block
 block discarded – undo
103 103
         $form->image('avatar', trans('admin.avatar'));
104 104
         $form->password('password', trans('admin.password'))->rules('required|confirmed');
105 105
         $form->password('password_confirmation', trans('admin.password_confirmation'))->rules('required')
106
-            ->default(function ($form) {
106
+            ->default(function($form) {
107 107
                 return $form->model()->password;
108 108
             });
109 109
 
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
         $form->display('created_at', trans('admin.created_at'));
116 116
         $form->display('updated_at', trans('admin.updated_at'));
117 117
 
118
-        $form->saving(function (Form $form) {
118
+        $form->saving(function(Form $form) {
119 119
             if ($form->password && $form->model()->password != $form->password) {
120 120
                 $form->password = Hash::make($form->password);
121 121
             }
Please login to merge, or discard this patch.
src/Controllers/AuthController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
     {
97 97
         $form = $this->settingForm();
98 98
         $form->tools(
99
-            function (Form\Tools $tools) {
99
+            function(Form\Tools $tools) {
100 100
                 $tools->disableList();
101 101
                 $tools->disableDelete();
102 102
                 $tools->disableView();
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
         $form->image('avatar', trans('admin.avatar'));
135 135
         $form->password('password', trans('admin.password'))->rules('confirmed|required');
136 136
         $form->password('password_confirmation', trans('admin.password_confirmation'))->rules('required')
137
-            ->default(function ($form) {
137
+            ->default(function($form) {
138 138
                 return $form->model()->password;
139 139
             });
140 140
 
@@ -142,13 +142,13 @@  discard block
 block discarded – undo
142 142
 
143 143
         $form->ignore(['password_confirmation']);
144 144
 
145
-        $form->saving(function (Form $form) {
145
+        $form->saving(function(Form $form) {
146 146
             if ($form->password && $form->model()->password != $form->password) {
147 147
                 $form->password = Hash::make($form->password);
148 148
             }
149 149
         });
150 150
 
151
-        $form->saved(function () {
151
+        $form->saved(function() {
152 152
             admin_toastr(trans('admin.update_succeeded'));
153 153
 
154 154
             return redirect(admin_url('auth/setting'));
Please login to merge, or discard this patch.