PHP Class Owl\Repositories\Eloquent\ItemRepository

Inheritance: implements Owl\Repositories\ItemRepositoryInterface
Afficher le fichier Open project: owl/owl

Protected Properties

Свойство Type Description
$item

Méthodes publiques

Méthode Description
__construct ( Item $item )
createItem ( $obj ) : Illuminate\Database\Eloquent\Model Create a new item.
deleteItem ( $item_id ) : boolean Delete a item.
getAllFlowPublished ( ) : Illuminate\Database\Eloquent\Model Get flow published items.
getAllPublished ( ) : Illuminate\Database\Eloquent\Model Get all published items.
getAllStockPublished ( ) : Illuminate\Database\Eloquent\Model Get stock published items.
getById ( integer $item_id ) : Illuminate\Database\Eloquent\Model Get a item by item id.
getByOpenItemId ( integer $open_item_id ) : Illuminate\Database\Eloquent\Model Get a item by open item id.
getByOpenItemIdWithComment ( integer $open_item_id ) : Illuminate\Database\Eloquent\Model Get a item by open item id with comments.
getLikeUsersById ( integer $item_id ) : Illuminate\Database\Eloquent\Model Get like users by item id.
getRecentsByLoginUserIdWithPaginate ( integer $user_id ) : Illuminate\Database\Eloquent\Model Get recent items by login user id with paginate.
getRecentsByTagId ( $tag_id ) : Illuminate\Database\Eloquent\Model Get recent items by tag id.
getRecentsByUserId ( integer $user_id ) : Illuminate\Database\Eloquent\Model Get recent items by user id.
getRecentsByUserIdWithPaginate ( integer $user_id ) : Illuminate\Database\Eloquent\Model Get recent items by user id with paginate.
getTagsToArray ( object $item ) : array get item tags array
updateItem ( $id, $obj ) : Illuminate\Database\Eloquent\Model Update a item.

Method Details

__construct() public méthode

public __construct ( Item $item )
$item Owl\Repositories\Eloquent\Models\Item

createItem() public méthode

Create a new item.
public createItem ( $obj ) : Illuminate\Database\Eloquent\Model
$obj user_id, open_item_id, title, body, published
Résultat Illuminate\Database\Eloquent\Model

deleteItem() public méthode

Delete a item.
public deleteItem ( $item_id ) : boolean
$item_id int
Résultat boolean

getAllFlowPublished() public méthode

Get flow published items.
public getAllFlowPublished ( ) : Illuminate\Database\Eloquent\Model
Résultat Illuminate\Database\Eloquent\Model

getAllPublished() public méthode

Get all published items.
public getAllPublished ( ) : Illuminate\Database\Eloquent\Model
Résultat Illuminate\Database\Eloquent\Model

getAllStockPublished() public méthode

Get stock published items.
public getAllStockPublished ( ) : Illuminate\Database\Eloquent\Model
Résultat Illuminate\Database\Eloquent\Model

getById() public méthode

Get a item by item id.
public getById ( integer $item_id ) : Illuminate\Database\Eloquent\Model
$item_id integer
Résultat Illuminate\Database\Eloquent\Model

getByOpenItemId() public méthode

Get a item by open item id.
public getByOpenItemId ( integer $open_item_id ) : Illuminate\Database\Eloquent\Model
$open_item_id integer
Résultat Illuminate\Database\Eloquent\Model

getByOpenItemIdWithComment() public méthode

Get a item by open item id with comments.
public getByOpenItemIdWithComment ( integer $open_item_id ) : Illuminate\Database\Eloquent\Model
$open_item_id integer
Résultat Illuminate\Database\Eloquent\Model

getLikeUsersById() public méthode

Get like users by item id.
public getLikeUsersById ( integer $item_id ) : Illuminate\Database\Eloquent\Model
$item_id integer
Résultat Illuminate\Database\Eloquent\Model

getRecentsByLoginUserIdWithPaginate() public méthode

Get recent items by login user id with paginate.
public getRecentsByLoginUserIdWithPaginate ( integer $user_id ) : Illuminate\Database\Eloquent\Model
$user_id integer
Résultat Illuminate\Database\Eloquent\Model

getRecentsByTagId() public méthode

Get recent items by tag id.
public getRecentsByTagId ( $tag_id ) : Illuminate\Database\Eloquent\Model
Résultat Illuminate\Database\Eloquent\Model

getRecentsByUserId() public méthode

Get recent items by user id.
public getRecentsByUserId ( integer $user_id ) : Illuminate\Database\Eloquent\Model
$user_id integer
Résultat Illuminate\Database\Eloquent\Model

getRecentsByUserIdWithPaginate() public méthode

Get recent items by user id with paginate.
public getRecentsByUserIdWithPaginate ( integer $user_id ) : Illuminate\Database\Eloquent\Model
$user_id integer
Résultat Illuminate\Database\Eloquent\Model

getTagsToArray() public méthode

get item tags array
public getTagsToArray ( object $item ) : array
$item object
Résultat array

updateItem() public méthode

Update a item.
public updateItem ( $id, $obj ) : Illuminate\Database\Eloquent\Model
$obj user_id, open_item_id, title, body, published
Résultat Illuminate\Database\Eloquent\Model

Property Details

$item protected_oe property

protected $item