public UploadCommandHandler(IAttachmentRepository repository, IUnitOfWork unitOfWork, IMapper mapper, IAuthenticatedUserService authenticatedUser)
 {
     _repository        = repository;
     _unitOfWork        = unitOfWork;
     _mapper            = mapper;
     _authenticatedUser = authenticatedUser;
 }
 public RedmineController(IStringConstantRepository stringConstant, IRedmineRepository redmineRepository,
                          IAttachmentRepository attachmentRepository)
     : base(stringConstant)
 {
     _redmineRepository    = redmineRepository;
     _attachmentRepository = attachmentRepository;
 }
Beispiel #3
0
        public static void GenerateDemoData(
            IIssueRepository issueRepository,
            IProjectRepository projectRepository,
            IAttachmentRepository attachmentRepository)
        {
            Project p = new Project("SHOP", "Webshop", "All issues related to the webshop.");

            projectRepository.Add(p);

            Issue i = new Issue(p, "Crash after payment", @"I have justed paid for two pairs of shoes - or rather I tried to. When I clicked 'Pay' all I got was a yellow error screen.", 3);

            issueRepository.Add(i);

            string     errorReport = "This is an error report ...";
            Attachment att         = new Attachment(i, "Error report", "Error report from end user", Encoding.UTF8.GetBytes(errorReport), "text/plain");

            attachmentRepository.Add(att);

            string logFile = "DEBUG 2014-01-22 15:45:07,610 166033ms  [9] Log4NetTraceListener   WriteLine          - Executing OperationResult OperationResult: type=OK, statusCode=200.";

            att = new Attachment(i, "Logfile", "Logfile with server stack trace", Encoding.UTF8.GetBytes(logFile), "text/plain");
            attachmentRepository.Add(att);

            i = new Issue(p, "Not calculating VAT correctly", @"When I add both shoes and socks it fails to calculate the VAT correctly.", 3);

            issueRepository.Add(i);

            i = new Issue(p, "General Failure?", @"When I press ctrl-P it says 'General failure reading harddisk'! Who is that General and why is he reading my hard disk?", 5);

            issueRepository.Add(i);
        }
Beispiel #4
0
 public AttachmentRepositoryTest()
 {
     _componentContext     = AutofacConfig.RegisterDependancies();
     _attachmentRepository = _componentContext.Resolve <IAttachmentRepository>();
     _userManager          = _componentContext.Resolve <ApplicationUserManager>();
     _stringConstant       = _componentContext.Resolve <IStringConstantRepository>();
 }
 public LeaveRequestController(ISlackRepository slackRepository, IAttachmentRepository attachmentRepository, ILogger logger, IStringConstantRepository stringConstant)
 {
     _slackRepository      = slackRepository;
     _attachmentRepository = attachmentRepository;
     _logger         = logger;
     _stringConstant = stringConstant;
 }
