feat(notifications): add user-configurable ntfy to
This commit is contained in:
1 parent
2ac2789728
commit
7a89a97bf3
15 files changed
+2310
-22
No files matched your search
@@ -14,6 +14,7 @@ public class UserNotificationConfig : Entity<Guid>, IAuditableEntity
|
||||
public string? EmailAddress { get; private set; }
|
||||
public bool NtfyEnabled { get; private set; }
|
||||
public string? NtfyUrl { get; private set; }
|
||||
public string? NtfyTopic { get; private set; }
|
||||
public string Language { get; private set; } = "fr";
|
||||
public bool DailyDigest { get; private set; }
|
||||
public bool WeeklyDigest { get; private set; }
|
||||
@@ -35,10 +36,12 @@ public class UserNotificationConfig : Entity<Guid>, IAuditableEntity
|
||||
EmailEnabled = enabled;
|
||||
}
|
||||
|
||||
public void UpdateNtfy(string? url, bool enabled)
|
||||
public void UpdateNtfy(string? url, bool enabled, string? topic = null)
|
||||
{
|
||||
NtfyUrl = url;
|
||||
NtfyEnabled = enabled;
|
||||
if (topic is not null)
|
||||
NtfyTopic = topic;
|
||||
}
|
||||
|
||||
public void UpdateDigests(bool daily, bool weekly)
|
||||
|
||||
Reference in new issue
Block a user