Fixed route parameters and tests to match
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
@@ -97,7 +97,7 @@ class AccessoriesController extends Controller
|
||||
*/
|
||||
public function edit(Accessory $accessory) : View | RedirectResponse
|
||||
{
|
||||
return view('accessories.edit')->with('category_type', 'accessory');
|
||||
return view('accessories.edit')->with('item', $accessory)->with('category_type', 'accessory');
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -83,7 +83,7 @@ final class CompaniesController extends Controller
|
||||
public function edit(Company $company) : View | RedirectResponse
|
||||
{
|
||||
$this->authorize('update', $company);
|
||||
return view('companies/edit');
|
||||
return view('companies/edit')->with('item', $company);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -111,7 +111,9 @@ class ComponentsController extends Controller
|
||||
{
|
||||
|
||||
$this->authorize('update', $component);
|
||||
return view('components/edit')->with('category_type', 'component');
|
||||
return view('components/edit')
|
||||
->with('item', $component)
|
||||
->with('category_type', 'component');
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user