mirror of
https://github.com/C9Glax/tranga.git
synced 2025-02-23 15:50:13 +01:00
17 lines
487 B
C#
17 lines
487 B
C#
using System.ComponentModel.DataAnnotations;
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
namespace API.Schema;
|
|
|
|
[PrimaryKey("NotificationId")]
|
|
public class Notification(string title, string message = "", byte urgency = 2)
|
|
{
|
|
[MaxLength(64)]
|
|
public string NotificationId { get; init; } = TokenGen.CreateToken("Notification", 64);
|
|
|
|
public byte Urgency { get; init; } = urgency;
|
|
|
|
public string Title { get; init; } = title;
|
|
|
|
public string Message { get; init; } = message;
|
|
} |