BotSharp/src/Plugins/BotSharp.Plugin.MongoStorage/Collections/UserDocument.cs
2024-01-31 13:57:54 -06:00

36 lines
983 B
C#

using BotSharp.Abstraction.Users.Models;
namespace BotSharp.Plugin.MongoStorage.Collections;
public class UserDocument : MongoBase
{
public string UserName { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string Email { get; set; }
public string Salt { get; set; }
public string Password { get; set; }
public string Source { get; set; } = "internal";
public string? ExternalId { get; set; }
public string Role { get; set; }
public DateTime CreatedTime { get; set; }
public DateTime UpdatedTime { get; set; }
public User ToUser()
{
return new User
{
Id = Id,
UserName = UserName,
FirstName = FirstName,
LastName = LastName,
Email = Email,
Password = Password,
Salt = Salt,
Source = Source,
ExternalId = ExternalId,
Role = Role
};
}
}