Beispiel #6
0
 public AttachmentService(IMapper mapper, IAttachmentRepository attachmentRepository, IMediaTypeRepository mediaTypeRepository, WebConfigModel webConfig)
 {
     _mapper = mapper;
     _attachmentRepository = attachmentRepository;
     _mediaTypeRepository  = mediaTypeRepository;
     _webConfig            = webConfig;
 }
 public AttachmentsController(IUserRepository userRepository, IAttachmentRepository attachmentRepository, IActivityRepository activityRepository)
     : base(userRepository)
 {
     _userRepository = userRepository;
     _attachmentRepository = attachmentRepository;
     _activityRepository = activityRepository;
 }
 public RequestService(IUnitOfWork unitOfWork, IRequestRepository requestRepository,
                       IProfileRepository profileRepository, IStudentRepository studentRepository,
                       IPersonRepository personRepository, IMemberMasterRepository memberMasterRepository,
                       ISignerRepository signerRepository, ICartableRepository cartableRepository,
                       IPostPersonRepository postPersonRepository, IArchiveRepository archiveRepository,
                       IUserPostRepository userPostRepository, ICommissionRepository commissionRepository,
                       ICouncilRepository councilRepository, IAttachmentRepository attachmentRepository,
                       IVoteRepository voteRepository, ICommissionSpecialEducationRepository commissionSpecialEducationRepository)
 {
     _unitOfWork             = unitOfWork;
     _requestRepository      = requestRepository;
     _profileRepository      = profileRepository;
     _studentRepository      = studentRepository;
     _personRepository       = personRepository;
     _memberMasterRepository = memberMasterRepository;
     _signerRepository       = signerRepository;
     _cartableRepository     = cartableRepository;
     _postPersonRepository   = postPersonRepository;
     _archiveRepository      = archiveRepository;
     _userPostRepository     = userPostRepository;
     _commissionRepository   = commissionRepository;
     _councilRepository      = councilRepository;
     _attachmentRepository   = attachmentRepository;
     _voteRepository         = voteRepository;
     _commissionSpecialEducationRepository = commissionSpecialEducationRepository;
 }
 public SyncService(
     ICipherApiRepository cipherApiRepository,
     IFolderApiRepository folderApiRepository,
     IAccountsApiRepository accountsApiRepository,
     ISettingsApiRepository settingsApiRepository,
     ISyncApiRepository syncApiRepository,
     IFolderRepository folderRepository,
     ICollectionRepository collectionRepository,
     ICipherCollectionRepository cipherCollectionRepository,
     ICipherService cipherService,
     IAttachmentRepository attachmentRepository,
     ISettingsRepository settingsRepository,
     IAuthService authService,
     ICryptoService cryptoService,
     ISettings settings,
     IAppSettingsService appSettingsService)
 {
     _cipherApiRepository        = cipherApiRepository;
     _folderApiRepository        = folderApiRepository;
     _accountsApiRepository      = accountsApiRepository;
     _settingsApiRepository      = settingsApiRepository;
     _syncApiRepository          = syncApiRepository;
     _folderRepository           = folderRepository;
     _collectionRepository       = collectionRepository;
     _cipherCollectionRepository = cipherCollectionRepository;
     _cipherService        = cipherService;
     _attachmentRepository = attachmentRepository;
     _settingsRepository   = settingsRepository;
     _authService          = authService;
     _cryptoService        = cryptoService;
     _settings             = settings;
     _appSettingsService   = appSettingsService;
 }
 public LeaveReportController(ILeaveReportRepository leaveReport, IAttachmentRepository attachmentRepository, ApplicationUserManager userManager, ILogger logger)
 {
     _leaveReport          = leaveReport;
     _attachmentRepository = attachmentRepository;
     _userManager          = userManager;
     _logger = logger;
 }
 public ProviderService(IMapper mapper, IRequestData requestData, IProviderRepository providerRepository, IAttachmentRepository attachmentRepository, IStorageService storageService)
     : base(mapper, requestData)
 {
     this.providerRepository   = providerRepository;
     this.attachmentRepository = attachmentRepository;
     this.storageService       = storageService;
 }
Beispiel #12
0
 public AttachmentService(IAttachmentRepository repository,
                          IUnitOfWork unitOfWork,
                          IFileManagement fileManagement)
     : base(repository, unitOfWork)
 {
     FileManagement = fileManagement;
 }
 // Using DI to inject infrastructure persistence Repositories
 public SetUniCommandHandler(IMediator mediator, IAttachmentRepository attachmentRepository,
                             IAttachmentBandwidthRepository attachmentBandwidthRepository)
 {
     _mediator                      = mediator ?? throw new ArgumentNullException(nameof(mediator));
     _attachmentRepository          = attachmentRepository ?? throw new ArgumentNullException(nameof(attachmentRepository));
     _attachmentBandwidthRepository = attachmentBandwidthRepository ?? throw new ArgumentNullException(nameof(attachmentBandwidthRepository));
 }
