public MV_Exception GuardarDepartamento(TBC_DEPARTAMENTO depto, int idUsuario) { var result = new MV_Exception(); try { result = H_LogErrorEXC.resultToException(_context.SP_TBC_DEPARTAMENTO_INSERT(depto.COD_DEPARTAMENTO, depto.NOMBRE, idUsuario).FirstOrDefault()); if (result.IDENTITY == null) { throw new Exception(result.ERROR_MESSAGE); } } catch (Exception e) { H_LogErrorEXC.GuardarRegistroLogError(e); } return(result); }