Completed
Pull Request — master (#201)
by
unknown
02:13
created
src/Components/RecordsPerPage.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -83,7 +83,9 @@
 block discarded – undo
83 83
     public function prepare()
84 84
     {
85 85
         $value = $this->getValue();
86
-        if (!$value || !is_numeric($value)) return;
86
+        if (!$value || !is_numeric($value)) {
87
+            return;
88
+        }
87 89
         $this->grid->getConfig()->getDataProvider()->setPageSize($value);
88 90
     }
89 91
 }
Please login to merge, or discard this patch.
src/Components/RenderFunc.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,9 @@
 block discarded – undo
21 21
      */
22 22
     public function __construct($func = null)
23 23
     {
24
-        if ($func) $this->setFunc($func);
24
+        if ($func) {
25
+            $this->setFunc($func);
26
+        }
25 27
     }
26 28
 
27 29
     /**
Please login to merge, or discard this patch.
src/Components/TotalsRow.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,9 @@
 block discarded – undo
77 77
         Event::listen(
78 78
             DataProvider::EVENT_FETCH_ROW,
79 79
             function (DataRow $row, DataProvider $currentProvider) use ($provider) {
80
-                if ($currentProvider !== $provider) return;
80
+                if ($currentProvider !== $provider) {
81
+                    return;
82
+                }
81 83
                 $this->rows_processed++;
82 84
                 foreach ($this->fields as $field) {
83 85
                     $name = $field->getName();
Please login to merge, or discard this patch.
resources/views/default/components/filters/checkboxes.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,7 +1,9 @@
 block discarded – undo
1 1
 <?php
2 2
 /** @var Nayjest\Grids\Components\SelectFilter $component */
3 3
 $value = $component->getValue();
4
-if (!is_array($value)) $value = [];
4
+if (!is_array($value)) {
5
+    $value = [];
6
+}
5 7
 $id = uniqid() . mt_rand();
6 8
 ?>
7 9
 <div class="btn-group">
Please login to merge, or discard this patch.
src/Components/ExcelDownload.php 1 patch
Unused Use Statements   -8 removed lines patch added patch discarded remove patch
@@ -4,16 +4,8 @@
 block discarded – undo
4 4
 
5 5
 use Event;
6 6
 use Illuminate\Support\Facades\Storage;
7
-use Illuminate\Pagination\Paginator;
8
-use Illuminate\Foundation\Application;
9
-use Maatwebsite\Excel\Classes\LaravelExcelWorksheet;
10
-use Maatwebsite\Excel\Excel;
11
-use Maatwebsite\Excel\Writers\LaravelExcelWriter;
12 7
 use Nayjest\Grids\Components\Base\RenderableComponent;
13 8
 use Nayjest\Grids\Components\Base\RenderableRegistry;
14
-use Nayjest\Grids\DataProvider;
15
-use Nayjest\Grids\DataRow;
16
-use Nayjest\Grids\FieldConfig;
17 9
 use Nayjest\Grids\Grid;
18 10
 
19 11
 class ExcelDownload extends RenderableComponent
Please login to merge, or discard this patch.
src/Components/ExcelDispatchJobService.php 2 patches
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -4,13 +4,10 @@
 block discarded – undo
4 4
 
5 5
 use App\Components\Grid\ExtendedTableRow;
6 6
 use App\Components\Grid\GridsToComponents;
7
-use App\Http\Controllers\SupportersController;
8 7
 use App\Topic;
9 8
 use App\User;
10
-use Event;
11 9
 use Illuminate\Pagination\Paginator;
12 10
 use Illuminate\Foundation\Application;
13
-use Illuminate\Support\Facades\DB;
14 11
 use Maatwebsite\Excel\Classes\LaravelExcelWorksheet;
15 12
 use Maatwebsite\Excel\Excel;
16 13
 use Maatwebsite\Excel\Writers\LaravelExcelWriter;
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -145,8 +145,7 @@
 block discarded – undo
145 145
         if($sheetName == 'topicQuestionsGrid') {
146 146
             $topic = Topic::find($showId);
147 147
             $this->config = $className::getQuestionsGridConfig($topic);
148
-        }
149
-        else{
148
+        } else{
150 149
             $this->config = $className::getGridConfig($user);
151 150
         }
152 151
 
Please login to merge, or discard this patch.