public function getSiteFilterQuery($targetTableAlias)
    {
        $parent = $this->getParent();
        if ($parent and $parentId = $parent->getId()) {
            return $targetTableAlias . '.site_id = ' . $parentId;
        } elseif ($id = $this->getId()) {
            return $targetTableAlias . '.site_id = ' . $id;
        }

        return '';
    }
public function getSiteFilterQuery($targetTableAlias)
    {
        $parent = $this->getParent();
        if ($parent and $parentId = $parent->getId()) {
            return $targetTableAlias . '.site_id = ' . $parentId;
        } elseif ($id = $this->getId()) {
            return $targetTableAlias . '.site_id = ' . $id;
        }

        return '';
    }
public function getSiteFilterQuery ( $ targetTableAlias ) { $ parent = $ this -> getParent ( ) ; if ( $ parent and $ parentId = $ parent -> getId ( ) ) { return $ targetTableAlias . '.site_id = ' . $ parentId ; } elseif ( $ id = $ this -> getId ( ) ) { return $ targetTableAlias . '.site_id = ' . $ id ; } return '' ; }
Get filter query

@param $targetTableAlias

@return string
Get filter query