mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-01 05:39:10 +02:00
BUGFIX Moved SiteTree?->ParentID property to Hierarchy extension (fixes #5638) (from r105668)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@105786 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
06f18485a9
commit
53b02f6d99
@ -25,6 +25,15 @@ class Hierarchy extends DataObjectDecorator {
|
|||||||
function augmentWrite(&$manipulation) {
|
function augmentWrite(&$manipulation) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function extraStatics($class = null) {
|
||||||
|
return array(
|
||||||
|
'has_one' => array(
|
||||||
|
// TODO this method is called *both* statically and on an instance
|
||||||
|
"Parent" => ($class) ? $class : $this->owner->class
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the children of this DataObject as an XHTML UL. This will be called recursively on each child,
|
* Returns the children of this DataObject as an XHTML UL. This will be called recursively on each child,
|
||||||
* so if they have children they will be displayed as a UL inside a LI.
|
* so if they have children they will be displayed as a UL inside a LI.
|
||||||
|
@ -123,10 +123,6 @@ class SiteTree extends DataObject implements PermissionProvider,i18nEntityProvid
|
|||||||
"CanEditType" => "Inherit"
|
"CanEditType" => "Inherit"
|
||||||
);
|
);
|
||||||
|
|
||||||
static $has_one = array(
|
|
||||||
"Parent" => "SiteTree"
|
|
||||||
);
|
|
||||||
|
|
||||||
static $versioning = array(
|
static $versioning = array(
|
||||||
"Stage", "Live"
|
"Stage", "Live"
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user