Conditions | 2 |
Paths | 2 |
Total Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
47 | public function findByParent(int $topCategory, bool $sorting = false) |
||
48 | { |
||
49 | $query = $this->createQuery(); |
||
50 | $query->matching($query->equals('parent', $topCategory)); |
||
51 | if ($sorting) { |
||
52 | $query->setOrderings(['title' => QueryInterface::ORDER_ASCENDING]); |
||
53 | } |
||
54 | |||
55 | return $query->execute(); |
||
56 | } |
||
57 | } |
||
58 |