Skip to content

Commit

Permalink
View changes
Browse files Browse the repository at this point in the history
  • Loading branch information
sohelamin committed Mar 4, 2018
1 parent 9b7eece commit 33de683
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
8 changes: 4 additions & 4 deletions publish/views/layouts/app.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,22 +35,22 @@
<ul class="navbar-nav ml-auto">
<!-- Authentication Links -->
@guest
<li><a class="nav-link" href="{{ route('login') }}">Login</a></li>
<li><a class="nav-link" href="{{ route('register') }}">Register</a></li>
<li><a class="nav-link" href="{{ url('/login') }}">Login</a></li>
<li><a class="nav-link" href="{{ url('/register') }}">Register</a></li>
@else
<li class="nav-item dropdown">
<a id="navbarDropdown" class="nav-link dropdown-toggle" href="#" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{{ Auth::user()->name }} <span class="caret"></span>
</a>

<div class="dropdown-menu" aria-labelledby="navbarDropdown">
<a class="dropdown-item" href="{{ route('logout') }}"
<a class="dropdown-item" href="{{ url('/logout') }}"
onclick="event.preventDefault();
document.getElementById('logout-form').submit();">
Logout
</a>

<form id="logout-form" action="{{ route('logout') }}" method="POST" style="display: none;">
<form id="logout-form" action="{{ url('/logout') }}" method="POST" style="display: none;">
@csrf
</form>
</div>
Expand Down
12 changes: 6 additions & 6 deletions src/stubs/views/laravelcollective/show.blade.stub
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,20 @@
@include('admin.sidebar')

<div class="col-md-9">
<div class="panel panel-default">
<div class="panel-heading">%%modelName%% {{ $%%crudNameSingular%%->%%primaryKey%% }}</div>
<div class="panel-body">
<div class="card">
<div class="card-header">%%modelName%% {{ $%%crudNameSingular%%->%%primaryKey%% }}</div>
<div class="card-body">

<a href="{{ url('/%%routeGroup%%%%viewName%%') }}" title="Back"><button class="btn btn-warning btn-xs"><i class="fa fa-arrow-left" aria-hidden="true"></i> Back</button></a>
<a href="{{ url('/%%routeGroup%%%%viewName%%/' . $%%crudNameSingular%%->%%primaryKey%% . '/edit') }}" title="Edit %%modelName%%"><button class="btn btn-primary btn-xs"><i class="fa fa-pencil-square-o" aria-hidden="true"></i> Edit</button></a>
<a href="{{ url('/%%routeGroup%%%%viewName%%') }}" title="Back"><button class="btn btn-warning btn-sm"><i class="fa fa-arrow-left" aria-hidden="true"></i> Back</button></a>
<a href="{{ url('/%%routeGroup%%%%viewName%%/' . $%%crudNameSingular%%->%%primaryKey%% . '/edit') }}" title="Edit %%modelName%%"><button class="btn btn-primary btn-sm"><i class="fa fa-pencil-square-o" aria-hidden="true"></i> Edit</button></a>
{!! Form::open([
'method'=>'DELETE',
'url' => ['%%routeGroup%%%%crudName%%', $%%crudNameSingular%%->%%primaryKey%%],
'style' => 'display:inline'
]) !!}
{!! Form::button('<i class="fa fa-trash-o" aria-hidden="true"></i> Delete', array(
'type' => 'submit',
'class' => 'btn btn-danger btn-xs',
'class' => 'btn btn-danger btn-sm',
'title' => 'Delete %%modelName%%',
'onclick'=>'return confirm("Confirm delete?")'
))!!}
Expand Down

0 comments on commit 33de683

Please sign in to comment.