Skip to content

Commit

Permalink
Merge pull request #86 from peelman/develop
Browse files Browse the repository at this point in the history
Cancel and back buttons on edit forms now take you back properly
  • Loading branch information
snipe committed Nov 28, 2013
2 parents 54d9d72 + 54013cf commit 7a3d925
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
10 changes: 10 additions & 0 deletions app/views/backend/assets/edit.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@
@endif

<div class="pull-right">
@if ($asset->id)
<a href="{{ route('view/asset',$asset->id) }}" class="btn-flat gray"><i class="icon-circle-arrow-left icon-white"></i> Back</a>
@else
<a href="{{ route('assets') }}" class="btn-flat gray"><i class="icon-circle-arrow-left icon-white"></i> Back</a>
@endif

</div>
</h3>
</div>
Expand Down Expand Up @@ -154,7 +159,12 @@
<!-- Form actions -->
<div class="control-group">
<div class="controls">
@if ($asset->id)
<a class="btn btn-link" href="{{ route('view/asset', $asset->id) }}">Cancel</a>
@else
<a class="btn btn-link" href="{{ route('assets') }}">Cancel</a>
@endif

<button type="submit" class="btn-flat success"><i class="icon-ok icon-white"></i> Save</button>
</div>
</div>
Expand Down
8 changes: 8 additions & 0 deletions app/views/backend/licenses/edit.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,11 @@
@endif

<div class="pull-right">
@if ($license->id)
<a href="{{ route('view/license',$license->id) }}" class="btn-flat gray"><i class="icon-circle-arrow-left icon-white"></i> Back</a>
@else
<a href="{{ route('licenses') }}" class="btn-flat gray"><i class="icon-circle-arrow-left icon-white"></i> Back</a>
@endif
</div>
</h3>
</div>
Expand Down Expand Up @@ -117,7 +121,11 @@
<!-- Form actions -->
<div class="control-group">
<div class="controls">
@if ($license->id)
<a class="btn btn-link" href="{{ route('view/license', $license->id) }}">@lang('general.cancel')</a>
@else
<a class="btn btn-link" href="{{ route('licenses') }}">@lang('general.cancel')</a>
@endif
<button type="submit" class="btn-flat success"><i class="icon-ok icon-white"></i> @lang('general.save')</button>
</div>
</div>
Expand Down

0 comments on commit 7a3d925

Please sign in to comment.