@tsteur opened this Pull Request on April 14th 2019 Member

fix https://github.com/matomo-org/matomo/issues/9716

I actually tried to fix it by changing eg


class GetCategoryFromNameId extends Base
{
    protected function init()
    {
        parent::init();

        $this->dimension     = new EventCategory();
        $this->name          = Piwik::translate('Events_EventCategories');
        $this->isSubtableReport = true;
    }
}

to

class GetCategoryFromNameId extends Base
{
    protected function init()
    {
        parent::init();

        $this->dimension     = new EventCategory();
        $this->name          = Piwik::translate('Events_EventCategories');
        $this->isSubtableReport = true;
        $this->parameters = array('secondaryDimension' => 'eventName')
    }
}

so the report has its own unique id and the viewDataTables will be only applied to this report. The problem though is that this doesn't quite work with our report factory which would always use the GetCategory report etc.

The easy workaround is to simply not store the pivoted view data table option when switching between related reports.

This Pull Request was closed on May 20th 2019
Powered by GitHub Issue Mirror