public WorkingDaysLeftController(
            WorkingDaysLeftViewModel leftViewModel,
            WorkingDaysLeftSettingsViewModel settingsViewModel,
            IAsyncRepository<ProjectInfoServer> projectInforepository,
            IAsyncRepository<Holiday> holidayRepository,
            ITimer refreshNotifier,
            ILog logger,
            IProgressbar loadingNotifier,
            Configuration config)
        {
            this.leftViewModel = leftViewModel;
            this.settingsViewModel = settingsViewModel;
            this.holidayRepository = holidayRepository;
            this.projectInforepository = projectInforepository;
            this.logger = logger;
            this.loadingNotifier = loadingNotifier;
            this.refreshNotifier = refreshNotifier;

            this.Rand = new Random((int)DateTime.Now.Ticks).Next();

            projectInforepository.GetCompleted += GotProjectInfo;
            holidayRepository.GetCompleted += GotHolidays;

            this.settingsViewModel.RefreshAvailableServers.ExecuteDelegate = OnRefreshAvailableServers;
            this.settingsViewModel.ReloadSettings.ExecuteDelegate = settingsViewModel.Reset;

            refreshNotifier.Elapsed += refreshNotifier_Elapsed;
            settingsViewModel.PropertyChanged += RefreshAvailableProjectsWhenSelectedServerChanges;
            refreshNotifier.Start(10000);

            OnRefreshAvailableServers();
            SetConfigAndUpdate(config);
        }
        public CustomersController(IAsyncRepository<Customer> repo, IAuthoriseAccessToData<Customer> dataAccessAuthoriser, AutoResolveContext db) : base(db)
        {
            __loggingResourceName = "Customer";
            _repo = repo;
            _dataAccessAuthoriser = dataAccessAuthoriser;

        }
 public NotificationsController() : base()
 {
     __loggingResourceName = "Notification";
     _repo = new NotificationsAsyncRepository(_db);
     customerRepo = new CustomerAsyncRepository(_db);
     accidentRepo = new AccidentAsyncRepository(_db);
     otherDriversRepo = new OtherDriverAsyncRepository(_db);
     _dataAccessAuthoriser = new AuthoriseCustomerDataAccess(_db);
 }
Esempio n. 4
0
 public ConfigurationManager(ITimer timer, IAsyncRepository<Configuration> asyncRepository)
 {
     this.timer = timer;
     timer.Start(REFRESH_INTERVAL_SECONDS * 1000);
     this.asyncRepository = asyncRepository;
     this.asyncRepository.GetCompleted += asyncRepository_GetCompleted;
     timer.Elapsed += timer_Elapsed;
     BeginGetConfigurations();
     
 }
        public NotificationsController(IAsyncRepository<ExternalNotification> repo, IAuthoriseAccessToData<Customer> dataAccessAuthoriser, AutoResolveContext db) : base(db)
        {
            __loggingResourceName = "Notification";
            _db = db;
            _repo = repo;
            customerRepo = new CustomerAsyncRepository(_db);
            accidentRepo = new AccidentAsyncRepository(_db);
            otherDriversRepo = new OtherDriverAsyncRepository(_db);
            _dataAccessAuthoriser = dataAccessAuthoriser;

        }
Esempio n. 6
0
 public UnitOfWork(
     IDbContext context,
     IAsyncRepository<User> usersRepository, 
     IAsyncRepository<HaikuEntity> haikusRepository,
     IAsyncRepository<Report> reportsRepository,
     IAsyncRepository<HaikuRating> ratingsRepository)
 {
     this.context = context;
     this.usersRepository = usersRepository;
     this.haikusRepository = haikusRepository;
     this.reportsRepository = reportsRepository;
     this.ratingsRepository = ratingsRepository;
 }
