/// <summary> /// Gets the registration by email. /// </summary> /// <param name="email">The email.</param> /// <returns></returns> /// <exception cref="System.ApplicationException">Repository GetRegistrationByEmail</exception> public IAgentOfDeduction GetAgentOfDeductionId(int userId) { try { using ( var dbContext = (PitalyticsEntities)dbContextFactory.GetDbContext()) { var aRecord = AccountQueries.GetAgentOfDeductionId(dbContext, userId); return(aRecord); } } catch (Exception e) { throw new ApplicationException("Repository AgentOfDeduction", e); } }