mirror of
https://github.com/snipe/snipe-it.git
synced 2025-02-02 08:21:09 -08:00
Cleaned up status label method
This commit is contained in:
parent
7496a902bd
commit
0788347990
|
@ -32,18 +32,17 @@ class StatuslabelsController extends Controller
|
||||||
|
|
||||||
public function index()
|
public function index()
|
||||||
{
|
{
|
||||||
return view('statuslabels/index', compact('statuslabels'));
|
return view('statuslabels.index', compact('statuslabels'));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function show($id)
|
public function show($id)
|
||||||
{
|
{
|
||||||
$statuslabel = Statuslabel::find($id);
|
|
||||||
|
|
||||||
if (isset($statuslabel->id)) {
|
if ($statuslabel = Statuslabel::find($id)) {
|
||||||
return view('statuslabels/view', compact('statuslabel'));
|
return view('statuslabels.view')->with('statuslabel', $statuslabel);
|
||||||
}
|
}
|
||||||
|
|
||||||
return redirect()->route('statuslabels.index')->with('error', trans('admin/locations/message.does_not_exist', compact('id')));
|
return redirect()->route('statuslabels.index')->with('error', trans('admin/statuslabels/message.does_not_exist', compact('id')));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue