31 lines
987 B
C#
31 lines
987 B
C#
using System.ComponentModel.DataAnnotations;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
|
|
namespace Fitness_core_BE.Models
|
|
{
|
|
public class Staff
|
|
{
|
|
[Key]
|
|
public Guid StaffId { get; set; }
|
|
|
|
public Guid FKUserId { get; set; }
|
|
[ForeignKey("FKUserId")]
|
|
public virtual User User { get; set; }
|
|
|
|
public Guid FKClientId { get; set; }
|
|
[ForeignKey("FKClientId")]
|
|
public virtual Client Client { get; set; }
|
|
|
|
// Null = no role assigned yet = zero permissions (see PermissionService).
|
|
public Guid? FKGymRoleId { get; set; }
|
|
[ForeignKey("FKGymRoleId")]
|
|
public virtual GymRole? GymRole { get; set; }
|
|
|
|
public string? StaffPosition { get; set; }
|
|
public string? Department { get; set; }
|
|
public DateTime HireDate { get; set; } = DateTime.UtcNow;
|
|
public bool IsActive { get; set; } = true;
|
|
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
|
}
|
|
}
|