Error view report

Hi all

Reciently i have problems when I tried access to the option view report in the menu stats & reports the error that ocurred is the following: Fatal error: Call to a member function getGalleyLabel() on a non-object in /home/sicesi/revistas/plugins/reports/views/ on line 135 I dont know why display this error thanks for your help

Hi @christian_criollo,

I bet this is happening because you have stats data in your metrics table related to a galley that was deleted. The report should be prepared to handle this case, and it seems it is not. Can you add this line just before the one that’s causing the rror?

if (!$galley) continue;

Try again after changing that and let us know if you can generate the report then.


thanks beghelli I applied the line suggested and working fine, the question now is when I generated the report with the option view report not displaying stats of the last numbers of the magazine thanks for you help.


Nice it is working now. I will change that into OJS code and the next release should have this fix.

About the report not having the last issue stats data, this is expected. The view report is an old report that used to grab it’s own data. After the stats rework that we did for earlier OJS versions, the view report is only a report template. All new stats data is collected by some other part of the system. Because we are collecting stats slightly different than before, we can’t merge them. So now you have 2 kinds of stats in OJS: the old one and the new one. See here for more details:

In general, all stats reports can work with both stats types. You just have to tell the system which one you want. In your case, the view report uses by default the old stats. The old stats is there so you can still have your older published objects stats data, but this type of stats is not counted anymore. So that’s why you don’t see your newer published objects stats on that report. To use the new stats (since your upgrade to the newer OJS version) you can use this url:


Then you will should have the stats you’re looking for.


thanks beghelli for the answer and your help.