mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 11:05:53 +02:00
ENHANCMENT: Link pages in reports to cms edit
This commit is contained in:
parent
8df5cd74fc
commit
9888f980aa
@ -170,6 +170,11 @@ class ReportAdmin extends LeftAndMain implements PermissionProvider {
|
|||||||
if(isset($info['csvFormatting'])) $csvFieldFormatting[$source] = $info['csvFormatting'];
|
if(isset($info['csvFormatting'])) $csvFieldFormatting[$source] = $info['csvFormatting'];
|
||||||
if(isset($info['casting'])) $fieldCasting[$source] = $info['casting'];
|
if(isset($info['casting'])) $fieldCasting[$source] = $info['casting'];
|
||||||
|
|
||||||
|
if(isset($info['link']) && $info['link']) {
|
||||||
|
$link = singleton('CMSPageEditController')->Link('show');
|
||||||
|
$fieldFormatting[$source] = '<a href=\"' . $link . '/$ID\">$value</a>';
|
||||||
|
}
|
||||||
|
|
||||||
$displayFields[$source] = isset($info['title']) ? $info['title'] : $source;
|
$displayFields[$source] = isset($info['title']) ? $info['title'] : $source;
|
||||||
}
|
}
|
||||||
$gridField->setDisplayFields($displayFields);
|
$gridField->setDisplayFields($displayFields);
|
||||||
|
Loading…
Reference in New Issue
Block a user