public ConsultarObjetosResponse <BloqueioInstrumentoInfo> ConsultarObjetos(OMS.Persistencia.ConsultarObjetosRequest <BloqueioInstrumentoInfo> pParametro) { var lRetorno = new ConsultarObjetosResponse <BloqueioInstrumentoInfo>(); var lAcessaDados = new AcessaDados(); lAcessaDados.ConnectionStringName = "RISCO_GRADUALOMS"; using (DbCommand lDbCommand = lAcessaDados.CreateCommand(CommandType.StoredProcedure, "prc_cliente_bloqueio_instrumento_lst")) { lAcessaDados.AddInParameter(lDbCommand, "@id_cliente", DbType.Int32, pParametro.Condicoes[0].Valores[0]); var lDataTable = lAcessaDados.ExecuteDbDataTable(lDbCommand); if (null != lDataTable && lDataTable.Rows.Count > 0) { for (int i = 0; i < lDataTable.Rows.Count; i++) { lRetorno.Resultado.Add( new BloqueioInstrumentoInfo() { CdAtivo = lDataTable.Rows[i]["cd_ativo"].DBToString(), Direcao = lDataTable.Rows[i]["direcao"].DBToString(), IdCliente = lDataTable.Rows[i][""].DBToInt32(), }); } } } return(lRetorno); }
public OMS.Persistencia.ConsultarObjetosResponse <AssociacaoClienteRiscoInfo> ConsultarObjetos(OMS.Persistencia.ConsultarObjetosRequest <AssociacaoClienteRiscoInfo> lRequest) { ConsultarObjetosResponse <AssociacaoClienteRiscoInfo> lRetorno = new ConsultarObjetosResponse <AssociacaoClienteRiscoInfo>(); try { Dictionary <string, object> parametros = new Dictionary <string, object>(); foreach (CondicaoInfo ci in lRequest.Condicoes) { parametros.Add(ci.Propriedade, ci.Valores[0]); } DataSet ds = _dbLib.ExecutarConsulta("prc_associacao_lst", parametros); for (int i = 0; i < ds.Tables[0].Rows.Count; i++) { lRetorno.Resultado.Add(MontarObjeto(ds.Tables[0].Rows[i])); } return(lRetorno); } catch (Exception ex) { logger.Error(lRequest, ex); throw (ex); } }
public OMS.Persistencia.ConsultarObjetosResponse <BolsaBancoInfo> ConsultarObjetos(OMS.Persistencia.ConsultarObjetosRequest <BolsaBancoInfo> lRequest) { ConsultarObjetosResponse <BolsaBancoInfo> lRetorno = new ConsultarObjetosResponse <BolsaBancoInfo>(); try { DataSet ds = _dbLib.ExecutarProcedure("prc_bolsa_lst", new object[] { }); for (int i = 0; i < ds.Tables[0].Rows.Count; i++) { lRetorno.Resultado.Add(MontarObjeto(ds.Tables[0].Rows[i])); } return(lRetorno); } catch (Exception ex) { logger.Error(lRequest, ex); throw (ex); } }
public OMS.Persistencia.ConsultarObjetosResponse <ClienteLimiteMovimentoInfo> ConsultarMovimentacaoDosLimitesDoCliente(OMS.Persistencia.ConsultarObjetosRequest <ClienteLimiteMovimentoInfo> pParametros) { throw new NotImplementedException(); }