@@ -166,7 +166,9 @@ |
||
166 | 166 | |
167 | 167 | if($form['datatable_orig'] != ''){ |
168 | 168 | $params = explode("|", $form['datatable_orig']); |
169 | - if(!isset($params[2])) $params[2] = "id"; |
|
169 | + if(!isset($params[2])) { |
|
170 | + $params[2] = "id"; |
|
171 | + } |
|
170 | 172 | $value = DB::table($params[0])->where($params[2], $id)->first()->{$params[1]}; |
171 | 173 | $value = explode(",", $value); |
172 | 174 | } else { |
@@ -12,7 +12,9 @@ |
||
12 | 12 | $datatable_field = explode(',', $datatable)[1]; |
13 | 13 | if($form['datatable_orig'] != ''){ |
14 | 14 | $params = explode("|", $form['datatable_orig']); |
15 | - if(!isset($params[2])) $params[2] = "id"; |
|
15 | + if(!isset($params[2])) { |
|
16 | + $params[2] = "id"; |
|
17 | + } |
|
16 | 18 | $values = explode(",", DB::table($params[0])->where($params[2], $id)->first()->{$params[1]}); |
17 | 19 | $tableData = DB::table($datatable_table)->whereIn("id", $values)->select($datatable_field)->pluck($datatable_field)->toArray(); |
18 | 20 | } else { |
@@ -15,12 +15,16 @@ |
||
15 | 15 | if(in_array(strtolower($ext), $images_type)): |
16 | 16 | ?> |
17 | 17 | <p><a data-lightbox='roadtrip' href='{{$url}}'><img style='max-width:160px' title="Image For {{$form['label']}}" src='{{$url}}'/></a></p> |
18 | - <?php else:?> |
|
18 | + <?php else { |
|
19 | + :?> |
|
19 | 20 | <p><a href='{{$url}}'>{{trans("crudbooster.button_download_file")}}</a></p> |
20 | 21 | <?php endif; |
22 | +} |
|
21 | 23 | echo "<input type='hidden' name='_$name' value='$value'/>"; |
22 | - else: |
|
24 | + else { |
|
25 | + : |
|
23 | 26 | echo "<p class='text-danger'><i class='fa fa-exclamation-triangle'></i> ".trans("crudbooster.file_broken")."</p>"; |
27 | + } |
|
24 | 28 | endif; |
25 | 29 | ?> |
26 | 30 | @if(!$readonly || !$disabled) |
@@ -4,7 +4,10 @@ |
||
4 | 4 | if(Storage::exists($value) || file_exists($value)): |
5 | 5 | if(in_array(strtolower($ext), $images_type)):?> |
6 | 6 | <a data-lightbox='roadtrip' href='{{asset($value)}}'><img style='max-width:150px' title="Image For {{$form['label']}}" src='{{asset($value)}}'/></a> |
7 | -<?php else:?> |
|
7 | +<?php else { |
|
8 | + :?> |
|
8 | 9 | <a href='{{asset($value)}}?download=1' target="_blank">{{trans("crudbooster.button_download_file")}}: {{basename($value)}} <i class="fa fa-download"></i></a> |
9 | -<?php endif;?> |
|
10 | +<?php endif; |
|
11 | +} |
|
12 | +?> |
|
10 | 13 | <?php endif;?> |
@@ -81,7 +81,9 @@ |
||
81 | 81 | foreach ($selects_data as $d) { |
82 | 82 | $val = $d->{$datatable_field}; |
83 | 83 | $checked = (is_array($value) && in_array($val, $value)) ? "checked" : ""; |
84 | - if ($val == '' || ! $d->id) continue; |
|
84 | + if ($val == '' || ! $d->id) { |
|
85 | + continue; |
|
86 | + } |
|
85 | 87 | |
86 | 88 | echo " |
87 | 89 | <div data-val='$val' class='checkbox $disabled'> |
@@ -6,7 +6,9 @@ |
||
6 | 6 | $type = @$form['type'] ?: 'text'; |
7 | 7 | $name = $form['name']; |
8 | 8 | |
9 | -if (in_array($type, $asset_already)) continue; |
|
9 | +if (in_array($type, $asset_already)) { |
|
10 | + continue; |
|
11 | +} |
|
10 | 12 | ?> |
11 | 13 | @if(file_exists(base_path('/vendor/crocodicstudio/crudbooster/src/views/default/type_components/'.$type.'/asset.blade.php'))) |
12 | 14 | @include('crudbooster::default.type_components.'.$type.'.asset') |
@@ -4,7 +4,9 @@ |
||
4 | 4 | foreach($forms as $form) { |
5 | 5 | $type = @$form['type'] ?: 'text'; |
6 | 6 | |
7 | -if (in_array($type, $asset_already)) continue; |
|
7 | +if (in_array($type, $asset_already)) { |
|
8 | + continue; |
|
9 | +} |
|
8 | 10 | |
9 | 11 | ?> |
10 | 12 | @if(file_exists(base_path('/vendor/crocodicstudio/crudbooster/src/views/default/type_components/'.$type.'/asset.blade.php'))) |
@@ -59,7 +59,9 @@ discard block |
||
59 | 59 | <?php endif;?> |
60 | 60 | <?php |
61 | 61 | foreach ($columns as $col) { |
62 | - if ($col['visible'] === FALSE) continue; |
|
62 | + if ($col['visible'] === FALSE) { |
|
63 | + continue; |
|
64 | + } |
|
63 | 65 | |
64 | 66 | $sort_column = Request::get('filter_column'); |
65 | 67 | $colname = $col['label']; |
@@ -107,9 +109,12 @@ discard block |
||
107 | 109 | <td colspan='{{count($columns)+3}}' align="center"> |
108 | 110 | <?php elseif( ($button_bulk_action && ! $show_numbering) || (! $button_bulk_action && $show_numbering) ):?> |
109 | 111 | <td colspan='{{count($columns)+2}}' align="center"> |
110 | - <?php else:?> |
|
112 | + <?php else { |
|
113 | + :?> |
|
111 | 114 | <td colspan='{{count($columns)+1}}' align="center"> |
112 | - <?php endif;?> |
|
115 | + <?php endif; |
|
116 | +} |
|
117 | +?> |
|
113 | 118 | |
114 | 119 | <i class='fa fa-search'></i> {{trans("crudbooster.table_data_not_found")}} |
115 | 120 | </td> |
@@ -159,7 +164,9 @@ discard block |
||
159 | 164 | |
160 | 165 | <?php |
161 | 166 | foreach ($columns as $col) { |
162 | - if ($col['visible'] === FALSE) continue; |
|
167 | + if ($col['visible'] === FALSE) { |
|
168 | + continue; |
|
169 | + } |
|
163 | 170 | $colname = $col['label']; |
164 | 171 | $width = ($col['width']) ?: "auto"; |
165 | 172 | $style = ($col['style']) ?: ""; |
@@ -311,7 +318,10 @@ discard block |
||
311 | 318 | <form method='get' action=''> |
312 | 319 | <div class="modal-body"> |
313 | 320 | <?php foreach($columns as $key => $col):?> |
314 | - <?php if (isset($col['image']) || isset($col['download']) || $col['visible'] === FALSE) continue;?> |
|
321 | + <?php if (isset($col['image']) || isset($col['download']) || $col['visible'] === FALSE) { |
|
322 | + continue; |
|
323 | +} |
|
324 | +?> |
|
315 | 325 | |
316 | 326 | <div class='form-group'> |
317 | 327 |
@@ -117,7 +117,10 @@ |
||
117 | 117 | @if($param['used']) |
118 | 118 | <?php |
119 | 119 | $param_exception = ['in', 'not_in', 'digits_between']; |
120 | - if ($param['config'] && substr($param['config'], 0, 1) != '*' && ! in_array($param['type'], $param_exception)) continue;?> |
|
120 | + if ($param['config'] && substr($param['config'], 0, 1) != '*' && ! in_array($param['type'], $param_exception)) { |
|
121 | + continue; |
|
122 | + } |
|
123 | + ?> |
|
121 | 124 | <tr> |
122 | 125 | <td>{{++$i}}</td> |
123 | 126 | <td width="5%"><em>{{$param['type']}}</em></td> |