2019-01-07 12:59:38 +01:00
|
|
|
|
using Umbraco.Core;
|
2016-03-30 16:07:45 +02:00
|
|
|
|
using Umbraco.Core.IO;
|
2017-05-30 18:13:11 +02:00
|
|
|
|
using Umbraco.Web.Composing;
|
2016-03-30 16:07:45 +02:00
|
|
|
|
using Umbraco.Web.Models.Trees;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web.Trees
|
|
|
|
|
|
{
|
2018-10-10 12:24:00 +01:00
|
|
|
|
[CoreTree(TreeGroup = Constants.Trees.Groups.Templating)]
|
2018-10-05 11:51:34 +02:00
|
|
|
|
[Tree(Constants.Applications.Settings, Constants.Trees.Scripts, "Scripts", "icon-folder", "icon-folder", sortOrder: 10)]
|
2016-03-30 16:07:45 +02:00
|
|
|
|
public class ScriptsTreeController : FileSystemTreeController
|
|
|
|
|
|
{
|
2019-01-22 09:49:35 +01:00
|
|
|
|
protected override IFileSystem FileSystem => Current.FileSystems.ScriptsFileSystem; // todo inject
|
2016-03-30 16:07:45 +02:00
|
|
|
|
|
2017-05-12 14:49:44 +02:00
|
|
|
|
private static readonly string[] ExtensionsStatic = { "js" };
|
2016-03-30 16:07:45 +02:00
|
|
|
|
|
2017-05-12 14:49:44 +02:00
|
|
|
|
protected override string[] Extensions => ExtensionsStatic;
|
2016-03-30 16:07:45 +02:00
|
|
|
|
|
2017-05-12 14:49:44 +02:00
|
|
|
|
protected override string FileIcon => "icon-script";
|
2016-03-30 16:07:45 +02:00
|
|
|
|
}
|
|
|
|
|
|
}
|