51 lines
No EOL
1.4 KiB
C#
51 lines
No EOL
1.4 KiB
C#
using System;
|
|
using System.Web.Http;
|
|
using ULA.Cathay.CreditoModel.Credito;
|
|
using ULA.Cathay.CreditoModel.DAL.Credito;
|
|
using Ultimus.Utilitarios;
|
|
|
|
namespace ULA.Cathay.Credito.ControllersWebApi.Desembolso
|
|
{
|
|
public class IngresoCaratulaAprobacionUnicaAPIController : ApiController
|
|
{
|
|
UltimusLogs log = new UltimusLogs("IngresoCaratulaAprobacionUnicaAPI");
|
|
|
|
public IngresoCaratulaAprobacionUnicaAPIController()
|
|
{
|
|
GlobalAPIController.SetRegionalConfig();
|
|
}
|
|
|
|
#region ObtenerOferta
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="modelResp"></param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
public Oferta ObtenerOferta(Oferta model)
|
|
{
|
|
Oferta respuesta = new Oferta();
|
|
OfertaDAL ConnOferta = new OfertaDAL();
|
|
|
|
try
|
|
{
|
|
respuesta = ConnOferta.ObtenerOfertaSolicitud(model);
|
|
if (respuesta.IdTipoCategoria == null)
|
|
{
|
|
ConnOferta.CopiarOfertaCaratulaCreditoParaDesembolso(model);
|
|
respuesta = ConnOferta.ObtenerOfertaSolicitud(model);
|
|
}
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
log.Error(ex);
|
|
}
|
|
finally
|
|
{
|
|
ConnOferta = null;
|
|
}
|
|
return respuesta;
|
|
}
|
|
#endregion
|
|
}
|
|
} |