api โครงสร้างลูกจ้าง
This commit is contained in:
parent
1c99718a30
commit
25f0fb06c1
25 changed files with 14453 additions and 1 deletions
|
|
@ -0,0 +1,26 @@
|
|||
using BMA.EHR.Application.Common.Interfaces;
|
||||
using BMA.EHR.Domain.Models.MetaData;
|
||||
using BMA.EHR.Domain.Models.OrganizationEmployee;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace BMA.EHR.Application.Repositories
|
||||
{
|
||||
public class OrganizationEmployeeRepository : GenericRepository<Guid, OrgEmployee>
|
||||
{
|
||||
private readonly IApplicationDBContext _dbContext;
|
||||
private readonly IHttpContextAccessor _httpContextAccessor;
|
||||
public OrganizationEmployeeRepository(IApplicationDBContext dbContext, IHttpContextAccessor httpContextAccessor) : base(dbContext, httpContextAccessor)
|
||||
{
|
||||
_dbContext = dbContext;
|
||||
_httpContextAccessor = httpContextAccessor;
|
||||
}
|
||||
|
||||
public async Task<IEnumerable<OrgEmployee>> FindByIdAsync(Guid id)
|
||||
{
|
||||
var data = await _dbContext.Set<OrgEmployee>().Where(x => x.Id == id).ToListAsync();
|
||||
|
||||
return data;
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue