77 lines
1.6 KiB
C#
77 lines
1.6 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel.DataAnnotations;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using gehGassi.Domain.Common;
|
|
|
|
namespace gehGassi.Domain.Devices
|
|
{
|
|
/// <summary>
|
|
/// Repräsentiert ein Gerät eines Benutzers.
|
|
/// Konkret ein smartphone, Tablet oder sonstiges
|
|
/// </summary>
|
|
public class Device
|
|
{
|
|
/// <summary>
|
|
/// Eindeutige ID des Devices
|
|
/// </summary>
|
|
[Key]
|
|
[Required]
|
|
public long Id { get; set; }
|
|
|
|
/// <summary>
|
|
/// Id des App-Users dem das Device gehört
|
|
/// </summary>
|
|
[Required]
|
|
[MaxLength(128)]
|
|
public string AppUserId { get; set; }
|
|
|
|
/// <summary>
|
|
/// Eindeutige ID des Devices
|
|
/// </summary>
|
|
[Required]
|
|
[MaxLength(128)]
|
|
public string InstallationId { get; set; }
|
|
|
|
/// <summary>
|
|
/// Platform des Devices
|
|
/// </summary>
|
|
[Required]
|
|
public Platform Platform { get; set; }
|
|
|
|
/// <summary>
|
|
/// Notification-Platform die verwendet werden soll
|
|
/// </summary>
|
|
[Required]
|
|
public NotificationPlatform NotificationPlatform { get; set; }
|
|
|
|
/// <summary>
|
|
/// Welcher Pushnotification-Channel wurde gebucht
|
|
/// </summary>
|
|
[Required]
|
|
[MaxLength(512)]
|
|
public string Channel { get; set; }
|
|
|
|
/// <summary>
|
|
/// Eingestellte Sprache des Devices
|
|
/// </summary>
|
|
[Required]
|
|
[MaxLength(2)]
|
|
public string Language { get; set; }
|
|
|
|
/// <summary>
|
|
/// Datum der Erstellung
|
|
/// </summary>
|
|
[Required]
|
|
public DateTimeOffset Created { get; set; }
|
|
|
|
/// <summary>
|
|
/// Datum der letzten Aktualisierung
|
|
/// </summary>
|
|
[Required]
|
|
public DateTimeOffset LastUpdate { get; set; }
|
|
}
|
|
}
|