/// <summary> /// Implementacion nucleo de la interfaz de la capa DominioServicios /// </summary> /// <param name="strCredencial"></param> /// <param name="oListarPersona"></param> /// <param name="strMensajeError"></param> /// <returns></returns> public List <O_LISTAR_PERSONA> ListarPersona(string strCredencial, O_LISTAR_PERSONA oListarPersona, ref string strMensajeError) { using (var ctx = new EntidadesSisReservas()) { try { var objListado = ctx.PGET_LISTADOS_P_LISTAR_PERSONA(strCredencial, oListarPersona.ID_PERSONA, oListarPersona.ID_TIPO_PERSONA, oListarPersona.TIPO_PERSONA, oListarPersona.ID_GENERO, oListarPersona.GENERO, oListarPersona.NOMBRE, oListarPersona.AP_PATERNO, oListarPersona.AP_MATERNO, oListarPersona.FECHA_NACIMIENTO, oListarPersona.DIRECCION, oListarPersona.EMAIL, oListarPersona.APP_ID_USUARIO, oListarPersona.AUD_ESTADO, oListarPersona.FECHA_REGISTRO ).ToList(); return(objListado); } catch (Exception ex) { strMensajeError = "Error 200: " + ex.Message + "-" + ex.InnerException; return(null); } } }
public List <O_RESULTADO> RegistrarPersona(string strCredencial, O_LISTAR_PERSONA oPersona, ref string strMensajeError) { using (var ctx = new EntidadesSisReservas()) { try { var objResultado = ctx.PGET_GESTION_P_REGISTRAR_PERSONA(strCredencial, oPersona.ID_PERSONA, oPersona.ID_TIPO_PERSONA, oPersona.ID_GENERO, oPersona.NOMBRE, oPersona.AP_PATERNO, oPersona.AP_MATERNO, oPersona.FECHA_NACIMIENTO, oPersona.DIRECCION, oPersona.EMAIL, oPersona.APP_ID_USUARIO, oPersona.AUD_ESTADO, oPersona.FECHA_REGISTRO ).ToList(); return(objResultado); } catch (Exception ex) { strMensajeError = "CPersistenciaRepositorio " + ex.Message + " " + ex.InnerException; return(null); } } }
public void registrarPersona(string nombre, decimal documento, decimal genero, decimal tipoPersona) { try { var oPersona = new O_LISTAR_PERSONA(); oPersona.NOMBRE = nombre; oPersona.ID_GENERO = Convert.ToDecimal(genero); oPersona.ID_TIPO_PERSONA = tipoPersona; oPersona.AUD_ESTADO = 1; var strMensajeError = ""; var rstRegistroPersona = servicioGestion.RegistrarPersona(strCredencial, oPersona, ref strMensajeError); if (rstRegistroPersona == null || rstRegistroPersona[0].ID_TABLA < 0) { throw new Exception(rstRegistroPersona == null ? "No se registro la persona" : rstRegistroPersona[0].MENSAJE_ERROR); } else { var idUltimaPersona = rstRegistroPersona[0].ID_TABLA; var oDocumento = new O_LISTAR_DOCUMENTO(); oDocumento.ID_TIPO_DOCUMENTO = documento; oDocumento.ID_PERSONA = idUltimaPersona; var rstDocumento = servicioGestion.RegistrarDocumento(strCredencial, oDocumento, ref strMensajeError); } } catch (Exception ex) { throw new Exception("Error 600: " + ex.Message); } }
public List <O_RESULTADO> RegistrarPersona(string strCredencial, O_LISTAR_PERSONA oPersona, ref string strMensajeError) { try { return(_repositorioGestion.RegistrarPersona(strCredencial, oPersona, ref strMensajeError).ToList()); } catch (Exception ex) { strMensajeError = "Aplicacion Error " + System.Reflection.MethodBase.GetCurrentMethod().Name + "Error: " + ex.InnerException; return(null); } }
public List <O_LISTAR_PERSONA> ListarPersona(string strCredencial, O_LISTAR_PERSONA oListarPersona, ref string strMensajeError) { try { var _servicio = FabricaIoC.Contenedor.Resolver <IAplicacionReportes>(); return(_servicio.ListarPersona(strCredencial, oListarPersona, ref strMensajeError).ToList()); } catch (Exception e) { strMensajeError += e.Message + " error 500: " + e.InnerException; return(null); } }
public List <O_RESULTADO> RegistrarPersona(string strCredencial, O_LISTAR_PERSONA oPersona, ref string strMensajeError) { try { var _servicio = FabricaIoC.Contenedor.Resolver <IAplicacionGestion>(); return(_servicio.RegistrarPersona(strCredencial, oPersona, ref strMensajeError)); } catch (Exception e) { strMensajeError += e.Message + " - " + e.InnerException; return(null); } }
public List <O_LISTAR_PERSONA> ListarPersona(string strCredencial, O_LISTAR_PERSONA oListarPersona, ref string strMensajeError) { try { var objListado = _repositorioReportes.ListarPersona(strCredencial, oListarPersona, ref strMensajeError); return(objListado); } catch (Exception ex) { strMensajeError = "CAplicacionListados: method ListarFeriados(...)" + System.Reflection.MethodBase.GetCurrentMethod().Name + "Error 300:" + ex.Message + '-' + ex.InnerException; return(null); } }