@@ 1635-1637 (lines=3) @@ | ||
1632 | return $ret; |
|
1633 | } |
|
1634 | if (!$inSubCat) { |
|
1635 | while ($row = $result->fetch(\PDO::FETCH_ASSOC)) { |
|
1636 | $catsCount[$row['categoryid']] = $row['count']; |
|
1637 | } |
|
1638 | return $catsCount; |
|
1639 | } |
|
1640 | while ($row = $result->fetch(\PDO::FETCH_ASSOC)) { |
|
@@ 1640-1642 (lines=3) @@ | ||
1637 | } |
|
1638 | return $catsCount; |
|
1639 | } |
|
1640 | while ($row = $result->fetch(\PDO::FETCH_ASSOC)) { |
|
1641 | $catsCount[$row['parentid']][$row['categoryid']] = $row['count']; |
|
1642 | } |
|
1643 | $resultCatCounts = array(); |
|
1644 | foreach ($catsCount[0] as $subCatId => $count) { |
|
1645 | $resultCatCounts[$subCatId] = $count; |