public TimeEntryAuditManagementService(ITimeEntryAuditRepository timeEntryAuditRepository, IPersonManagementService personManagementService, ITimeEntryRepository timeEntryRepository)
        {
            Check.Require(timeEntryAuditRepository != null, "timeEntryRepository may not be null");
            Check.Require(personManagementService != null, "personManagementService may not be null");

            _timeEntryAuditRepository = timeEntryAuditRepository;
            _personManagementService = personManagementService;
            _timeEntryRepository = timeEntryRepository;
        }
        public TimeEntryManagementService(ITimeEntryRepository timeEntryRepository, IRequestRepository requestRepository,
                                          IWrmsSystemRepository wrmsSystemRepository,
                                          IPersonManagementService personManagementService)
        {
            Check.Require(timeEntryRepository != null, "timeEntryRepository may not be null");
            Check.Require(requestRepository != null, "requestRepository may not be null");
            Check.Require(wrmsSystemRepository != null, "wrmsSystemRepository may not be null");
            Check.Require(personManagementService != null, "personManagementService may not be null");

            _timeEntryRepository = timeEntryRepository;
            _personManagementService = personManagementService;
            _requestRepository = requestRepository;
            _wrmsSystemRepository = wrmsSystemRepository;
            _personManagementService = personManagementService;
        }
 public TimeClockController(ILogger <AnnouncementController> logger, IPatrolRepository patrolRepository,
                            IPatrolService patrolService, ITimeClockService timeClockService, ITimeEntryRepository timeEntryRepository, ISystemClock clock)
 {
     _logger              = logger;
     _patrolRepository    = patrolRepository;
     _patrolService       = patrolService;
     _timeClockService    = timeClockService;
     _timeEntryRepository = timeEntryRepository;
     _clock = clock;
 }
Beispiel #4
0
 public TimeEntryController(ITimeEntryRepository repository, IOperationCounter <TimeEntry> operationCounter)
 {
     ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls;
     _repository       = repository;
     _operationCounter = operationCounter;
 }
 public TimeEntryController(ITimeEntryRepository timeEntryRepository)
 {
     this._repository = timeEntryRepository;
 }
Beispiel #6
0
 public TimeEntryController(ITimeEntryRepository repository, IOperationCounter <TimeEntry> operationCounter)
 {
     //repository set
     _repository       = repository;
     _operationCounter = operationCounter;
 }
Beispiel #7
0
 public TimeEntryHealthContributor(ITimeEntryRepository timeEntryRepository)
 {
     _timeEntryRepository = timeEntryRepository;
 }
Beispiel #8
0
 public TimeEntryController(ITimeEntryRepository repository)
 {
     _repository = repository;
 }
 public TimeEntryHealthContributor(ITimeEntryRepository repo)
 {
     _repo = repo;
 }
 public TimeEntryHealthContributor(ITimeEntryRepository repository)
 {
     Repository = repository;
 }
 public ApiController(ITimeEntryRepository timeEntryRepository)
 {
     _timeEntryRepository = timeEntryRepository;
 }
        public void SetUp()
        {
            ServiceLocatorInitializer.Init();

            _timeEntryRepository =
                MockRepository.GenerateMock<ITimeEntryRepository>();
            _timeEntryRepository.Stub(r => r.DbContext)
                .Return(MockRepository.GenerateMock<IDbContext>());

            _wrmsSystemRepository =
                MockRepository.GenerateMock<IWrmsSystemRepository>();
            _wrmsSystemRepository.Stub(r => r.DbContext)
                .Return(MockRepository.GenerateMock<IDbContext>());

            _requestRepository =
                MockRepository.GenerateMock<IRequestRepository>();
            _requestRepository.Stub(r => r.DbContext)
                .Return(MockRepository.GenerateMock<IDbContext>());
            _personManagementService = MockRepository.GenerateMock<IPersonManagementService>();

            _timeEntryManagementService = new TimeEntryManagementService(_timeEntryRepository, _requestRepository,
                                                                         _wrmsSystemRepository, _personManagementService);
        }
