| @@ 92-97 (lines=6) @@ | ||
| 89 | } |
|
| 90 | } |
|
| 91 | ||
| 92 | if (\is_null($parentId)) { |
|
| 93 | $qb->andWhere('b.parent is NULL'); |
|
| 94 | } elseif ($parentId !== false) { |
|
| 95 | $qb->andWhere('b.parent = :parent') |
|
| 96 | ->setParameter('parent', $parentId); |
|
| 97 | } |
|
| 98 | if ($rootNode) { |
|
| 99 | $qb->andWhere('b.lft >= :left') |
|
| 100 | ->andWhere('b.rgt <= :right') |
|
| @@ 486-493 (lines=8) @@ | ||
| 483 | $qb->andWhere('t.online = true'); |
|
| 484 | } |
|
| 485 | ||
| 486 | if (\is_null($parentId)) { |
|
| 487 | $qb->andWhere('n.parent is NULL'); |
|
| 488 | } elseif ($parentId === false) { |
|
| 489 | // Do nothing |
|
| 490 | } else { |
|
| 491 | $qb->andWhere('n.parent = :parent') |
|
| 492 | ->setParameter('parent', $parentId); |
|
| 493 | } |
|
| 494 | ||
| 495 | $query = $qb->getQuery(); |
|
| 496 | ||