mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
When calling Folder::findOrMake(), set the Title as well as the Name of new folders
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.2@64354 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
069c4464ad
commit
26fde80558
@ -30,6 +30,7 @@ class Folder extends File {
|
||||
$item = new Folder();
|
||||
$item->ParentID = $parentID;
|
||||
$item->Name = $part;
|
||||
$item->Title = $part;
|
||||
$item->write();
|
||||
if(!file_exists($item->getFullPath())) mkdir($item->getFullPath(),Filesystem::$folder_create_mask);
|
||||
}
|
||||
@ -37,6 +38,8 @@ class Folder extends File {
|
||||
}
|
||||
return $item;
|
||||
}
|
||||
// To Make SSP Gallery structure work
|
||||
// $item->Title = $part;
|
||||
|
||||
function userCanUse() {
|
||||
if( Member::currentUser()->_isAdmin() )
|
||||
|
Loading…
Reference in New Issue
Block a user