Completed
Push — master ( 22ac2d...0f92de )
by Song
03:31
created
src/Grid.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -335,7 +335,7 @@  discard block
 block discarded – undo
335 335
         $column = new Column($column, $label);
336 336
         $column->setGrid($this);
337 337
 
338
-        return tap($column, function ($value) {
338
+        return tap($column, function($value) {
339 339
             $this->columns->push($value);
340 340
         });
341 341
     }
@@ -352,7 +352,7 @@  discard block
 block discarded – undo
352 352
         $column = new Column($column, $label);
353 353
         $column->setGrid($this);
354 354
 
355
-        return tap($column, function ($value) {
355
+        return tap($column, function($value) {
356 356
             $this->columns->prepend($value);
357 357
         });
358 358
     }
@@ -471,7 +471,7 @@  discard block
 block discarded – undo
471 471
      */
472 472
     public function disableRowSelector()
473 473
     {
474
-        $this->tools(function ($tools) {
474
+        $this->tools(function($tools) {
475 475
             /* @var Grid\Tools $tools */
476 476
             $tools->disableBatchActions();
477 477
         });
@@ -514,7 +514,7 @@  discard block
 block discarded – undo
514 514
 
515 515
         Column::setOriginalGridModels($collection);
516 516
 
517
-        $this->columns->map(function (Column $column) use (&$data) {
517
+        $this->columns->map(function(Column $column) use (&$data) {
518 518
             $data = $column->fill($data);
519 519
 
520 520
             $this->columnNames[] = $column->getName();
@@ -610,7 +610,7 @@  discard block
 block discarded – undo
610 610
      */
611 611
     protected function buildRows(array $data)
612 612
     {
613
-        $this->rows = collect($data)->map(function ($model, $number) {
613
+        $this->rows = collect($data)->map(function($model, $number) {
614 614
             return new Row($number, $model);
615 615
         });
616 616
 
Please login to merge, or discard this patch.
src/Grid/Column.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -309,13 +309,13 @@  discard block
 block discarded – undo
309 309
      * @param array $arguments
310 310
      * @return Column
311 311
      */
312
-    public function displayUsing($abstract, $arguments =[])
312
+    public function displayUsing($abstract, $arguments = [])
313 313
     {
314 314
         $grid = $this->grid;
315 315
 
316 316
         $column = $this;
317 317
 
318
-        return $this->display(function ($value) use ($grid, $column, $abstract, $arguments) {
318
+        return $this->display(function($value) use ($grid, $column, $abstract, $arguments) {
319 319
             /** @var AbstractDisplayer $displayer */
320 320
             $displayer = new $abstract($value, $grid, $column, $this);
321 321
 
@@ -333,7 +333,7 @@  discard block
 block discarded – undo
333 333
      */
334 334
     public function using(array $values, $default = null)
335 335
     {
336
-        return $this->display(function ($value) use ($values, $default) {
336
+        return $this->display(function($value) use ($values, $default) {
337 337
             if (is_null($value)) {
338 338
                 return $default;
339 339
             }
@@ -351,7 +351,7 @@  discard block
 block discarded – undo
351 351
      */
352 352
     public function view($view)
353 353
     {
354
-        return $this->display(function ($value) use ($view) {
354
+        return $this->display(function($value) use ($view) {
355 355
             $model = $this;
356 356
 
357 357
             return view($view, compact('model', 'value'))->render();
@@ -474,7 +474,7 @@  discard block
 block discarded – undo
474 474
         $grid = $this->grid;
475 475
         $column = $this;
476 476
 
477
-        $this->display(function ($value) use ($grid, $column, $class) {
477
+        $this->display(function($value) use ($grid, $column, $class) {
478 478
             /** @var AbstractDisplayer $definition */
479 479
             $definition = new $class($value, $grid, $column, $this);
480 480
 
@@ -492,7 +492,7 @@  discard block
 block discarded – undo
492 492
     protected function htmlEntityEncode($item)
493 493
     {
494 494
         if (is_array($item)) {
495
-            array_walk_recursive($item, function (&$value) {
495
+            array_walk_recursive($item, function(&$value) {
496 496
                 $value = htmlentities($value);
497 497
             });
498 498
         } else {
@@ -572,7 +572,7 @@  discard block
 block discarded – undo
572 572
      */
573 573
     protected function callSupportDisplayer($abstract, $arguments)
574 574
     {
575
-        return $this->display(function ($value) use ($abstract, $arguments) {
575
+        return $this->display(function($value) use ($abstract, $arguments) {
576 576
             if (is_array($value) || $value instanceof Arrayable) {
577 577
                 return call_user_func_array([collect($value), $abstract], $arguments);
578 578
             }
@@ -596,7 +596,7 @@  discard block
 block discarded – undo
596 596
     protected function callBuiltinDisplayer($abstract, $arguments)
597 597
     {
598 598
         if ($abstract instanceof Closure) {
599
-            return $this->display(function ($value) use ($abstract, $arguments) {
599
+            return $this->display(function($value) use ($abstract, $arguments) {
600 600
                 return $abstract->call($this, ...array_merge([$value], $arguments));
601 601
             });
602 602
         }
@@ -605,7 +605,7 @@  discard block
 block discarded – undo
605 605
             $grid = $this->grid;
606 606
             $column = $this;
607 607
 
608
-            return $this->display(function ($value) use ($abstract, $grid, $column, $arguments) {
608
+            return $this->display(function($value) use ($abstract, $grid, $column, $arguments) {
609 609
                 /** @var AbstractDisplayer $displayer */
610 610
                 $displayer = new $abstract($value, $grid, $column, $this);
611 611
 
Please login to merge, or discard this patch.