mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-09-29 20:59:23 +02:00
API Shift Security page class config to separate option
This commit is contained in:
parent
3f1cda8510
commit
2c274c838e
@ -124,6 +124,14 @@ class Security extends Controller implements TemplateGlobalProvider
|
|||||||
*/
|
*/
|
||||||
private static $template_main = 'Page';
|
private static $template_main = 'Page';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Class to use for page rendering
|
||||||
|
*
|
||||||
|
* @var string
|
||||||
|
* @config
|
||||||
|
*/
|
||||||
|
private static $page_class = 'Page';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Default message set used in permission failures.
|
* Default message set used in permission failures.
|
||||||
*
|
*
|
||||||
@ -515,7 +523,7 @@ class Security extends Controller implements TemplateGlobalProvider
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Use the default setting for which Page to use to render the security page
|
// Use the default setting for which Page to use to render the security page
|
||||||
$pageClass = (string) $this->stat('template_main');
|
$pageClass = $this->stat('page_class');
|
||||||
$tmpPage = new $pageClass;
|
$tmpPage = new $pageClass;
|
||||||
$tmpPage->Title = $title;
|
$tmpPage->Title = $title;
|
||||||
/** @skipUpgrade */
|
/** @skipUpgrade */
|
||||||
|
Loading…
Reference in New Issue
Block a user