Beispiel #13
0
 public TimeEntryController(ITimeEntryRepository repository, IOperationCounter <TimeEntry> operationCounterObject)
 {
     _repository             = repository;
     _operationCounterObject = operationCounterObject;
 }
 public TimeEntriesController(ITimeEntryValidationService validationService, ITimeEntryRepository timeEntryRepository)
 {
     _validationService   = validationService;
     _timeEntryRepository = timeEntryRepository;
 }
Beispiel #15
0
 public TimeEntryController(ITimeEntryRepository repository)
 {
     database = repository;
 }
 public TimeEntryController(ITimeEntryRepository repository, IOperationCounter <TimeEntry> counter)
 {
     _repository = repository;
     _counter    = counter;
 }
 public TimeEntryController(ITimeEntryRepository timeEntryRepository, IOperationCounter <TimeEntry> operationCounter)
 {
     _timeEntryRepository = timeEntryRepository;
     _operationCounter    = operationCounter;
 }
 public TimeEntryController(ITimeEntryRepository inMemoryTimeEntryRepository)
 {
     _inMemoryTimeEntryRepository = inMemoryTimeEntryRepository;
 }
Beispiel #19
0
 public TimeEntryController(ITimeEntryRepository repository, IOperationCounter <TimeEntry> operationCounter)
 {
     this.Repository        = repository;
     this._operationCounter = operationCounter;
 }
 public TimeEntryController(IEmployeeRepository employeeRepository, IProjectRepository projectRepository, ITimeEntryRepository timeEntryRepository)
 {
     _employeeRepository  = employeeRepository;
     _projectRepository   = projectRepository;
     _timeEntryRepository = timeEntryRepository;
 }
Beispiel #21
0
        public HistoryFeedViewModel(IUserSession userSession, ISyncService syncService, ITimeEntryRepository timeEntryRepository,
                                    ITimeEntryTypeRepository timeEntryTypeRepository,
                                    IUserWlanSettingsService userWlanSettingsService,
                                    IAppSettings appSettings)
        {
            _userSession             = userSession;
            _syncService             = syncService;
            _timeEntryRepository     = timeEntryRepository;
            _timeEntryTypeRepository = timeEntryTypeRepository;
            _userWlanSettingsService = userWlanSettingsService;
            _appSettings             = appSettings;


            TimeEntries = new ObservableCollection <HistoryFeedRowViewModel>();
            ApplicationCommands.SyncCompleted.RegisterCommand(new DelegateCommand <object>(SyncComplete));
            ApplicationCommands.SyncProgressChanged.RegisterCommand(new DelegateCommand <Tuple <int, string> >(SyncProgressChanged));
            ApplicationCommands.SyncStarted.RegisterCommand(new DelegateCommand <object>(SyncStarted));
            TaskCommands.SaveTaskCompleted.RegisterCommand(new DelegateCommand <object>(TaskSaved));
            SyncInProgress = _syncService.SyncInProgress;
            ApplicationCommands.SyncFailed.RegisterCommand(new DelegateCommand <string>(SyncFailedCommand));
            CloseErrorMessageCommand = new DelegateCommand <object>(ExecuteCloseErrorMessage);
            CancelChanges            = new DelegateCommand <object>(CancelChangesExecute);

            TimeEntryTypes = _timeEntryTypeRepository.GetGlobal();

            ApplicationCommands.PremiseSettingChanged.RegisterCommand(new DelegateCommand <object>(SetDefaultType));
        }
