Files
Umbraco-CMS/src/Umbraco.Web/Models/ContentEditing/CodeFileDisplay.cs
T

48 lines
1.5 KiB
C#
Raw Normal View History

2017-01-09 22:54:28 +01:00
using System;
using System.Collections.Generic;
using System.ComponentModel;
2017-01-09 22:54:28 +01:00
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;
namespace Umbraco.Web.Models.ContentEditing
{
[DataContract(Name = "scriptFile", Namespace = "")]
public class CodeFileDisplay : INotificationModel
2017-01-09 22:54:28 +01:00
{
2017-01-31 11:06:14 +01:00
/// <summary>
/// VirtualPath is the path to the file on disk
/// /views/partials/file.cshtml
/// </summary>
[DataMember(Name = "virtualPath", IsRequired = true)]
2017-01-09 22:54:28 +01:00
public string VirtualPath { get; set; }
2017-01-31 11:06:14 +01:00
/// <summary>
/// Path represents the path used by the backoffice tree
/// For files stored on disk, this is a urlencoded, comma seperated
/// path to the file, always starting with -1.
///
/// -1,Partials,Parials%2FFolder,Partials%2FFolder%2FFile.cshtml
/// </summary>
[DataMember(Name = "path")]
[ReadOnly(true)]
2017-01-30 13:33:05 +01:00
public string Path { get; set; }
[DataMember(Name = "name", IsRequired = true)]
public string Name { get; set; }
[DataMember(Name = "content", IsRequired = true)]
2017-01-09 22:54:28 +01:00
public string Content { get; set; }
[DataMember(Name = "fileType", IsRequired = true)]
public string FileType { get; set; }
2017-01-09 22:54:28 +01:00
[DataMember(Name = "snippet")]
[ReadOnly(true)]
2017-01-09 22:54:28 +01:00
public string Snippet { get; set; }
public List<Notification> Notifications { get; private set; }
2017-01-09 22:54:28 +01:00
}
}