Beispiel #14
0
 public AbstractService(IMapper mapper, IDapperRepository <T, PK> repository, IAttachmentRepository attachmentRepository, IHttpContextAccessor accessor)
 {
     Mapper               = mapper;
     Repository           = repository;
     AttachmentRepository = attachmentRepository;
     HttpContextAccessor  = accessor;
 }
 public LeaveReportController(ILeaveReportRepository leaveReport, IAttachmentRepository attachmentRepository,
                              ApplicationUserManager userManager, IStringConstantRepository stringConstant) : base(stringConstant)
 {
     _leaveReport          = leaveReport;
     _attachmentRepository = attachmentRepository;
     _userManager          = userManager;
 }
Beispiel #16
0
 public AttachmentService(
     IDbContextScopeFactory dbContextScopeFactory,
     IAttachmentRepository attachmentRepository)
 {
     _dbContextScopeFactory = dbContextScopeFactory;
     _attachmentRepository  = attachmentRepository;
 }
Beispiel #17
0
    public static void GenerateDemoData(
      IIssueRepository issueRepository, 
      IProjectRepository projectRepository, 
      IAttachmentRepository attachmentRepository)
    {
      Project p = new Project("SHOP", "Webshop", "All issues related to the webshop.");
      projectRepository.Add(p);

      Issue i = new Issue(p, "Crash after payment", @"I have justed paid for two pairs of shoes - or rather I tried to. When I clicked 'Pay' all I got was a yellow error screen.", 3);

      issueRepository.Add(i);

      string errorReport = "This is an error report ...";
      Attachment att = new Attachment(i, "Error report", "Error report from end user", Encoding.UTF8.GetBytes(errorReport), "text/plain");
      attachmentRepository.Add(att);

      string logFile = "DEBUG 2014-01-22 15:45:07,610 166033ms  [9] Log4NetTraceListener   WriteLine          - Executing OperationResult OperationResult: type=OK, statusCode=200.";
      att = new Attachment(i, "Logfile", "Logfile with server stack trace", Encoding.UTF8.GetBytes(logFile), "text/plain");
      attachmentRepository.Add(att);

      i = new Issue(p, "Not calculating VAT correctly", @"When I add both shoes and socks it fails to calculate the VAT correctly.", 3);

      issueRepository.Add(i);

      i = new Issue(p, "General Failure?", @"When I press ctrl-P it says 'General failure reading harddisk'! Who is that General and why is he reading my hard disk?", 5);

      issueRepository.Add(i);
    }
Beispiel #18
0
 public AttachmentService(IAttachmentRepository repository, IAttachmentOwnerRepository ownerRepository, IOptionsMonitor <ModuleCommonOptions> moduleCommonOptionsMonitor, IMediaTypeRepository mediaTypeRepository, IMapper mapper)
 {
     _repository          = repository;
     _ownerRepository     = ownerRepository;
     _moduleCommonOptions = moduleCommonOptionsMonitor.CurrentValue;
     _mediaTypeRepository = mediaTypeRepository;
     _mapper = mapper;
 }
Beispiel #19
0
 public AttachmentController(IAttachmentRepository repository, IMapper mapper, LinkGenerator linkGenerator,
                             ILogger <AttachmentController> logger)
 {
     _repository    = repository;
     _mapper        = mapper;
     _linkGenerator = linkGenerator;
     _logger        = logger;
 }
Beispiel #20
0
 public AttachmentServices(IConfiguration configuration,
                           ICommentRepository commentRepository,
                           IAttachmentRepository attachmentRepository)
 {
     _configuration        = configuration;
     _commentRepository    = commentRepository;
     _attachmentRepository = attachmentRepository;
 }
        public AttachmentService(IAttachmentRepository attachmentRepository, IReferenceGenerator referenceGenerator)
        {
            Check.If(attachmentRepository).IsNotNull();
            Check.If(referenceGenerator).IsNotNull();

            _attachmentRepository = attachmentRepository;
            _referenceGenerator = referenceGenerator;
        }
Beispiel #22
0
 public AttachmentService(IAttachmentRepository attachmentRepository)
 {
     _attachmentRepository = attachmentRepository;
     if (!string.IsNullOrEmpty(CurrentUser.DbName))
     {
         this._dbName = CurrentUser.DbName;
     }
 }
