Package Data | |
---|---|
Maintainer Username: | djordje |
Package Create Date: | 2013-10-27 |
Package Last Update: | 2013-12-01 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-12-15 15:17:36 |
Package Statistics | |
---|---|
Total Downloads: | 49 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 4 |
Total Watchers: | 1 |
Total Forks: | 0 |
Total Open Issues: | 0 |
Simple backend layout based on Twitter Bootstrap 3 for rapid backend view creation.
Recommended installation is trough composer, add to your composer.json
:
"require": {
"djordje/laravel-backend-layout": "dev-master"
}
Add service provider to your app/config/app.php
file:
# ...
'providers' => array(
# ...
'Djordje\LaravelBackendLayout\LaravelBackendLayoutServiceProvider',
),
# ...
Publish package configuration:
php artisan config:publish djordje/laravel-backend-layout
Publish package assets:
php artisan asset:publish djordje/laravel-backend-layout
Use it in your view:
@extends('laravel-backend-layout::default')
{{-- Optional --}}
@section('title')
My page title
@stop
{{-- Optional --}}
@section('head_hook')
<!-- Your custom CSS, JS or meta data for <head> section -->
@stop
{{-- Optional --}}
@section('navbar_hook')
<!-- Your custom additional content for navbar, usualy some menu links or search form -->
@stop
@section('left_col')
<!-- Content for left column, usualy menu navigation for current controller -->
{{ \Djordje\LaravelTwbsHelpers\Facades\TwbsListGroup::build(array('items' => array(
array('Index', 'href' => route('controller.index')),
array('Add', 'href' => route('controller.add')),
array('Help', 'href' => route('controller.help'))
))) }}
@stop
@section('content')
<!-- Your view -->
<table class="table table-hover-table-bordered table-striped">
<thead>
<!-- ... -->
</thead>
<tbody>
<!-- ... -->
</tbody>
</table>
@stop
** User dropdown partial template:**
You can create your custom dropdown to match your routes and auth system!
<ul class="nav navbar-nav pull-right">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<!-- User name or avatar -->
<b class="caret"></b>
</a>
<ul class="dropdown-menu">
<!-- User links -->
<li>
<a href="/signout">
<i class="glyphicon glyphicon-log-out"></i> Sign out!
</a>
</li>
</ul>
</li>
</ul>