1
0
mirror of https://github.com/bitwarden/server.git synced 2025-06-30 15:42:48 -05:00
Files
bitwarden/src/Core/Models/EntityFramework/Organization.cs
2020-01-10 18:54:44 -05:00

33 lines
795 B
C#

using System.Collections.Generic;
using System.Text.Json;
using AutoMapper;
namespace Bit.Core.Models.EntityFramework
{
public class Organization : Table.Organization
{
private JsonDocument _twoFactorProvidersJson;
public ICollection<Cipher> Ciphers { get; set; }
[IgnoreMap]
public JsonDocument TwoFactorProvidersJson
{
get => _twoFactorProvidersJson;
set
{
TwoFactorProviders = value?.ToString();
_twoFactorProvidersJson = value;
}
}
}
public class OrganizationMapperProfile : Profile
{
public OrganizationMapperProfile()
{
CreateMap<Table.Organization, Organization>().ReverseMap();
}
}
}