API Upgrade to SilverStripe\CMS namespace

This commit is contained in:
Damian Mooyman 2016-07-25 10:20:06 +12:00
parent afdae4937e
commit c7387ff45f
4 changed files with 6 additions and 2 deletions

View File

@ -7,6 +7,7 @@ use Injector;
use ClassInfo;
use Convert;
use Object;
use SilverStripe\ORM\Connect\SS_Query;
use SilverStripe\ORM\Queries\SQLConditionGroup;
use SilverStripe\ORM\Queries\SQLSelect;

View File

@ -1,5 +1,6 @@
<?php
use SilverStripe\CMS\Model\SiteTree;
use SilverStripe\ORM\DataModel;
use SilverStripe\ORM\Versioning\Versioned;
/**
@ -467,7 +468,7 @@ class Director implements TemplateGlobalProvider {
* Return the {@link SiteTree} object that is currently being viewed. If there is no SiteTree
* object to return, then this will return the current controller.
*
* @return SiteTree
* @return SiteTree|Controller
*/
public static function get_current_page() {
return self::$current_page ? self::$current_page : Controller::curr();

View File

@ -57,6 +57,7 @@
* `Folder_UnusedAssetsField` is removed.
* `UpgradeSiteTreePermissionSchemaTask` is removed.
* `$action` parameter to `Controller::Link()` method is standardised.
* Removed `UpgradeSiteTreePermissionSchemaTask`
## New API
@ -1001,4 +1002,4 @@ The default `admin/` URL to access the CMS interface can now be changed via a cu
`AdminRootController`. If your website or module has hard coded `admin` URLs in PHP, templates or JavaScript, make sure
to update those with the appropriate function or config call. See
[CMS architecture](/developer_guides/customising_the_admin_interface/cms-architecture#the-admin-url) for language
specific functions.
specific functions.

View File

@ -1,6 +1,7 @@
<?php
use SilverStripe\ORM\FieldType\DBField;
use SilverStripe\ORM\FieldType\DBHTMLText;
/**
* A ViewableData object is any object that can be rendered into a template/view.