\App\Repositories\EloquentArticleCategoryRepositoryEloquent

Class ArticleCategoryRepositoryEloquent

Summary

Methods
Properties
Constants
model()
boot()
getAllCate()
saveCate()
updateCate()
saveCateOrder()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

model()

model() : string

Specify Model class name

Returns

string

boot()

boot() 

Boot up the repository, pushing criteria

getAllCate()

getAllCate(integer  $parent_id) : array

获取全部分类

Parameters

integer $parent_id

父类ID

Returns

array

saveCate()

saveCate(  $data) : array

保存新增分类

Parameters

$data

object 保存信息

Returns

array

updateCate()

updateCate(integer  $id, object  $request) : array

更新分类

Parameters

integer $id
object $request

Returns

array

saveCateOrder()

saveCateOrder(object  $cates, integer  $parent_id) : boolean

保存分类排序

Parameters

object $cates
integer $parent_id

Returns

boolean