Пример #1
0
                          <tr>
                              @foreach($columns as $column)
                                  <td>@if(in_array($column,$hide))<i>HIDDEN</i>@else @if($row->$column == "")<i>EMPTY</i>@else {{ $row->$column }} @endif @endif</td>
                              @endforeach
                              @if($allow_edit and \Schema::hasColumn($name, 'id'))
                                  <td>
                                      <a href="{{ route('Laralum::CRUD_edit', ['table' => $name, 'id' => $row->id]) }}" class="ui {{ Laralum::settings()->button_color }} button">{{ trans('laralum.edit') }}</a>
                                  </td>
                              @else
                                  <td>
                                      <a class="ui disabled {{ Laralum::settings()->button_color }} button">{{ trans('laralum.edit') }}</a>
                                  </td>
                              @endif
                              <?php 
# Check if you're allowed to delete rows
require Laralum::dataPath() . '/DevData.php';
$del = true;
if (array_key_exists($name, $data)) {
    if (array_key_exists('delete', $data[$name])) {
        if (!$data[$name]['delete']) {
            $del = false;
        }
    }
}
?>
                              @if($del)
                                  <td>
                                      <a href="{{ route('Laralum::CRUD_delete', ['table' => $name, 'id' => $row->id]) }}" class="ui {{ Laralum::settings()->button_color }} button">{{ trans('laralum.delete') }}</a>
                                  </td>
                              @else
                                  <td>