WIP Clean Architecture

Windows 8.1 App Uses keepasslib v2.44 (temporarily)
This commit is contained in:
Geoffroy BONNEVILLE
2020-03-24 13:01:14 +01:00
parent 34cd4ca3d8
commit 7e44d47065
290 changed files with 4084 additions and 36416 deletions

View File

@@ -0,0 +1,21 @@
using AutoMapper;
using ModernKeePass.Application.Common.Mappings;
using ModernKeePass.Application.Group.Models;
using ModernKeePass.Domain.Entities;
namespace ModernKeePass.Application.Database.Models
{
public class DatabaseVm: IMapFrom<DatabaseEntity>
{
public bool IsOpen { get; set; }
public string Name { get; set; }
public GroupVm RootGroup { get; set; }
public void Mapping(Profile profile)
{
profile.CreateMap<DatabaseEntity, DatabaseVm>()
.ForMember(d => d.Name, opts => opts.MapFrom(s => s.Name))
.ForMember(d => d.RootGroup, opts => opts.MapFrom(s => s.RootGroupEntity));
}
}
}