Passed
Push — master ( 5d61dd...39b295 )
by Iman
07:19 queued 03:28
created
src/helpers/DbInspector.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
      */
17 17
     public static function findPK($table)
18 18
     {
19
-        if (! $table) {
19
+        if (!$table) {
20 20
             return 'id';
21 21
         }
22 22
 
@@ -25,13 +25,13 @@  discard block
 block discarded – undo
25 25
         }
26 26
         $table = CRUDBooster::parseSqlTable($table);
27 27
 
28
-        if (! $table['table']) {
28
+        if (!$table['table']) {
29 29
             throw new \Exception("parseSqlTable can't determine the table");
30 30
         }
31 31
 
32 32
         $primaryKey = self::findPKname($table);
33 33
 
34
-        if (! $primaryKey) {
34
+        if (!$primaryKey) {
35 35
             return 'id';
36 36
         }
37 37
         CbCache::put('table_'.$table, 'primaryKey', $primaryKey);
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
         }
97 97
 
98 98
         $table = self::getTableForeignKey($fieldName);
99
-        if (! $table) {
99
+        if (!$table) {
100 100
             return false;
101 101
         }
102 102
 
Please login to merge, or discard this patch.
src/Modules/ApiGeneratorModule/AdminApiGeneratorController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
 
78 78
             if (strtolower($api->method_type) == 'get' && $httpbuilder) {
79 79
                 $httpbuilder = "?".http_build_query($httpbuilder);
80
-            }else{
80
+            } else {
81 81
                 $httpbuilder = '';
82 82
             }
83 83
 
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
             $type_field = \Schema::getColumnType($table, $ro);
201 201
             $new_result[] = ['name' => $ro, 'type' => $this->getFieldType($ro, $type_field)];
202 202
 
203
-            if (!in_array($type, ['list', 'detail']) || !starts_with($ro, 'id_') ) {
203
+            if (!in_array($type, ['list', 'detail']) || !starts_with($ro, 'id_')) {
204 204
                 continue;
205 205
             }
206 206
             $table2 = substr($ro, 3);
@@ -271,7 +271,7 @@  discard block
 block discarded – undo
271 271
     {
272 272
         $json = [];
273 273
         for ($i = 0, $_count = count($params_name); $i <= $_count; $i++) {
274
-            if (! $params_name[$i]) {
274
+            if (!$params_name[$i]) {
275 275
                 continue;
276 276
             }
277 277
             $json[] = [
@@ -297,7 +297,7 @@  discard block
 block discarded – undo
297 297
     {
298 298
         $json = [];
299 299
         for ($i = 0, $_count = count($responses_name); $i <= $_count; $i++) {
300
-            if (! $responses_name[$i]) {
300
+            if (!$responses_name[$i]) {
301 301
                 continue;
302 302
             }
303 303
             $json[] = [
Please login to merge, or discard this patch.
src/Modules/ModuleGenerator/Step3Handler.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
 {
10 10
     public function showForm($id)
11 11
     {
12
-        $row = ModulesRepo::find($id);;
12
+        $row = ModulesRepo::find($id); ;
13 13
 
14 14
         $columns = \Schema::getColumnListing($row->table_name);
15 15
 
Please login to merge, or discard this patch.
src/Modules/ModuleGenerator/ControllerGenerator/FormConfigGenerator.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
 
89 89
             $props = array_get($map, FieldDetector::detect($colName), null);
90 90
             unset($map);
91
-            if($props !== null){
91
+            if ($props !== null) {
92 92
                 $input = array_merge($input, $props);
93 93
             }
94 94
 
@@ -129,8 +129,8 @@  discard block
 block discarded – undo
129 129
         $arr = array_get([
130 130
             'string' => $default,
131 131
             'text' => ['textarea', "string|min:5", []],
132
-            'date' => ['date', "date", ['php_format' => 'M, d Y', 'datepicker_format' => 'M, dd YYYY',]],
133
-            'datetime' => ['datetime', "date_format:Y-m-d H:i:s", ['php_format' => 'M, d Y H:i',]],
132
+            'date' => ['date', "date", ['php_format' => 'M, d Y', 'datepicker_format' => 'M, dd YYYY', ]],
133
+            'datetime' => ['datetime', "date_format:Y-m-d H:i:s", ['php_format' => 'M, d Y H:i', ]],
134 134
             'time' => ['time', 'date_format:H:i:s', []],
135 135
             'double' => ['money', "integer|min:0", []],
136 136
             'int' => ['number', 'integer|min:0', []],
@@ -150,7 +150,7 @@  discard block
 block discarded – undo
150 150
     private static function handleForeignKey($field)
151 151
     {
152 152
         $jointable = str_replace(['id_', '_id'], '', $field);
153
-        if (! Schema::hasTable($jointable)) {
153
+        if (!Schema::hasTable($jointable)) {
154 154
             return ['', ''];
155 155
         }
156 156
         $options = [
Please login to merge, or discard this patch.