preparing to feed abstract

test should run ok [modulo config]
This commit is contained in:
2018-07-15 06:47:41 +02:00
parent 3505d5aa6c
commit 5f26e97f0a
36 changed files with 766 additions and 244 deletions

View File

@ -1,7 +1,6 @@
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using Microsoft.AspNet.Http.Authentication;
namespace Yavsc.ViewModels.Account
{
@ -49,6 +48,13 @@ namespace Yavsc.ViewModels.Account
/// Lists external identity provider descriptions.
/// </summary>
/// <returns>an enumeration of the descriptions.</returns>
public IEnumerable<AuthenticationDescription> ExternalProviders { get; set; }
public IEnumerable<YaAuthenticationDescription> ExternalProviders { get; set; }
}
public class YaAuthenticationDescription {
public string DisplayName { get; set; }
public string AuthenticationScheme { get; set; }
public IDictionary<string,object> Items { get; set; }
}
}

View File

@ -1,14 +1,14 @@
namespace Yavsc.Models.Auth
{
public class Me : IApplicationUser {
public Me(ApplicationUser user)
public Me(string userId, string userName, string email, string avatar, ILocation address, string gCalId)
{
Id = user.Id;
UserName = user.UserName;
EMail = user.Email;
Avatar = user.Avatar;
PostalAddress = user.PostalAddress;
DedicatedGoogleCalendar = user.DedicatedGoogleCalendar;
Id = userId;
UserName = userName;
EMail = email;
Avatar = avatar;
PostalAddress = address;
DedicatedGoogleCalendar = gCalId;
}
public string Id { get; set; }
public string UserName { get; set; }

View File

@ -1,5 +1,4 @@
using System.Linq;
using Microsoft.AspNet.Identity.EntityFramework;
namespace Yavsc.ViewModels.Administration
{
@ -9,11 +8,11 @@ namespace Yavsc.ViewModels.Administration
{
}
public RoleInfo ( IdentityRole role)
public RoleInfo ( string roleName, string roleId, string[] users)
{
Name = role.Name;
Id = role.Id;
Users = role.Users.Select(u => u.UserId).ToArray();
Name = roleName; // role.Name;
Id = roleId; // role.Id;
Users = users ; // role.Users.Select(u => u.UserId).ToArray();
}
public string Id { get; set; }
public string Name { get; set; }

View File

@ -1,11 +0,0 @@
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

@ -1,55 +0,0 @@
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

@ -1,13 +0,0 @@
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; }
}
}