Ejemplo n.º 1
0
        /// <summary>
        ///     Metodo que crear un Costo
        /// </summary>
        /// <param name="info"></param>
        internal int Crear(CostoInfo info)
        {
            int infoId;

            try
            {
                Logger.Info();
                Dictionary <string, object> parameters = AuxCostoDAL.ObtenerParametrosGuardado(info);
                infoId = Create("[dbo].[Costo_Crear]", parameters);
            }
            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(infoId);
        }