Jump to:

5450 Posts in 1672 Topics by 1197 members

Customising the CMS

SilverStripe Forums » Customising the CMS » Side Report doesn't show up

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 266 Views
  • suntrop
    Avatar
    Community Member
    131 Posts

    Side Report doesn't show up Link to this post

    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")),
    );
    }
    }
    ?>

  • Willr
    Avatar
    Forum Moderator
    5464 Posts

    Re: Side Report doesn't show up Link to this post

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

  • suntrop
    Avatar
    Community Member
    131 Posts

    Re: Side Report doesn't show up Link to this post

    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?

    266 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.