diff --git a/code/StatisticsAdmin.php b/code/StatisticsAdmin.php index f0c5a5a4..5c615e07 100644 --- a/code/StatisticsAdmin.php +++ b/code/StatisticsAdmin.php @@ -27,6 +27,22 @@ class StatisticsAdmin extends LeftAndMain { ) ); } + + public function versions() { + /*$pageID = $this->urlParams['ID']; + //$pageID = "1"; + $page = $this->getRecord($pageID); + if($page) { + $versions = $page->allVersions($_REQUEST['unpublished'] ? "" : "`SiteTree_versions`.WasPublished = 1"); + return array( + 'Versions' => $versions, + ); + } else { + return "Can't find page #$pageID"; + }*/ + + } + } ?> diff --git a/templates/Includes/StatisticsAdmin_left.ss b/templates/Includes/StatisticsAdmin_left.ss index 37ed6323..d0cbc734 100644 --- a/templates/Includes/StatisticsAdmin_left.ss +++ b/templates/Includes/StatisticsAdmin_left.ss @@ -2,5 +2,58 @@
+ <% if Items %> + + <% end_if %>
+ +

Page Version History

+
+

+

+ +
+ + + + + + + + + + + <% control versions %> + + + + + + + <% end_control %> + +
#WhenAuthorPublisher
$Version$LastEdited.Nice$Author.FirstName $Author.Surname.Initial + <% if Published %> + <% if Publisher %> + $Publisher.FirstName $Publisher.Surname.Initial + <% else %> + Unknown + <% end_if %> + <% else %> + Not published + <% end_if %> +
+
+
+
diff --git a/templates/Includes/StatisticsAdmin_right.ss b/templates/Includes/StatisticsAdmin_right.ss index 815d8d7b..8d4fbc13 100644 --- a/templates/Includes/StatisticsAdmin_right.ss +++ b/templates/Includes/StatisticsAdmin_right.ss @@ -3,7 +3,9 @@ <% if EditForm %> $EditForm <% else %> -

Welcome to the $ApplicationName statistics section. Please choose a specific report from the left.

+
+

Welcome to the $ApplicationName statistics section. Please choose a specific report from the left.

+
<% end_if %>