Esempio n. 7
0
    	public ModuleLoader(IAsyncRepository<SlideConfiguration> slideConfigRepo, 
			IAsyncRepository<WidgetMetadata> widgetMetadataRepo,
			ILog logger)
        {
    		Guard.Requires<ArgumentNullException>(slideConfigRepo != null);
			Guard.Requires<ArgumentNullException>(widgetMetadataRepo != null);
			Guard.Requires<ArgumentNullException>(logger != null);

            this.slideConfigRepo = slideConfigRepo;
            this.logger = logger;
			this.widgetMetadataRepo = widgetMetadataRepo;

			widgetMetadataRepo.GetCompleted += widgetMetadataRepo_GetCompleted;
        }
        public SelectWidgetsDialogController(
            SelectWidgetsDialog viewModel, 
            IAsyncRepository<WidgetMetadata> repository, 
            IPersistDomainModelsAsync<SlideConfiguration> slideConfigPersister)
        {
            Guard.Requires<ArgumentNullException>(viewModel != null);
            Guard.Requires<ArgumentNullException>(repository != null);
            Guard.Requires<ArgumentNullException>(slideConfigPersister != null);
            
            this.viewModel = viewModel;
            this.repository = repository;
            this.slideConfigPersister = slideConfigPersister;

            this.slideConfigPersister.SaveCompleted += slideConfigPersister_SaveCompleted;

            repository.GetCompleted += repository_GetCompleted;

            BeginGetWidgetMetadata();
        }
        public SchoolUow(DbContext context,
                         ICoursesRepository courses,
                         IAsyncRepository<Department> departments,
                         IStudentsRepository students,
                         IInstructorsRepository instructors,
                         IEnrollmentsRepository enrollments,
                         IRepository<OfficeAssignment> offices)
        {
            _dbContext = context;

            _dbContext.Configuration.LazyLoadingEnabled = false;
            
            _courses = courses;
            _departments = departments;
            _students = students;
            _instructors = instructors;
            _enrollments = enrollments;
            _offices = offices;
        }
        public WorkingDaysLeftRxController(
            WorkingDaysLeftViewModel viewModel, 
            WorkingDaysLeftSettingsViewModel settingsViewModel,
            IAsyncRepository<ProjectInfoServer> projectInforepository,
            IAsyncRepository<Configuration> configRepository,
            IAsyncRepository<Holiday> holidayRepository, 
            IPersistDomainModels<Configuration> configPersisterRepository,
            ITimer refreshNotifier,
            ILog logger)
        {
            _viewModel = viewModel;
            _settingsViewModel = settingsViewModel;
            this._holidayRepository = holidayRepository;
            this._projectInforepository = projectInforepository;
            this._logger = logger;
            this._configRepository = configRepository;
            this._configPersisterRepository = configPersisterRepository;

            SetupReactiveEvents();
        }
Esempio n. 11
0
 public Connect(IAsyncRepository <RemoteAccount> accountRepository, IMapper mapper, IEmailNotificationService emailNotificationService)
 {
     _accountRepository        = accountRepository;
     _mapper                   = mapper;
     _emailNotificationService = emailNotificationService;
 }
 public CustomerReviewController(IAsyncRepository <CustomerReview> repo, ILogger <CustomerReviewController> logger, IMapper mapper, DataContext context)
     : base(repo, logger, mapper, context)
 {
 }
Esempio n. 13
0
 public GetAppointmentsListQueryHandler(IMapper mapper, IAsyncRepository <Appointment> appointmentRepository)
 {
     _mapper = mapper;
     _appointmentRepository = appointmentRepository;
 }
Esempio n. 14
0
 public ImageCapilarController(ILogger <ImageCapilarController> logger, IAsyncRepository <ImageCapilar> ImageCapilarAsyncRepository, IUnitOfWork unitOfWork)
 {
     _logger = logger;
     this._ImageCapilarAsyncRepository = ImageCapilarAsyncRepository;
     this._unitOfWork = unitOfWork;
 }
Esempio n. 15
0
 public CustomerService(IAsyncRepository <Customer> customerRepository)
 {
     _customerRepository = customerRepository;
 }
Esempio n. 16
0
 // public CreateOrderController(IHttpClientFactory client, IOptionsSnapshot<MyStoreSetting> configRoot, IHubContext<DataHub> hub, IAsyncRepository<Item> itemRepo)
 public CreateOrderController(IHttpClientFactory client, IOptionsSnapshot <MyStoreSetting> configRoot, IAsyncRepository <Item> itemRepo)
 {
     _clientFactory = client;
     _configRoot    = configRoot.Value;
     _itemRepo      = itemRepo;
 }
Esempio n. 17
0
 public UserService(IAsyncRepository <User> repository, IAsyncRepository <Friend> friendRepository, IAsyncRepository <Tag> tagRepository) : base(repository)
 {
     _repository       = repository;
     _friendRepository = friendRepository;
     _tagRepository    = tagRepository;
 }
 public GetEventsExportQueryHandler(IMapper mapper, IAsyncRepository <Event> eventRepository, ICsvExporter csvExporter)
 {
     _mapper          = mapper;
     _eventRepository = eventRepository;
     _csvExporter     = csvExporter;
 }
 public BasketViewModelService(IHttpContextAccessor httpContextAccessor, IAsyncRepository <Basket> basketRepository, IBasketService basketService, IAsyncRepository <Product> productRepository)
 {
     _httpContextAccessor = httpContextAccessor;
     _basketRepository    = basketRepository;
     _basketService       = basketService;
     _productRepository   = productRepository;
 }
Esempio n. 20
0
 public ActionListService(IAsyncRepository <ActionList> listRepository)
 {
     _listRepository = listRepository;
 }
Esempio n. 21
0
 public EpisodeService(IAsyncRepository <Episode> episodeRepository, IAsyncRepository <Appearance> appearanceRepository)
 {
     _episodeRepository    = episodeRepository;
     _appearanceRepository = appearanceRepository;
 }
