Files
Umbraco-CMS/src/Umbraco.Web.BackOffice/Trees/FilesTreeController.cs
2020-06-11 15:38:12 +02:00

34 lines
1.1 KiB
C#

using Umbraco.Core;
using Umbraco.Core.Hosting;
using Umbraco.Core.IO;
using Umbraco.Core.Logging;
using Umbraco.Core.Services;
using Umbraco.Web.BackOffice.Trees;
using Umbraco.Web.WebApi;
namespace Umbraco.Web.Trees
{
[Tree(Constants.Applications.Settings, "files", TreeTitle = "Files", TreeUse = TreeUse.Dialog)]
[CoreTree]
public class FilesTreeController : FileSystemTreeController
{
protected override IFileSystem FileSystem { get; }
private static readonly string[] ExtensionsStatic = { "*" };
public FilesTreeController(
ILocalizedTextService localizedTextService,
UmbracoApiControllerTypeCollection umbracoApiControllerTypeCollection,
IMenuItemCollectionFactory menuItemCollectionFactory,
IFileSystem fileSystem)
: base(localizedTextService, umbracoApiControllerTypeCollection, menuItemCollectionFactory)
{
FileSystem = fileSystem;
}
protected override string[] Extensions => ExtensionsStatic;
protected override string FileIcon => Constants.Icons.MediaFile;
}
}