Beispiel #23
0
 public RequestUniWhenAttachmentCreatedDomainEventHandler(
     ILoggerFactory logger,
     IAttachmentRepository attachmentRepository,
     IAttachmentIntegrationEventService attachmentIntegrationEventService)
 {
     _attachmentRepository = attachmentRepository ?? throw new ArgumentNullException(nameof(attachmentRepository));
     _attachmentIntegrationEventService = attachmentIntegrationEventService ?? throw new ArgumentNullException(nameof(attachmentIntegrationEventService));
     _logger = logger ?? throw new ArgumentNullException(nameof(logger));
 }
Beispiel #24
0
 public AttachmentService(ILoggerServices loggerServices, IDbContextScopeFactory dbContextScopeFactory, IMapper mapper, IUserServices userServices, IAttachmentRepository attachmentRepository, ITaskItemProcessHistoryService taskItemProcessHistoryService)
 {
     _loggerServices        = loggerServices;
     _dbContextScopeFactory = dbContextScopeFactory;
     _mapper                        = mapper;
     _userServices                  = userServices;
     _attachmentRepository          = attachmentRepository;
     _taskItemProcessHistoryService = taskItemProcessHistoryService;
 }
 public AttachmentService(IAttachmentRepository repository, IAttachmentOwnerRepository ownerRepository, IMediaTypeRepository mediaTypeRepository, IMapper mapper, CommonDbContext dbContext, IConfigProvider configProvider)
 {
     _repository          = repository;
     _ownerRepository     = ownerRepository;
     _mediaTypeRepository = mediaTypeRepository;
     _mapper         = mapper;
     _dbContext      = dbContext;
     _configProvider = configProvider;
 }
 public RedmineRepository(IRepository <ApplicationUser> userDataRepository, IHttpClientService httpClientService,
                          IStringConstantRepository stringConstant, IAttachmentRepository attachmentRepository, IClient clientRepository)
 {
     _userDataRepository   = userDataRepository;
     _httpClientService    = httpClientService;
     _stringConstant       = stringConstant;
     _attachmentRepository = attachmentRepository;
     _clientRepository     = clientRepository;
 }
        public AddEditAttachmentViewModel(IAttachmentRepository attachmentRepository)
        {
            this.attachmentRepository = attachmentRepository;

            CancelCommand        = new RelayCommand(Close);
            BrowseFilesCommand   = new RelayCommand(BrowseFiles);
            AddAttachmentCommand = new RelayCommand(SaveAttachments);
            Attachments          = new ObservableCollection <Attachment>();
        }
Beispiel #28
0
 protected void AddAttachments(IAttachmentRepository attachmentRepository, Diary diary, List <string> fileNames)
 {
     foreach (string fileName in fileNames)
     {
         attachmentRepository.Add(new Attachment {
             Path = fileName, DiaryId = diary.Id
         });
     }
 }
Beispiel #29
0
 protected void AddAttachments(IAttachmentRepository attachmentRepository, Todo todo, List <string> fileNames)
 {
     foreach (string fileName in fileNames)
     {
         attachmentRepository.Add(new Attachment {
             Path = fileName, TodoId = todo.Id
         });
     }
 }
        public AttachmentController(IAttachmentRepository repository, string catalog, LoginView view)
        {
            this._LoginId = view.LoginId.ToLong();
            this._UserId = view.UserId.ToInt();
            this._OfficeId = view.OfficeId.ToInt();
            this._Catalog = catalog;

            this.AttachmentRepository = repository;
        }
Beispiel #31
0
 public AppService(IAppRepository appRepo, IMasterService masterService,
                   IAttachmentRepository attachmentRepo,
                   ICreditCheckingRepository creditCheckingRepo)
 {
     _appRepo            = appRepo;
     _masterService      = masterService;
     _attachmentRepo     = attachmentRepo;
     _creditCheckingRepo = creditCheckingRepo;
 }
