This commit is contained in:
2025-12-25 13:54:49 -06:00
parent d405b61ddd
commit 3457721238
26 changed files with 3509 additions and 139 deletions

View File

@@ -0,0 +1,34 @@
using System.ComponentModel.DataAnnotations;
namespace MieSystem.Models
{
public class Asistencia
{
public int Id { get; set; }
public int ExpedienteId { get; set; }
public DateTime Fecha { get; set; }
public string Estado { get; set; } // P, T, F
public TimeSpan? HoraEntrada { get; set; }
public TimeSpan? HoraSalida { get; set; }
public string Observaciones { get; set; }
public DateTime FechaRegistro { get; set; }
public string UsuarioRegistro { get; set; }
// Propiedades calculadas
public string EstadoTexto => Estado switch
{
"P" => "Presente",
"T" => "Tarde",
"F" => "Falto",
_ => "Desconocido"
};
public string ColorEstado => Estado switch
{
"P" => "success",
"T" => "warning",
"F" => "danger",
_ => "secondary"
};
}
}