3
0
mirror of https://github.com/snipe/snipe-it.git synced 2026-02-05 23:05:58 +00:00

Add ability to view assets by status label

This should be refactored. Lots of copypaste from the assets views here
This commit is contained in:
snipe
2017-01-18 20:41:40 -08:00
parent 19cb428fb0
commit ad4bf83aaa
6 changed files with 153 additions and 3 deletions

View File

@ -32,10 +32,19 @@ class StatuslabelsController extends Controller
public function index()
{
// Show the page
return View::make('statuslabels/index', compact('statuslabels'));
}
public function show($id)
{
$statuslabel = Statuslabel::find($id);
if (isset($statuslabel->id)) {
return View::make('statuslabels/view', compact('statuslabel'));
}
return redirect()->route('statuslabels.index')->with('error', trans('admin/locations/message.does_not_exist', compact('id')));
}