1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-04 01:22:50 -05:00

device apis and models

This commit is contained in:
Kyle Spearrin
2016-06-18 16:03:33 -04:00
parent 25793e0523
commit 4fd65f974d
3 changed files with 152 additions and 0 deletions

View File

@ -0,0 +1,28 @@
using System;
using Bit.Core.Domains;
using Bit.Core.Enums;
namespace Bit.Api.Models
{
public class DeviceResponseModel : ResponseModel
{
public DeviceResponseModel(Device device)
: base("device")
{
if(device == null)
{
throw new ArgumentNullException(nameof(device));
}
Id = device.Id.ToString();
Name = device.Name;
Type = device.Type;
CreationDate = device.CreationDate;
}
public string Id { get; set; }
public string Name { get; set; }
public DeviceType Type { get; set; }
public DateTime CreationDate { get; set; }
}
}