Beispiel #22
0
 public GeneralSettingsService(IDomainSettings domainSettings, ITimeEntryRepository timeEntryRepository)
 {
     _domainSettings      = domainSettings;
     _timeEntryRepository = timeEntryRepository;
 }
        public ReportScreenMasterViewModel(ITimeEntryService timeEntryService, IBusyService busyService, IConnectivityService connectivityService,
                                           ITimeEntryTypeRepository timeEntryTypeRepository, ITimeEntryRepository timeEntryRepository, IAppSettings appSettings)
        {
            _timeEntryService        = timeEntryService;
            _busyService             = busyService;
            _connectivityService     = connectivityService;
            _timeEntryTypeRepository = timeEntryTypeRepository;
            _timeEntryRepository     = timeEntryRepository;
            _appSettings             = appSettings;
            Search = new DelegateCommand <object>(ExecuteSearch);
            _busyService.ShowBusy(_reportscreenKey);
            LoadPredefinedSearchItems();
            SelectedPredefinedSearch = PredefinedSearchItems[1];
            EditTimeEntryCommand     = new DelegateCommand <object>(EditTimeEntry);
            SaveCommand = new DelegateCommand <object>(SaveCommandExecute);

            try
            {
                TimeEntryTypes = _timeEntryTypeRepository.GetGlobal();
            }
            catch (Exception ex)
            {
                Logger.Error(ex);
            }

            TaskCommands.SaveTaskCompleted.RegisterCommand(new DelegateCommand(Reload));
            TaskCommands.SaveTaskCancelled.RegisterCommand(new DelegateCommand(Reload));

            ApplicationCommands.ConnectivityChanged.RegisterCommand(new DelegateCommand <object>(ConnectivityChangedExecute));
        }
Beispiel #24
0
        public WeeklyOverviewViewmodel(ITimeEntryService timeEntryService, IBusyService busyService, ITimeEntryRepository timeEntryRepository,
                                       ITaskItemViewmodelFactory taskItemViewmodelFactory, ITimeEntryTypeRepository timeEntryTypeRepository,
                                       ISyncService syncService, ICommonDialogs commonDialogs)
        {
            _timeEntryService = timeEntryService;
            //_busyService = busyService;
            _timeEntryRepository      = timeEntryRepository;
            _taskItemViewmodelFactory = taskItemViewmodelFactory;
            _timeEntryTypeRepository  = timeEntryTypeRepository;
            _syncService                    = syncService;
            _commonDialogs                  = commonDialogs;
            _syncCompletedCommand           = new DelegateCommand <object>(SyncCompletedExecute);
            PreviousDateCommand             = new DelegateCommand <object>(a => StartDate = StartDate.AddDays(-7));
            NextDayCommand                  = new DelegateCommand <object>(a => StartDate = StartDate.AddDays(7));
            TodayCommand                    = new DelegateCommand <object>(a => TodayCommandExecute());
            SwitchToDayViewCommand          = new DelegateCommand <object>(SwitchToDayViewCommandExecute);
            CopyPreviousTasksToSelectedDate = new DelegateCommand <object>(CopyPreviousTasksToSelectedDateExecute);
            AddTaskCommand                  = new DelegateCommand <object>(AddTaskCommandExecute);
            SaveCommand     = new DelegateCommand <object>(SaveCommandExecute);
            DeleteTimeEntry = new DelegateCommand <object>(DeleteTimeEntryExecute);
            ApplicationCommands.SyncCompleted.RegisterCommand(_syncCompletedCommand);
            TaskCommands.TaskSelectCompleted.RegisterCommand(new DelegateCommand <Task>(TaskSelectCompleted));
            TaskCommands.SaveTaskCancelled.RegisterCommand(new DelegateCommand <TimeEntry>(TaskSelectCompleted));

            Rows                    = new ObservableItemCollection <TaskItemViewmodel>();
            Rows.ItemChanged       += TasksOnItemChanged;
            _deletedRows            = new List <TaskItemViewmodel>();
            _timeEntriesForThisWeek = new List <TimeEntry>();

            TimeEntryTypes = _timeEntryTypeRepository.GetGlobal();
            StartDate      = DateTime.Today.FirstDayOfWeek();
        }