Skip to content

Commit

Permalink
Fixes #3 and Fixes #4
Browse files Browse the repository at this point in the history
  • Loading branch information
mrakodol committed Oct 28, 2014
1 parent 157f3c9 commit 7dd6d6c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/Http/Controllers/Admin/LanguageController.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ public function postEdit(LanguageRequest $request, $id)

public function getDelete($id)
{
$language = Language::find($id);
$language = $id;
// Show the page
return view('admin/language/delete', compact('language'));
}
Expand Down
4 changes: 2 additions & 2 deletions resources/views/admin/language/delete.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<ul class="nav nav-tabs">
<li class="active"><a href="#tab-general" data-toggle="tab">{{ Lang::get("admin/modal.general") }}</a></li>
</ul>
<form id="deleteForm" class="form-horizontal" method="post" action="@if (isset($language)){{ URL::to('admin/language/' . $language->id . '/delete') }}@endif" autocomplete="off">
<form id="deleteForm" class="form-horizontal" method="post" action="{{ URL::to('admin/language/' . $language . '/delete') }}" autocomplete="off">
<input type="hidden" name="_token" value="{{{ csrf_token() }}}" />
<input type="hidden" name="id" value="{{ $language->id }}" />
<input type="hidden" name="id" value="{{ $language }}" />
<div class="form-group">
<div class="controls">
{{ Lang::get("admin/modal.delete_message") }}<br>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/site/layouts/default.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
@if(isset($admin))
<li><a href="{{{ URL::to('admin') }}}">{{{ Lang::get('site/site.admin_panel') }}}</a></li>
@endif
<li><a href="{{{ URL::to('auth/changepassword') }}}">{{{ Lang::get('site/site.login_as') }}} {{{ Auth::user()->name }}}</a></li>
<li><a href="#">{{{ Lang::get('site/site.login_as') }}} {{{ Auth::user()->name }}}</a></li>
<li><a href="{{{ URL::to('auth/logout') }}}">{{{ Lang::get('site/site.logout') }}}</a></li>
@else
<li {{ (Request::is('auth/login') ? ' class="active"' : '') }}><a href="{{{ URL::to('auth/login') }}}">{{{ Lang::get('site/site.login') }}}</a></li>
Expand Down

0 comments on commit 7dd6d6c

Please sign in to comment.