@@ -49,20 +49,20 @@ |
||
49 | 49 | return static::$view; |
50 | 50 | } |
51 | 51 | |
52 | - if (view()->exists('admin.widgets.'.static::safeTitle().'.widget')) { |
|
53 | - return 'admin.widgets.'.static::safeTitle().'.widget'; |
|
52 | + if (view()->exists('admin.widgets.' . static::safeTitle() . '.widget')) { |
|
53 | + return 'admin.widgets.' . static::safeTitle() . '.widget'; |
|
54 | 54 | } |
55 | 55 | |
56 | - if (view()->exists('admin.widgets.'.static::safeTitle())) { |
|
57 | - return 'admin.widgets.'.static::safeTitle(); |
|
56 | + if (view()->exists('admin.widgets.' . static::safeTitle())) { |
|
57 | + return 'admin.widgets.' . static::safeTitle(); |
|
58 | 58 | } |
59 | 59 | |
60 | - if (view()->exists('admin.'.static::safeTitle())) { |
|
61 | - return 'admin.'.static::safeTitle(); |
|
60 | + if (view()->exists('admin.' . static::safeTitle())) { |
|
61 | + return 'admin.' . static::safeTitle(); |
|
62 | 62 | } |
63 | 63 | |
64 | - if (view()->exists('flare::'.self::$view)) { |
|
65 | - return 'flare::'.self::$view; |
|
64 | + if (view()->exists('flare::' . self::$view)) { |
|
65 | + return 'flare::' . self::$view; |
|
66 | 66 | } |
67 | 67 | } |
68 | 68 |
@@ -29,11 +29,11 @@ discard block |
||
29 | 29 | // parameter represents the DataTables column identifier. In this case simple |
30 | 30 | // indexes |
31 | 31 | $columns = array( |
32 | - array( 'db' => 'id', 'dt' => 0 ), |
|
33 | - array( 'db' => 'firstname', 'dt' => 1 ), |
|
34 | - array( 'db' => 'surname', 'dt' => 2 ), |
|
35 | - array( 'db' => 'zip', 'dt' => 3 ), |
|
36 | - array( 'db' => 'country', 'dt' => 4 ) |
|
32 | + array('db' => 'id', 'dt' => 0), |
|
33 | + array('db' => 'firstname', 'dt' => 1), |
|
34 | + array('db' => 'surname', 'dt' => 2), |
|
35 | + array('db' => 'zip', 'dt' => 3), |
|
36 | + array('db' => 'country', 'dt' => 4) |
|
37 | 37 | ); |
38 | 38 | |
39 | 39 | // SQL server connection information |
@@ -50,9 +50,9 @@ discard block |
||
50 | 50 | * server-side, there is no need to edit below this line. |
51 | 51 | */ |
52 | 52 | |
53 | -require( '../../../../examples/server_side/scripts/ssp.class.php' ); |
|
53 | +require('../../../../examples/server_side/scripts/ssp.class.php'); |
|
54 | 54 | |
55 | 55 | echo json_encode( |
56 | - SSP::simple( $_GET, $sql_details, $table, $primaryKey, $columns ) |
|
56 | + SSP::simple($_GET, $sql_details, $table, $primaryKey, $columns) |
|
57 | 57 | ); |
58 | 58 |
@@ -40,16 +40,16 @@ |
||
40 | 40 | return $this->view; |
41 | 41 | } |
42 | 42 | |
43 | - if (view()->exists('admin.'.$this->urlPrefix().'.index')) { |
|
44 | - return 'admin.'.$this->urlPrefix().'.index'; |
|
43 | + if (view()->exists('admin.' . $this->urlPrefix() . '.index')) { |
|
44 | + return 'admin.' . $this->urlPrefix() . '.index'; |
|
45 | 45 | } |
46 | 46 | |
47 | - if (view()->exists('admin.'.$this->urlPrefix())) { |
|
48 | - return 'admin.'.$this->urlPrefix(); |
|
47 | + if (view()->exists('admin.' . $this->urlPrefix())) { |
|
48 | + return 'admin.' . $this->urlPrefix(); |
|
49 | 49 | } |
50 | 50 | |
51 | - if (view()->exists('flare::'.$this->view)) { |
|
52 | - return 'flare::'.$this->view; |
|
51 | + if (view()->exists('flare::' . $this->view)) { |
|
52 | + return 'flare::' . $this->view; |
|
53 | 53 | } |
54 | 54 | |
55 | 55 | return parent::getView(); |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | return $this->config[$key]; |
131 | 131 | } |
132 | 132 | |
133 | - return config('flare.'.$key); |
|
133 | + return config('flare.' . $key); |
|
134 | 134 | } |
135 | 135 | |
136 | 136 | /** |
@@ -233,7 +233,7 @@ discard block |
||
233 | 233 | */ |
234 | 234 | public function relativeAdminUrl($path = '') |
235 | 235 | { |
236 | - return rtrim($this->getRelativeAdminUrl().'/'.$path, '/'); |
|
236 | + return rtrim($this->getRelativeAdminUrl() . '/' . $path, '/'); |
|
237 | 237 | } |
238 | 238 | |
239 | 239 | /** |
@@ -271,7 +271,7 @@ discard block |
||
271 | 271 | */ |
272 | 272 | public function docsUrl($path = '') |
273 | 273 | { |
274 | - return url('#'.$path); |
|
274 | + return url('#' . $path); |
|
275 | 275 | } |
276 | 276 | |
277 | 277 | /** |
@@ -133,6 +133,6 @@ |
||
133 | 133 | */ |
134 | 134 | private function basePath($filepath = false) |
135 | 135 | { |
136 | - return __DIR__.'/../'.$filepath; |
|
136 | + return __DIR__ . '/../' . $filepath; |
|
137 | 137 | } |
138 | 138 | } |
@@ -170,8 +170,8 @@ |
||
170 | 170 | { |
171 | 171 | // Could swap this out for model -> getAttribute, then check if we have an attribute or a relation... getRelationValue() is helpful |
172 | 172 | if (method_exists($this->model, $key) && is_a(call_user_func_array([$this->model, $key], []), 'Illuminate\Database\Eloquent\Relations\Relation')) { |
173 | - foreach ($this->{$action.'Relations'} as $relationship => $method) { |
|
174 | - if (is_a(call_user_func_array([$this->model, $key], []), 'Illuminate\Database\Eloquent\Relations\\'.$relationship)) { |
|
173 | + foreach ($this->{$action . 'Relations'} as $relationship => $method) { |
|
174 | + if (is_a(call_user_func_array([$this->model, $key], []), 'Illuminate\Database\Eloquent\Relations\\' . $relationship)) { |
|
175 | 175 | $this->model->$key()->$method($value); |
176 | 176 | |
177 | 177 | return; |
@@ -93,9 +93,9 @@ |
||
93 | 93 | protected function adminController($route = null) |
94 | 94 | { |
95 | 95 | if ($route) { |
96 | - return $this->namespace.'\\'.$this->compatibilityVersion.'\AdminController@'.$route; |
|
96 | + return $this->namespace . '\\' . $this->compatibilityVersion . '\AdminController@' . $route; |
|
97 | 97 | } |
98 | 98 | |
99 | - return $this->namespace.'\\'.$this->compatibilityVersion.'\AdminController'; |
|
99 | + return $this->namespace . '\\' . $this->compatibilityVersion . '\AdminController'; |
|
100 | 100 | } |
101 | 101 | } |
@@ -152,7 +152,7 @@ discard block |
||
152 | 152 | */ |
153 | 153 | private function getOptions($name) |
154 | 154 | { |
155 | - $method = 'get'.Str::studly($name).'Options'; |
|
155 | + $method = 'get' . Str::studly($name) . 'Options'; |
|
156 | 156 | |
157 | 157 | return $this->modelManager->{$method}(); |
158 | 158 | } |
@@ -166,7 +166,7 @@ discard block |
||
166 | 166 | */ |
167 | 167 | public function hasOptionsMethod($key) |
168 | 168 | { |
169 | - return method_exists($this->modelManager, 'get'.Str::studly($key).'Options'); |
|
169 | + return method_exists($this->modelManager, 'get' . Str::studly($key) . 'Options'); |
|
170 | 170 | } |
171 | 171 | |
172 | 172 | /** |
@@ -27,18 +27,18 @@ |
||
27 | 27 | |
28 | 28 | if (!empty($_POST)) |
29 | 29 | { |
30 | - foreach ( $_POST as $key => $value ) |
|
30 | + foreach ($_POST as $key => $value) |
|
31 | 31 | { |
32 | - if ( ( !is_string($value) && !is_numeric($value) ) || !is_string($key) ) |
|
32 | + if ((!is_string($value) && !is_numeric($value)) || !is_string($key)) |
|
33 | 33 | continue; |
34 | 34 | |
35 | - if ( get_magic_quotes_gpc() ) |
|
36 | - $value = htmlspecialchars( stripslashes((string)$value) ); |
|
35 | + if (get_magic_quotes_gpc()) |
|
36 | + $value = htmlspecialchars(stripslashes((string) $value)); |
|
37 | 37 | else |
38 | - $value = htmlspecialchars( (string)$value ); |
|
38 | + $value = htmlspecialchars((string) $value); |
|
39 | 39 | ?> |
40 | 40 | <tr> |
41 | - <th style="vertical-align: top"><?php echo htmlspecialchars( (string)$key ); ?></th> |
|
41 | + <th style="vertical-align: top"><?php echo htmlspecialchars((string) $key); ?></th> |
|
42 | 42 | <td><pre class="samples"><?php echo $value; ?></pre></td> |
43 | 43 | </tr> |
44 | 44 | <?php |