Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Customising the CMS /

Side Report doesn't show up


Reply


3 Posts   454 Views

Avatar
suntrop

Community Member, 131 Posts

30 July 2013 at 8:02am

I want to create a report to get some specific pages. I just copied the code from http://doc.silverstripe.org/framework/en/reference/site-reports into a file CustomSideReport.php and put it into the code folder. But there is no report with my title there. Just the default reports.

<?php

class CustomSideReport_Test extends SideReport {
public function title() {
return "Test Report";
}

public function records() {
return Page::get()->sort("Title");
}

public function fieldsToShow() {
return array(
"Title" => array("NestedTitle", array("2")),
);
}
}
?>

Avatar
Willr

Forum Moderator, 5513 Posts

11 August 2013 at 6:39pm

This in 3.0, 2.4 or 3.1? 3.* side reports got ditched for just general reports.

Avatar
suntrop

Community Member, 131 Posts

12 August 2013 at 4:58am

Thanks for your answer! I am using 3.0.5. What do you mean by "general reports"? Is the code, I linked in my question, outdated?