mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 11:05:53 +02:00
42 lines
910 B
PHP
42 lines
910 B
PHP
<?php
|
|
|
|
namespace SilverStripe\Reports\Tests\ReportTest;
|
|
|
|
use SilverStripe\Control\Controller;
|
|
use SilverStripe\Dev\TestOnly;
|
|
use SilverStripe\ORM\CMSPreviewable;
|
|
use SilverStripe\ORM\DataObject;
|
|
|
|
class FakeObject extends DataObject implements CMSPreviewable, TestOnly
|
|
{
|
|
private static $table_name = 'ReportTest_FakeObject';
|
|
|
|
private static $db = array(
|
|
'Title' => 'Varchar'
|
|
);
|
|
|
|
/**
|
|
* @return String Absolute URL to the end-user view for this record.
|
|
* Example: http://mysite.com/my-record
|
|
*/
|
|
public function Link()
|
|
{
|
|
return Controller::join_links('dummy-link', $this->ID);
|
|
}
|
|
|
|
public function CMSEditLink()
|
|
{
|
|
return Controller::join_links('dummy-edit-link', $this->ID);
|
|
}
|
|
|
|
public function PreviewLink($action = null)
|
|
{
|
|
return false;
|
|
}
|
|
|
|
public function getMimeType()
|
|
{
|
|
return 'text/html';
|
|
}
|
|
}
|