mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-10 07:34:06 -08:00
Improved category_type with strtolower() to make it case insensitive
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
9b52c61d95
commit
61176335d7
|
@ -63,6 +63,7 @@ class CategoriesController extends Controller
|
|||
$this->authorize('create', Category::class);
|
||||
$category = new Category;
|
||||
$category->fill($request->all());
|
||||
$category->category_type = strtolower($request->input('category_type'));
|
||||
$category = $request->handleImages($category);
|
||||
|
||||
if ($category->save()) {
|
||||
|
@ -103,6 +104,7 @@ class CategoriesController extends Controller
|
|||
$this->authorize('update', Category::class);
|
||||
$category = Category::findOrFail($id);
|
||||
$category->fill($request->all());
|
||||
$category->category_type = strtolower($request->input('category_type'));
|
||||
$category = $request->handleImages($category);
|
||||
|
||||
if ($category->save()) {
|
||||
|
|
Loading…
Reference in a new issue