/// <summary> /// Obtiene el costo por id /// </summary> /// <param name="costo"></param> /// <returns></returns> internal CostoInfo ObtenerCostoPorID(CostoInfo costo) { CostoInfo result = null; try { Logger.Info(); Dictionary <string, object> parameters = AuxCostoDAL.ObtenerParametroCostoPorID(costo); DataSet ds = Retrieve("[dbo].[Costo_ObtenerPorID]", parameters); if (ValidateDataSet(ds)) { result = MapCostoDAL.ObtenerCostoPorID(ds); } } catch (SqlException ex) { Logger.Error(ex); throw new ExcepcionServicio(MethodBase.GetCurrentMethod(), ex); } catch (DataException ex) { Logger.Error(ex); throw new ExcepcionServicio(MethodBase.GetCurrentMethod(), ex); } catch (Exception ex) { Logger.Error(ex); throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex); } return(result); }