@mattab opened this Issue on November 23rd 2018 Member

The fatal error: Neither the property "getRows" nor one of the methods "getRows()", "getgetRows()"/"isgetRows()" or "__call()" exist and have public access in class "Piwik\DataTable\Map". in plugins/CoreVisualizations/templates/_dataTableViz_htmlTable.twig line 21

Can be reproduced at https://demo.matomo.org/index.php?forceView=1&viewDataTable=..%2fWEB-INF%2fweb.xml%3bx%3d&module=MediaAnalytics&action=get&idSite=3&period=day&date=2018-10-16,2018-11-14&showtitle=1&random=84&columns=sum_total_time_watched&colors={%22backgroundColor%22%3A%22%23ffffff%22%2C%22lineColor%22%3A%22%23162c4a%22%2C%22minPointColor%22%3A%22%23ff7f7f%22%2C%22maxPointColor%22%3A%22%2375bf7c%22%2C%22lastPointColor%22%3A%22%2355aaff%22%2C%22fillColor%22%3A%22%23ffffff%22}

It is only triggered under edge case (ie. security scanner), but will be good to fix since we get this emailed to us quite a bit.

@sgiehl commented on November 24th 2018 Member

The problem is, that multiple dates are requested for a table visualization. The datatable loaded from API is a Map in this case, which doesn't have a ┬┤getRows┬┤ method. Maybe we should throw an exception if multiple dates are requested for a visualization that can't handle it?

@tsteur commented on November 24th 2018 Member

There's also a random viewDataTable used etc. I don't think it's a bug and neither anything needs to be done. It's not really important or efficient to try avoid all of these. You'd need to add this to all visualisations, etc. Feel free to do so though.

Powered by GitHub Issue Mirror