mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 11:05:53 +02:00
BUGFIX Fixed loading of full page template via ajax in CMSPageHistoryController, which causes infinite loops in CMS initialization
This commit is contained in:
parent
d66a47271d
commit
c5323547b8
@ -24,12 +24,11 @@ class CMSPageHistoryController extends CMSMain {
|
||||
* @return array
|
||||
*/
|
||||
function show($request) {
|
||||
$form = $this->ShowVersionForm(
|
||||
$request->param('VersionID')
|
||||
);
|
||||
$form = $this->ShowVersionForm($request->param('VersionID'));
|
||||
|
||||
if($form && $this->isAjax()) {
|
||||
$content = $form->forTemplate();
|
||||
if($this->isAjax()) {
|
||||
if($form) $content = $form->forTemplate();
|
||||
else $content = $this->renderWith($this->getTemplatesWithSuffix('_Content'));
|
||||
} else {
|
||||
$content = $this->customise(array('EditForm' => $form))->renderWith($this->getViewer('show'));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user