mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
#1660 - Drag to relocate images not working
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@44561 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
15eff6e217
commit
5b2bcd75c2
@ -476,7 +476,7 @@ class File extends DataObject {
|
||||
function getRelativePath() {
|
||||
|
||||
if($this->ParentID) {
|
||||
$p = $this->Parent();
|
||||
$p = DataObject::get_one('Folder', "ID={$this->ParentID}");
|
||||
|
||||
if($p->ID) return $p->getRelativePath() . $this->getField("Name");
|
||||
else return "assets/" . $this->getField("Name");
|
||||
@ -613,4 +613,4 @@ class File extends DataObject {
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user