files tree made better.

This commit is contained in:
Paul Schneider 2019-01-01 16:28:47 +00:00
commit ccc91bbf19
1630 changed files with 18209 additions and 41860 deletions

View file

@ -0,0 +1,16 @@
using System.Collections.Generic;
using Microsoft.AspNet.Mvc.Rendering;
namespace Yavsc.ViewModels.Account
{
public class SendCodeViewModel
{
public string SelectedProvider { get; set; }
public ICollection<SelectListItem> Providers { get; set; }
public string ReturnUrl { get; set; }
public bool RememberMe { get; set; }
}
}

View file

@ -0,0 +1,11 @@
using Microsoft.AspNet.Authorization;
namespace Yavsc.ViewModels.Auth
{
public class EditRequirement : IAuthorizationRequirement
{
public EditRequirement()
{
}
}
}

View file

@ -0,0 +1,25 @@
using System.IO;
using Microsoft.AspNet.Authorization;
using Yavsc.Models.Blog;
namespace Yavsc.ViewModel.Auth {
public class FileSpotInfo : IAuthorizationRequirement
{
public DirectoryInfo PathInfo { get; private set; }
public FileSpotInfo(string path, BlogPost b) {
PathInfo = new DirectoryInfo(path);
AuthorId = b.AuthorId;
BlogEntryId = b.Id;
}
public string AuthorId { get; private set; }
public long BlogEntryId { get; private set; }
}
}

View file

@ -0,0 +1,9 @@
using Microsoft.AspNet.Authorization;
namespace Yavsc.ViewModels.Auth
{
public class ModerationRequirement : IAuthorizationRequirement
{
public ModerationRequirement() {}
}
}

View file

@ -0,0 +1,8 @@
using Microsoft.AspNet.Authorization;
namespace Yavsc.ViewModels.Auth
{
public class PrivateChatEntryRequirement : IAuthorizationRequirement
{
}
}

View file

@ -0,0 +1,11 @@
using Microsoft.AspNet.FileProviders;
namespace Yavsc.ViewModels.Auth
{
public class ViewFileContext
{
public string UserName { get; set; }
public IFileInfo File { get; set; }
public string Path { get; set; }
}
}

View file

@ -0,0 +1,11 @@
using Microsoft.AspNet.Authorization;
namespace Yavsc.ViewModels.Auth
{
public class ViewRequirement : IAuthorizationRequirement
{
public ViewRequirement()
{
}
}
}

View file

@ -0,0 +1,38 @@
using System.Linq;
using Yavsc.Models.Workflow;
namespace Yavsc.ViewModels.FrontOffice
{
public class PerformerProfileViewModel
{
public string UserName { get; set; }
public string PerformerId { get; set; }
public bool Active { get; set; }
public bool AcceptNotifications { get; set; }
public bool AcceptPublicContact { get; set; }
public UserActivity Context { get; set; }
public object Settings { get; set; }
public UserActivity[] Extra { get; set; }
public string WebSite { get; set; }
public string SettingsClassName { get; set; }
public PerformerProfileViewModel(PerformerProfile profile, string activityCode, object settings)
{
UserName = profile.Performer.UserName;
PerformerId = profile.PerformerId;
Active = profile.Active;
AcceptNotifications = profile.AcceptNotifications;
AcceptPublicContact = profile.AcceptPublicContact;
Context = profile.Activity.FirstOrDefault(a => a.DoesCode == activityCode);
SettingsClassName = Context.Does.SettingsClassName;
Settings = settings;
WebSite = profile.WebSite;
Extra = profile.Activity.Where(a => a.DoesCode != activityCode).ToArray();
}
}
}

View file

@ -0,0 +1,19 @@
using System.ComponentModel.DataAnnotations;
using Microsoft.AspNet.Mvc.Rendering;
namespace Yavsc.ViewModels.Gen
{
public class PdfGenerationViewModel
{
[Required]
public string TeXSource { get; set; }
[Required]
public string BaseFileName { get; set; }
[Required]
public string DestDir { get; set; }
public bool Generated { get; set; }
public HtmlString GenerationErrorMessage { get; set; }
public string Temp { get; set; }
}
}

View file

@ -0,0 +1,13 @@
using System.ComponentModel.DataAnnotations;
namespace Yavsc.ViewModels.Manage
{
public class ChangeUserNameViewModel
{
[Required]
[Display(Name = "New user name"),RegularExpression(Constants.UserNameRegExp)]
public string NewUserName { get; set; }
}
}

View file

@ -0,0 +1,12 @@
using System.Collections.Generic;
using Microsoft.AspNet.Mvc.Rendering;
namespace Yavsc.ViewModels.Manage
{
public class ConfigureTwoFactorViewModel
{
public string SelectedProvider { get; set; }
public ICollection<SelectListItem> Providers { get; set; }
}
}

View file

@ -0,0 +1,55 @@
using System.Collections.Generic;
using Microsoft.AspNet.Identity;
namespace Yavsc.ViewModels.Manage
{
using Models.Bank;
using Models;
using Models.Workflow;
public class IndexViewModel
{
public string UserName {get; set; }
public string Avatar { get; set; }
public bool HasPassword { get; set; }
public IList<UserLoginInfo> Logins { get; set; }
public string PhoneNumber { get; set; }
public bool TwoFactor { get; set; }
public bool BrowserRemembered { get; set; }
public List<UserActivity> Activity { get; set; }
public bool HaveProfessionalSettings { get; set; }
public bool HaveActivityToConfigure { get; set; }
public long PostsCounter { get; set; }
public AccountBalance Balance { get; set; }
public long ActiveCommandCount { get; set; }
public bool HasDedicatedCalendar { get; set; }
public IEnumerable<string> Roles { get; set; }
public string FullName { get; set; }
public string PostalAddress { get; set; }
public BankIdentity BankInfo { get; set; }
public long DiskQuota { get; set; }
public long DiskUsage { get; set; }
public string DedicatedCalendarId { get; set; }
public string EMail { get; set; }
public bool EmailConfirmed { get; set; }
public bool AllowMonthlyEmail { get; set; }
}
}

View file

@ -0,0 +1,13 @@
using System.Collections.Generic;
using Microsoft.AspNet.Http.Authentication;
using Microsoft.AspNet.Identity;
namespace Yavsc.ViewModels.Manage
{
public class ManageLoginsViewModel
{
public IList<UserLoginInfo> CurrentLogins { get; set; }
public IList<AuthenticationDescription> OtherLogins { get; set; }
}
}

View file

@ -0,0 +1,16 @@
using System.Collections.Concurrent;
using System.Net.WebSockets;
namespace Yavsc.ViewModels.Streaming
{
public class LiveCastClient {
public string UserName { get; set; }
public WebSocket Socket { get; set; }
}
public class LiveCastMeta
{
public WebSocket Socket { get; set; }
public ConcurrentDictionary<string, WebSocket> Listeners { get; set; } = new ConcurrentDictionary<string, WebSocket>();
}
}