mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
Moved callPageMethod to leftandmain, so that I can use it in other CMS controllers
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@40907 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
628105c410
commit
b747f9c42e
@ -1110,15 +1110,6 @@ HTML;
|
|||||||
$page = DataObject::get_by_id("SiteTree", $_REQUEST['ID']);
|
$page = DataObject::get_by_id("SiteTree", $_REQUEST['ID']);
|
||||||
return $page->testInvitation($data,$form);
|
return $page->testInvitation($data,$form);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Use this as an action handler for custom CMS buttons.
|
|
||||||
*/
|
|
||||||
function callPageMethod($data, $form) {
|
|
||||||
$methodName = $form->buttonClicked()->extraData();
|
|
||||||
$record = $this->CurrentPage();
|
|
||||||
return $record->$methodName($data, $form);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Provide the permission codes used by LeftAndMain.
|
* Provide the permission codes used by LeftAndMain.
|
||||||
|
@ -765,6 +765,15 @@ JS;
|
|||||||
function MceRoot() {
|
function MceRoot() {
|
||||||
return MCE_ROOT;
|
return MCE_ROOT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use this as an action handler for custom CMS buttons.
|
||||||
|
*/
|
||||||
|
function callPageMethod($data, $form) {
|
||||||
|
$methodName = $form->buttonClicked()->extraData();
|
||||||
|
$record = $this->CurrentPage();
|
||||||
|
return $record->$methodName($data, $form);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
Loading…
Reference in New Issue
Block a user