source/Core/UtilsCount.php
public function setManufacturerArticleCount($aCache, $sMnfId, $sActIdent)
    {
        // if Manufacturer/category name is 'root', skip counting
        if ($sMnfId == 'root') {
            return 0;
        }

        $oArticle = oxNew(\OxidEsales\Eshop\Application\Model\Article::class);
        $sArtTable = $oArticle->getViewName();

        // select each Manufacturer articles count
        //#3485
        $sQ = "select count($sArtTable.oxid) from $sArtTable where $sArtTable.oxparentid = '' and oxmanufacturerid = '$sMnfId' and " . $oArticle->getSqlActiveSnippet();

        $iValue = \OxidEsales\Eshop\Core\DatabaseProvider::getDb()->getOne($sQ);

        $aCache[$sMnfId][$sActIdent] = (int) $iValue;

        $this->_setManufacturerCache($aCache);

        return $aCache[$sMnfId][$sActIdent];
    }
public function setManufacturerArticleCount($aCache, $sMnfId, $sActIdent)
    {
        // if Manufacturer/category name is 'root', skip counting
        if ($sMnfId == 'root') {
            return 0;
        }

        $oArticle = oxNew(\OxidEsales\Eshop\Application\Model\Article::class);
        $sArtTable = $oArticle->getViewName();

        // select each Manufacturer articles count
        //#3485
        $sQ = "select count($sArtTable.oxid) from $sArtTable where $sArtTable.oxparentid = '' and oxmanufacturerid = '$sMnfId' and " . $oArticle->getSqlActiveSnippet();

        $iValue = \OxidEsales\Eshop\Core\DatabaseProvider::getDb()->getOne($sQ);

        $aCache[$sMnfId][$sActIdent] = (int) $iValue;

        $this->_setManufacturerCache($aCache);

        return $aCache[$sMnfId][$sActIdent];
    }
public function setManufacturerArticleCount ( $ aCache , $ sMnfId , $ sActIdent ) { // if Manufacturer/category name is 'root', skip counting if ( $ sMnfId == 'root' ) { return 0 ; } $ oArticle = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Article :: class ) ; $ sArtTable = $ oArticle -> getViewName ( ) ; // select each Manufacturer articles count //#3485 $ sQ = "select count($sArtTable.oxid) from $sArtTable where $sArtTable.oxparentid = '' and oxmanufacturerid = '$sMnfId' and " . $ oArticle -> getSqlActiveSnippet ( ) ; $ iValue = \ OxidEsales \ Eshop \ Core \ DatabaseProvider :: getDb ( ) -> getOne ( $ sQ ) ; $ aCache [ $ sMnfId ] [ $ sActIdent ] = ( int ) $ iValue ; $ this -> _setManufacturerCache ( $ aCache ) ; return $ aCache [ $ sMnfId ] [ $ sActIdent ] ; }
Saves and returns Manufacturers category article count into cache

@param array  $aCache    Category cache data
@param string $sMnfId    Unique Manufacturer ident
@param string $sActIdent Unique user context ID

@return int
Saves and returns Manufacturers category article count into cache