Piwik\Plugins\Goals\API::getGoalSpecificDataTable PHP Метод

getGoalSpecificDataTable() защищенный Метод

Utility method that retrieve an archived DataTable for a specific site, date range, segment and goal. If not goal is specified, this method will retrieve and sum the data for every goal.
protected getGoalSpecificDataTable ( string $recordName, integer | string $idSite, string $period, string $date, string $segment, integer | boolean $idGoal ) : false | DataTable
$recordName string The archive entry name.
$idSite integer | string The site(s) to select data for.
$period string The period type.
$date string The date type.
$segment string The segment.
$idGoal integer | boolean The id of the goal to get data for. If this is set to false, data for every goal that belongs to $idSite is returned.
Результат false | Piwik\DataTable
    protected function getGoalSpecificDataTable($recordName, $idSite, $period, $date, $segment, $idGoal)
    {
        Piwik::checkUserHasViewAccess($idSite);
        $archive = Archive::build($idSite, $period, $date, $segment);
        // check for the special goal ids
        $realGoalId = $idGoal != true ? false : self::convertSpecialGoalIds($idGoal);
        // get the data table
        $dataTable = $archive->getDataTable(Archiver::getRecordName($recordName, $realGoalId), $idSubtable = null);
        $dataTable->queueFilter('ReplaceColumnNames');
        return $dataTable;
    }