All checks were successful
CI/CD Pipeline / Build and Deploy with Docker Compose (push) Successful in 6m18s
Quote Demo v1
33 lines
1015 B
C#
33 lines
1015 B
C#
using Core.Interfaces;
|
|
using Domain.Entities;
|
|
using Models.Interfaces;
|
|
using System.Reflection;
|
|
|
|
namespace Core.Services
|
|
{
|
|
public class AdjustmentReasonService:IAdjustmentReasonDom
|
|
{
|
|
#region Declaraciones y Constructor
|
|
private readonly IPhSAdjustmentReasonRepository _repository;
|
|
public AdjustmentReasonService(IPhSAdjustmentReasonRepository repository)
|
|
{
|
|
_repository = repository ?? throw new ArgumentNullException(nameof(repository));
|
|
}
|
|
#endregion
|
|
#region Metodos de clase
|
|
public async Task<IEnumerable<EAdjustmentReason>> GetAllActiveAsync()
|
|
{
|
|
try
|
|
{
|
|
return await _repository.GetAllActiveAsync();
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
var methodName = MethodBase.GetCurrentMethod()?.Name ?? "UnknownMethod";
|
|
throw new Exception($"{methodName} Message: {ex.Message}", ex);
|
|
}
|
|
}
|
|
#endregion
|
|
}
|
|
}
|