mirror of
https://github.com/bitwarden/mobile
synced 2025-12-16 08:13:20 +00:00
initial commit
This commit is contained in:
32
src/App/Models/Data/FolderData.cs
Normal file
32
src/App/Models/Data/FolderData.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using SQLite;
|
||||
using Bit.App.Abstractions;
|
||||
|
||||
namespace Bit.App.Models.Data
|
||||
{
|
||||
[Table("Folder")]
|
||||
public class FolderData : IDataObject<int>
|
||||
{
|
||||
public FolderData()
|
||||
{ }
|
||||
|
||||
public FolderData(Folder folder)
|
||||
{
|
||||
Id = folder.Id;
|
||||
ServerId = folder.ServerId;
|
||||
Name = folder.Name?.EncryptedString;
|
||||
}
|
||||
|
||||
[PrimaryKey]
|
||||
[AutoIncrement]
|
||||
public int Id { get; set; }
|
||||
public string ServerId { get; set; }
|
||||
public string Name { get; set; }
|
||||
public DateTime RevisionDateTime { get; set; } = DateTime.UtcNow;
|
||||
|
||||
public Folder ToFolder()
|
||||
{
|
||||
return new Folder(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user