feat: enhance models and services with Sendable conformance, add preview data for debugging

This commit is contained in:
2026-03-14 07:18:35 +07:00
parent a4b475b13f
commit 758f5ec05f
17 changed files with 851 additions and 198 deletions
+4 -4
View File
@@ -1,6 +1,6 @@
import Foundation
struct AppNotification: Codable, Identifiable {
struct AppNotification: Codable, Identifiable, Sendable {
let id: UUID
let topic: String
let subject: String
@@ -22,19 +22,19 @@ struct AppNotification: Codable, Identifiable {
var isRead: Bool { readAt != nil }
}
enum NotificationStatus: String, Codable {
enum NotificationStatus: String, Codable, Sendable {
case sent
case delivered
case read
}
enum NotificationChannel: String, Codable {
enum NotificationChannel: String, Codable, Sendable {
case inApp = "in_app"
case push
case email
}
struct NotificationsPage: Codable {
struct NotificationsPage: Codable, Sendable {
let items: [AppNotification]
let total: Int
let page: Int