更新分类编辑
This commit is contained in:
parent
70d35fbc66
commit
7ef7edad6b
@ -120,7 +120,6 @@ class ArticleCategory extends BaseController
|
||||
return app('json')->fail('数据不存在');
|
||||
if ($data['pid'] && !$this->repository->merExists(0, $data['pid']))
|
||||
return app('json')->fail('上级分类不存在');
|
||||
|
||||
$this->repository->update($id, $data);
|
||||
return app('json')->success('编辑成功');
|
||||
}
|
||||
@ -181,7 +180,7 @@ class ArticleCategory extends BaseController
|
||||
*/
|
||||
public function checkParams(ArticleCategoryValidate $validate)
|
||||
{
|
||||
$data = $this->request->params([['pid', 0], 'title', 'info', 'status', 'image', 'sort']);
|
||||
$data = $this->request->params([['pid', 0], 'title', 'info', 'status', 'is_home', 'image', 'sort']);
|
||||
$validate->check($data);
|
||||
return $data;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user