src/actions/AdjacencyList/FullTreeDataAction.php 1 location
|
@@ 100-104 (lines=5) @@
|
| 97 |
|
$query = $class::find() |
| 98 |
|
->orderBy([$this->querySortOrder => SORT_ASC]); |
| 99 |
|
|
| 100 |
|
if ($this->whereCondition instanceof \Closure) { |
| 101 |
|
$query->where(call_user_func($this->whereCondition)); |
| 102 |
|
} elseif (count($this->whereCondition) > 0) { |
| 103 |
|
$query->where($this->whereCondition); |
| 104 |
|
} |
| 105 |
|
|
| 106 |
|
if (null === $rows = $query->asArray()->all()) { |
| 107 |
|
return []; |
src/actions/AdjacencyList/PartialTreeDataAction.php 1 location
|
@@ 102-106 (lines=5) @@
|
| 99 |
|
$query = $class::find() |
| 100 |
|
->orderBy([$this->querySortOrder => SORT_ASC]); |
| 101 |
|
|
| 102 |
|
if ($this->whereCondition instanceof \Closure) { |
| 103 |
|
$query->where(call_user_func($this->whereCondition)); |
| 104 |
|
} elseif (count($this->whereCondition) > 0) { |
| 105 |
|
$query->where($this->whereCondition); |
| 106 |
|
} |
| 107 |
|
$query->andWhere([$this->modelParentAttribute => $parent_id]); |
| 108 |
|
|
| 109 |
|
if (null === $rows = $query->asArray()->all()) { |