using Microsoft.AspNetCore.Identity; using Microsoft.AspNetCore.WebUtilities; using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.Configuration; using MTWorkHR.Application.Identity; using MTWorkHR.Application.Mapper; using MTWorkHR.Application.Models; using MTWorkHR.Core.Global; using MTWorkHR.Core.IRepositories; using MTWorkHR.Core.UnitOfWork; using MTWorkHR.Infrastructure.Entities; using MTWorkHR.Application.Services.Interfaces; using MTWorkHR.Core.Email; using MTWorkHR.Core.Entities; using MTWorkHR.Infrastructure.UnitOfWorks; namespace MTWorkHR.Application.Services { public class AttendanceService : BaseService, IAttendanceService { private readonly IUnitOfWork _unitOfWork; public AttendanceService(IUnitOfWork unitOfWork):base(unitOfWork) { _unitOfWork = unitOfWork; } public override async Task GetById(long id) { var entity = await _unitOfWork.Attendance.GetByIdWithAllChildren(id); var response = MapperObject.Mapper.Map(entity); return response; } } }