Beispiel #32
0
 public MessageService(IFirebaseMessageRepository fbMessageRepository, IAttachmentRepository attachmentRepository, IFirebaseStorageFactory storageFactory, ICounterRepository counterRepository, IMessageRepository messageRepository, IOptions <AppSettings> appSettings)
 {
     _fbMessageRepository  = fbMessageRepository;
     _counterRepository    = counterRepository;
     _attachmentRepository = attachmentRepository;
     _messageRepository    = messageRepository;
     _storageFactory       = storageFactory;
     _appSettings          = appSettings;
 }
Beispiel #33
0
        public AttachmentController(IAttachmentRepository repository, string catalog, LoginView view)
        {
            this._LoginId  = view.LoginId.ToLong();
            this._UserId   = view.UserId.ToInt();
            this._OfficeId = view.OfficeId.ToInt();
            this._Catalog  = catalog;

            this.AttachmentRepository = repository;
        }
 // Using DI to inject infrastructure persistence Repositories
 public CreateAttachmentCommandHandler(IMediator mediator, IAttachmentRepository attachmentRepository,
                                       IAttachmentRoleRepository attachmentRoleRepository, IAttachmentBandwidthRepository attachmentBandwidthRepository, IMapper mapper)
 {
     _mediator                      = mediator ?? throw new ArgumentNullException(nameof(mediator));
     _attachmentRepository          = attachmentRepository ?? throw new ArgumentNullException(nameof(attachmentRepository));
     _attachmentRoleRepository      = attachmentRoleRepository ?? throw new ArgumentNullException(nameof(attachmentRoleRepository));
     _attachmentBandwidthRepository = attachmentBandwidthRepository ?? throw new ArgumentNullException(nameof(attachmentBandwidthRepository));
     _mapper = mapper ?? throw new ArgumentNullException(nameof(mapper));
 }
 public ActivitiesController(IUserRepository userRepository,
     IActivityRepository activityRepository,
     IAttachmentRepository attachmentRepository,
     IAttachmentStorage attachmentStorage)
     : base(userRepository)
 {
     _userRepository = userRepository;
     _activityRepository = activityRepository;
     _attachmentRepository = attachmentRepository;
     _attachmentStorage = attachmentStorage;
 }
        public AttachmentController()
        {
            this._LoginId = AppUsers.GetCurrent().View.LoginId.ToLong();
            this._UserId = AppUsers.GetCurrent().View.UserId.ToInt();
            this._OfficeId = AppUsers.GetCurrent().View.OfficeId.ToInt();
            this._Catalog = AppUsers.GetCurrentUserDB();

            this.AttachmentRepository = new MixERP.Net.Schemas.Core.Data.Attachment
            {
                _Catalog = this._Catalog,
                _LoginId = this._LoginId,
                _UserId = this._UserId
            };
        }
        public PatientsBuilder(IDemographicFormDataRepository demographicFormDataRepository,
		                       IVitalsFormDataRepository vitalsFormDataRepository,
		                       IAdverseEventFormDataRepository adverseEventFormDataRepository,
		                       IElectrocardiogramFormDataRepository electrocardiogramFormDataRepository,
		                       IHappinessFormDataRepository happinessFormDataRepository,
		                       IInventoryFormDataRepository inventoryFormDataRepository,
		                       IAttachmentRepository attachmentRepository,
							IClinicalStudyDesign clinicalStudyDesign)
        {
            this.demographicFormDataRepository = demographicFormDataRepository;
            this.vitalsFormDataRepository = vitalsFormDataRepository;
            this.adverseEventFormDataRepository = adverseEventFormDataRepository;
            this.electrocardiogramFormDataRepository = electrocardiogramFormDataRepository;
            this.happinessFormDataRepository = happinessFormDataRepository;
            this.inventoryFormDataRepository = inventoryFormDataRepository;
            this.attachmentRepository = attachmentRepository;
            this.clinicalStudyDesign = clinicalStudyDesign;
        }
 public AttachmentController(IAttachmentRepository attachmentRepository)
 {
     this.attachmentRepository = attachmentRepository;
 }
Beispiel #39
0
 public AttachmentService(IUnitOfWork unitOfWork, IAttachmentRepository attachmentRepository)
 {
     _unitOfWork = unitOfWork;
     _attachmentRepository = attachmentRepository;
 }