first commit

This commit is contained in:
Dhananjaya99
2026-09-28 11:44:26 +05:30
parent 721743ae6b
commit bffc9b1686
424 changed files with 46474 additions and 0 deletions
+33
View File
@@ -0,0 +1,33 @@
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Fitness_core_BE.Models
{
// A persisted, in-app history of pushes sent to a customer (workout/meal plan assigned,
// a gym feed post, etc.) — backs the mobile Notification tab, independent of whether the
// device actually received/displayed the push itself.
public class CustomerNotification
{
[Key]
public Guid CustomerNotificationId { get; set; }
public Guid FKCustomerId { get; set; }
[ForeignKey("FKCustomerId")]
public virtual Customer? Customer { get; set; }
public string Title { get; set; } = string.Empty;
public string Body { get; set; } = string.Empty;
// "WorkoutPlanAssigned" | "MealPlanAssigned" | "FeedPost" — free text, not an enum, so
// new notification kinds don't need a migration.
public string NotificationType { get; set; } = string.Empty;
// Mirrors PushNavigationData's contract in the mobile app's pushNotification.ts, so a
// tap on this notification in the list can navigate the same way a live push would.
public string? RouteName { get; set; }
public string? RouteParamsJson { get; set; }
public bool IsRead { get; set; } = false;
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
}
}