Esempio n. 22
0
 public GetAllocationTypeQueryHandler(IMapper mapper, IAsyncRepository <AllocationType> allocationTypeRepository)
 {
     _mapper = mapper;
     _allocationTypeRepository = allocationTypeRepository;
 }
 public UpdateEventCommandHandler(IMapper mapper, IAsyncRepository <Event> eventRepository)
 {
     _mapper          = mapper;
     _eventRepository = eventRepository;
 }
Esempio n. 24
0
 public GetEventDetailQueryHandler(IMapper mapper, IAsyncRepository <Event> eventRepository, IAsyncRepository <Category> categoryRepository)
 {
     _eventRepository    = eventRepository;
     _categoryRepository = categoryRepository;
     _mapper             = mapper;
 }
Esempio n. 25
0
 public CacheHelper(IAsyncRepository <Action> actionRepository, IMemoryCache memoryCache)
 {
     _actionRepository = actionRepository;
     _memoryCache      = memoryCache;
 }
Esempio n. 26
0
 public BookingsService(IAsyncRepository <Bookings> bookingsRepository)
 {
     _bookingsRepository = bookingsRepository;
 }
Esempio n. 27
0
 public QuestionAppService(IAsyncRepository <Question> questionRepository,
                           IAsyncRepository <Answer> answerRepository)
 {
     _questionRepository = questionRepository;
     _answerRepository   = answerRepository;
 }
Esempio n. 28
0
 public BasketService(IAsyncRepository <Basket> basketRepository)
 {
     _basketRepository = basketRepository;
 }
Esempio n. 29
0
 public Delete(IAsyncRepository <Author> repository)
 {
     _repository = repository;
 }
 public MarketSellService(IAsyncRepository <MarketSell> asyncRepository, IMapper mapper, IMarketSellRepository marketSell)
 {
     _asyncRepository = asyncRepository;
     _mapper          = mapper;
     _marketSell      = marketSell;
 }
Esempio n. 31
0
 public PostAppService(IAsyncRepository <Post> postRepository, IBlobService blobService)
 {
     _postRepository = postRepository;
     _blobService    = blobService;
 }
Esempio n. 32
0
 public BasketService(IAsyncRepository <Basket> basketRepository,
                      IAppLogger <BasketService> logger)
 {
     _basketRepository = basketRepository;
     _logger           = logger;
 }
Esempio n. 33
0
 public CategoryService(IRepository <Category> repository, IAsyncRepository <Category> asyncRepository)
 {
     this.repository      = repository;
     this.asyncRepository = asyncRepository;
 }
 public UpdateDocumentUserGroupCommandHandler(IDocumentUserGroupRepository documentUserGroupRepository, IMapper mapper)
 {
     _documentUserGroupRepository = documentUserGroupRepository;
     _mapper = mapper;
 }
Esempio n. 35
0
 public IndexModel(IAsyncRepository <Product> productRepository,
                   IMapper mapper)
 {
     _productRepository = productRepository;
     _mapper            = mapper;
 }
        // GET: api/Customers


        public CustomersController() : base()
        {
            __loggingResourceName = "Customer";
            _repo = new CustomerAsyncRepository();
            _dataAccessAuthoriser = new AuthoriseCustomerDataAccess();
        }
Esempio n. 37
0
 public CreateCategoryCommandHandler(IMapper mapper, IAsyncRepository <Category> categoryRepository)
 {
     _mapper             = mapper;
     _categoryRepository = categoryRepository;
 }
 public OtherDriversController()
 {
     __loggingResourceName = "OtherDriver";
     repo = new OtherDriverAsyncRepository(_db);
     _dataAccessAuthoriser = new AuthoriseCustomerDataAccess(_db);
 }
Esempio n. 39
0
 public GetSportDetailQueryHandler(IMapper mapper, IAsyncRepository <Sport> sportRepository)
 {
     _mapper          = mapper;
     _sportRepository = sportRepository;
 }
Esempio n. 40
0
 public QuizService(IAsyncRepository <Quiz> quizRepository, IAsyncRepository <Student> studentRepository, IAsyncRepository <QuizItem> quizItemRepository)
 {
     _quizRepository     = quizRepository;
     _studentRepository  = studentRepository;
     _quizItemRepository = quizItemRepository;
 }
Esempio n. 41
0
 public SuppliersService(IAsyncRepository <T> repository) : base(repository)
 {
 }
 public TeamsController()
 {
     var dataContext = new AppServiceDataContext();
     this.repository = new Repository(dataContext);
 }
Esempio n. 43
0
 public GetEventsListQueryHandler(IMapper mapper, IAsyncRepository <Event> eventRepository)
 {
     _mapper          = mapper;
     _eventRepository = eventRepository;
 }
        // GET: api/AccidentMedia

        public AccidentMediaController()
        {
            __loggingResourceName = "AccidentMedia";
            repo = new AccidentMediaAsyncRepository(_db);
            _dataAccessAuthoriser = new AuthoriseCustomerDataAccess(_db);
        }