hrms-api-backend/BMA.EHR.Infrastructure/Persistence/LeaveDbContext.cs

37 lines
900 B
C#
Raw Normal View History

using BMA.EHR.Application.Common.Interfaces;
using BMA.EHR.Domain.Models.Leave.TimeAttendants;
using Microsoft.EntityFrameworkCore;
namespace BMA.EHR.Infrastructure.Persistence
{
public class LeaveDbContext : DbContext, ILeaveDbContext
{
#region " Check-In "
public DbSet<DutyTime> DutyTimes { get; set; }
public DbSet<UserTimeStamp> UserTimeStamps { get; set; }
2023-11-23 10:35:55 +07:00
public DbSet<ProcessUserTimeStamp> ProcessUserTimeStamps { get; set; }
public DbSet<UserDutyTime> UserDutyTimes { get; set; }
#endregion
public LeaveDbContext(DbContextOptions<LeaveDbContext> options) : base(options)
{
}
public Task<int> SaveChangesAsync()
{
return base.SaveChangesAsync();
}
public void Attatch<T>(T entity) where T : class
{
Attach(entity);
}
}
}