/// <inheritdoc /> async Task <IDictionaryRange <string, Objective> > IRepository <string, Objective> .FindAllAsync(ICollection <string> identifiers, CancellationToken cancellationToken) { IObjectiveRepository self = this; var request = new ObjectiveBulkRequest { Culture = self.Culture, Identifiers = identifiers }; var response = await this.serviceClient.SendAsync <ICollection <ObjectiveDTO> >(request); if (response.Content == null) { return(new DictionaryRange <string, Objective>(0)); } var values = response.Content.Select(value => this.objectiveConverter.Convert(value, null)).ToList(); var objectives = new DictionaryRange <string, Objective>(values.Count) { SubtotalCount = values.Count, TotalCount = values.Count }; foreach (var objective in values) { objective.Culture = request.Culture; objectives.Add(objective.ObjectiveId, objective); } return(objectives); }
public ObjectivesService(IObjectiveRepository objectiveRepository, IListingRepository listingRepository, IUnitOfWork unitOfWork) : this(new AppUserManager(new UserStore<AppUser>(unitOfWork.DbContext))) { this.objectiveRepository = objectiveRepository; this.listingRepository = listingRepository; this.unitOfWork = unitOfWork; userName = ""; }
public ObjectivesService(IObjectiveRepository objectiveRepository, IListingRepository listingRepository, ISiteRepository siteRepository, IUnitOfWork unitOfWork) : this(new AppUserManager(new UserStore <AppUser>(unitOfWork.DbContext))) { this.objectiveRepository = objectiveRepository; this.listingRepository = listingRepository; this.siteRepository = siteRepository; this.unitOfWork = unitOfWork; userName = ""; }
public ApiService(IAuctionRepository auctionRepository, IUserRepository userRepository, IListingRepository listingRepository, IObjectiveRepository objectiveRepository, ISiteRepository siteRepository, IUnitOfWork unitOfWork) : this(new AppUserManager(new UserStore <AppUser>(unitOfWork.DbContext))) { this.auctionRepository = auctionRepository; this.userRepository = userRepository; this.listingRepository = listingRepository; this.objectiveRepository = objectiveRepository; this.siteRepository = siteRepository; this.unitOfWork = unitOfWork; }
public AddObjectiveCommandHandler( IObjectiveFactory objectiveFactory, IObjectiveRepository objectiveRepository, IUnitOfWork unitOfWork) { _objectiveFactory = objectiveFactory ?? throw new ArgumentNullException(nameof(objectiveFactory)); _objectiveRepository = objectiveRepository ?? throw new ArgumentNullException(nameof(objectiveRepository)); _unitOfWork = unitOfWork ?? throw new ArgumentNullException(nameof(unitOfWork)); }
public UserService(IListingRepository listingRepository, IUserRepository userRepository, IPrizeRepository prizeRepository, IGiveawayRepository giveawayRepository, IAuctionRepository auctionRepository, IObjectiveRepository objectiveRepository, IUnitOfWork unitOfWork) : this(new AppUserManager(new UserStore <AppUser>(unitOfWork.DbContext))) { this.listingRepository = listingRepository; this.userRepository = userRepository; this.prizeRepository = prizeRepository; this.giveawayRepository = giveawayRepository; this.auctionRepository = auctionRepository; this.objectiveRepository = objectiveRepository; this.unitOfWork = unitOfWork; userName = ""; }
public UserService(IListingRepository listingRepository, IUserRepository userRepository, IPrizeRepository prizeRepository, IGiveawayRepository giveawayRepository, IAuctionRepository auctionRepository, IObjectiveRepository objectiveRepository, IUnitOfWork unitOfWork) : this(new AppUserManager(new UserStore<AppUser>(unitOfWork.DbContext))) { this.listingRepository = listingRepository; this.userRepository = userRepository; this.prizeRepository = prizeRepository; this.giveawayRepository = giveawayRepository; this.auctionRepository = auctionRepository; this.objectiveRepository = objectiveRepository; this.unitOfWork = unitOfWork; userName = ""; }
public EventRepository(Angular2_AspDotNet.Data.UnitOfWork.UnitOfWork unitOfWork) : base(unitOfWork.Context) { this._unitOfWork = unitOfWork; _IEventAttendeeRepository = new EventAttendeeRepository(this._unitOfWork); _IActionRepository = new ActionRepository(this._unitOfWork); _IActionResponsiblePersonRepository = new ActionResponsiblePersonRepository(this._unitOfWork); _IAgendaRepository = new AgendaRepository(this._unitOfWork); this._IAppointmentRepository = new AppointmentRepository(this._unitOfWork); this._IObjectiveRepository = new ObjectiveRepository(this._unitOfWork); this._IPerformanceReviewRepository = new PerformanceReviewRepository(this._unitOfWork); this._IRoleResponsibilityRepository = new RoleResponsibilityRepository(this._unitOfWork); }
public UnitOfWork( BlazorAppDbContext context, IObjectiveRepository objectiveRepository, IQuestionRepository questionRepository, IRespondentRepository respondentRepository, IResultRepository resultRepository) { _context = context; Objectives = objectiveRepository; Questions = questionRepository; Respondents = respondentRepository; Results = resultRepository; }
public PDRService(IUserRepository userRepository, IPDReviewRepository pdReview, IObjectiveRepository objective, IObjectiveTypeRepository objectiveType, ISuccessFactorRepository sucfact, ISuccessFactorTypeRepository sucfacType, IPDRStatusRepository pdrSt, IRatingTypeRepository ratTypeerep, IRatingRepository rateRep, IPersonalDevelopmentPlanRepository pdpRep, IDevelopmentCategoryRepository devcat, IHRProPersonnelRecordRepository hrPro, IUnitOfWork unitOfWork) { this._UserRepository = userRepository; this._PDRReviewRepository = pdReview; this._ObjectiveRepository = objective; this._ObjectiveTyperepository = objectiveType; this.unitOfWork = unitOfWork; this._PDRStatusRepository = pdrSt; this._Ratingrepository = rateRep; this._RatingTypeRepository = ratTypeerep; this._SuccessFactorRepository = sucfact; this._SuccessFactorTypeRepository = sucfacType; this._IPersonalDevelopmentPlanRepository = pdpRep; this._IDevelopmentCategoryRepository = devcat; this._IHRProPersonnelRecordRepository = hrPro; }
/// <inheritdoc /> async Task <Objective> IRepository <string, Objective> .FindAsync(string identifier, CancellationToken cancellationToken) { IObjectiveRepository self = this; var request = new ObjectiveDetailsRequest { Culture = self.Culture, Identifier = identifier }; var response = await this.serviceClient.SendAsync <ObjectiveDTO>(request, cancellationToken); if (response.Content == null) { return(null); } var result = this.objectiveConverter.Convert(response.Content, null); result.Culture = self.Culture; return(result); }
/// <inheritdoc /> Objective IRepository <string, Objective> .Find(string identifier) { IObjectiveRepository self = this; var request = new ObjectiveDetailsRequest { Culture = self.Culture, Identifier = identifier }; var response = this.serviceClient.Send <ObjectiveDTO>(request); if (response.Content == null) { return(null); } var result = this.objectiveConverter.Convert(response.Content, null); result.Culture = self.Culture; return(result); }
public UnitOfWork(ChallengifierEntities1 dbContext, IMilestoneRepository milestoneRepository, IChallengeRepository challengeRepository, IObjectiveRepository objectiveRepository, IPictureRepository pictureRepository, IPlanningStepRepository planningStepRepository, IUserRankRepository userRankRepository, IUserRatingRepository userRatingRepository, IUserRepository userRepository) { this.dbContext = dbContext; this.MilestoneRepository = milestoneRepository; this.ChallengeRepository = challengeRepository; this.ObjectiveRepository = objectiveRepository; this.PictureRepository = pictureRepository; this.PlanningStepRepository = planningStepRepository; this.UserRankRepository = userRankRepository; this.UserRatingRepository = userRatingRepository; this.UserRepository = userRepository; transaction = dbContext.Database.BeginTransaction(); }
/// <inheritdoc /> Task <ICollection <string> > IDiscoverable <string> .DiscoverAsync() { IObjectiveRepository self = this; return(self.DiscoverAsync(CancellationToken.None)); }
/// <inheritdoc /> Task <Objective> IRepository <string, Objective> .FindAsync(string identifier) { IObjectiveRepository self = this; return(self.FindAsync(identifier, CancellationToken.None)); }
public ObjectiveApplicationService(IObjectiveRepository repository, IMarkApplicationService serviceMark, IUnitOfWork unitOfWork) : base(unitOfWork) { this._repository = repository; this._serviceMark = serviceMark; }
/// <inheritdoc /> Task <IDictionaryRange <string, Objective> > IRepository <string, Objective> .FindAllAsync(ICollection <string> identifiers) { IObjectiveRepository self = this; return(self.FindAllAsync(identifiers, CancellationToken.None)); }
/// <inheritdoc /> Task <IDictionaryRange <string, Objective> > IRepository <string, Objective> .FindAllAsync(CancellationToken cancellationToken) { IObjectiveRepository self = this; return(self.FindAllAsync(null, cancellationToken)); }
public void Dispose() { _repository = null; }
/// <inheritdoc /> IDictionaryRange <string, Objective> IRepository <string, Objective> .FindAll() { IObjectiveRepository self = this; return(self.FindAll(null)); }