mirror of
https://github.com/openclassify/openclassify.git
synced 2026-02-09 14:56:13 -06:00
added category
This commit is contained in:
parent
7123f56ba2
commit
d8ac259197
@ -4,4 +4,13 @@ use Anomaly\Streams\Platform\Entry\EntryCollection;
|
|||||||
|
|
||||||
class CategoryCollection extends EntryCollection
|
class CategoryCollection extends EntryCollection
|
||||||
{
|
{
|
||||||
|
|
||||||
|
public function mainCategories()
|
||||||
|
{
|
||||||
|
return $this->filter(
|
||||||
|
function ($category) {
|
||||||
|
return (is_null($category->parent_category_id));
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user