Skip to content

Instantly share code, notes, and snippets.

@nissicreative
Last active August 31, 2016 15:28
Show Gist options
  • Save nissicreative/29ce7ac5df23980fb855d75bad268ccd to your computer and use it in GitHub Desktop.
Save nissicreative/29ce7ac5df23980fb855d75bad268ccd to your computer and use it in GitHub Desktop.
Admin Resource Index
@extends('admin.layouts.master')
@section('page_meta')
<title>{{ page_title('{Resources}') }}</title>
@endsection
@section('content')
<a href="{{ route('admin.{items}.create') }}" class="btn btn-primary pull-right"><i class="fa fa-plus"></i>&nbsp;&nbsp;Add {Resource}</a>
<h1 class="page-header">{Resources}</h1>
<table class="table table-striped card">
<thead>
<tr>
<th>Actions</th>
</tr>
</thead>
<tbody>
@foreach(${items} as $item)
<tr>
<td>
<div class="btn-row">
<a href="{{ route('admin.{items}.edit', $item->id) }}" class="btn btn-default btn-xs">Edit</a>
</div>
</td>
</tr>
@endforeach
</tbody>
</table>
{{-- Paginator --}}
<div class="text-center">{{ ${items}->links() }}</div>
@endsection
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment