mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
#150 - Pages with similar content
#148 - Stable against restructures (from r87251) git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89174 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
7e54fc1fc2
commit
f84180813f
@ -1321,10 +1321,10 @@ class SiteTree extends DataObject implements PermissionProvider,i18nEntityProvid
|
||||
} else {
|
||||
$this->HasBrokenLink = true;
|
||||
}
|
||||
} else if($link == '' || $link[0] == '/') {
|
||||
$this->HasBrokenLink = true;
|
||||
} else if($candidateFile = File::find(Convert::raw2sql(urldecode($link)))) {
|
||||
$linkedFiles[] = $candidateFile->ID;
|
||||
} else if($link == '' || $link[0] == '/') {
|
||||
$this->HasBrokenLink = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -90,6 +90,11 @@ class File extends DataObject {
|
||||
function TreeTitle() {
|
||||
return $this->Name;
|
||||
}
|
||||
|
||||
// Used by AssetTableField
|
||||
function BackLinkTrackingCount() {
|
||||
return $this->BackLinkTracking()->Count();
|
||||
}
|
||||
|
||||
/**
|
||||
* Event handler called before deleting from the database.
|
||||
|
@ -328,7 +328,7 @@ class Folder extends File {
|
||||
$this,
|
||||
"Files",
|
||||
"File",
|
||||
array("Title" => _t('Folder.TITLE', "Title"), "Filename" => _t('Folder.FILENAME', "Filename")),
|
||||
array("Title" => _t('Folder.TITLE', "Title"), "Filename" => _t('Folder.FILENAME', "Filename")),
|
||||
""
|
||||
);
|
||||
$fileList->setFolder($this);
|
||||
@ -498,4 +498,4 @@ class Folder_UnusedAssetsField extends CompositeField {
|
||||
return $assetList;
|
||||
}
|
||||
}
|
||||
?>
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user