Пример #1
0
        public SendMailForm(IEmailSender emailSender,
                            SystemSettingsRepository systemSettingsRepository,
                            UserProfileForm userProfileForm,
                            EmailSettingsForm emailSettingsForm)
        {
            this.emailSender       = emailSender;
            this.userProfileForm   = userProfileForm;
            this.emailSettingsForm = emailSettingsForm;
            smtpServerOptions      = systemSettingsRepository.GetSmtpServerOptions();

            InitializeComponent();
            Translator.Translate(this);
        }
Пример #2
0
        public MainForm(DatabaseSettingsForm databaseSettingsForm,
                        UserManagementForm userManagementForm,
                        UserProfileForm userProfileForm,
                        UserSettingsForm userSettingsForm,
                        CreateIssueForm createIssueForm,
                        CreateEventForm createEventForm,
                        CreateMeetingForm createMeetingForm,
                        AddResource addResource,
                        AddServerForm addServerForm,
                        AddCameraForm addCameraForm,
                        CalculatorForm calculatorForm,
                        EditorForm editorForm,
                        PasswordManager passwordManager,
                        CipherForm cipherForm,
                        SendMailForm sendMailForm,
                        LogViewer logViewer,
                        EmailSettingsForm emailSettingsForm,
                        AboutBox aboutBox,
                        ResourceListProvider resourceListProvider,
                        ServerListProvider serverListProvider,
                        FileManager fileManager,
                        IssueListProvider issueListProvider,
                        MeetingsListProvider meetingsListProvider,
                        EventListProvider eventListProvider,
                        IssueRepository issueRepository,
                        ResourceRepository resourceRepository,
                        ServerRepository serverRepository,
                        CameraRepository cameraRepository,
                        MeetingRepository meetingRepository,
                        EventRepository eventRepository,
                        CalendarItemsProvider calendarItemsProvider,
                        WakeOnLan wakeOnLan,
                        PingRequestSender pingRequestSender,
                        SystemSettingsRepository systemSettingsRepository,
                        ProcessUtils processUtils,
                        ErrorBoxHelper errorBoxHelper,
                        AddImageForm addImageForm,
                        IDateTimeProvider dateTimeProvider)
        {
            this.databaseSettingsForm     = databaseSettingsForm;
            this.userManagementForm       = userManagementForm;
            this.userProfileForm          = userProfileForm;
            this.userSettingsForm         = userSettingsForm;
            this.createIssueForm          = createIssueForm;
            this.createEventForm          = createEventForm;
            this.createMeetingForm        = createMeetingForm;
            this.sendMailForm             = sendMailForm;
            this.logViewer                = logViewer;
            this.emailSettingsForm        = emailSettingsForm;
            this.dateTimeProvider         = dateTimeProvider;
            this.addResource              = addResource;
            this.addServerForm            = addServerForm;
            this.addCameraForm            = addCameraForm;
            this.calculatorForm           = calculatorForm;
            this.editorForm               = editorForm;
            this.passwordManager          = passwordManager;
            this.cipherForm               = cipherForm;
            this.resourceListProvider     = resourceListProvider;
            this.serverListProvider       = serverListProvider;
            this.fileManager              = fileManager;
            this.issueListProvider        = issueListProvider;
            this.issueRepository          = issueRepository;
            this.resourceRepository       = resourceRepository;
            this.eventRepository          = eventRepository;
            this.meetingRepository        = meetingRepository;
            this.serverRepository         = serverRepository;
            this.cameraRepository         = cameraRepository;
            this.meetingsListProvider     = meetingsListProvider;
            this.eventListProvider        = eventListProvider;
            this.calendarItemsProvider    = calendarItemsProvider;
            this.systemSettingsRepository = systemSettingsRepository;
            this.aboutBox          = aboutBox;
            this.wakeOnLan         = wakeOnLan;
            this.pingRequestSender = pingRequestSender;
            this.processUtils      = processUtils;
            this.errorBoxHelper    = errorBoxHelper;
            this.addImageForm      = addImageForm;

            InitializeComponent();
            pTaskDetails.Dock = DockStyle.Fill;
            Translator.Translate(this);

            addResource.FormClosed += (_, __) =>
            {
                resourceListProvider.GetResources(tvItems);
            };

            fileManager.Active = lvFileExplorerLeft;
            GetDrives();

            cbView.FillWithEnum <CalendarViewType>();

            var columns = taskboard.GetColumns();

            foreach (var column in columns)
            {
                column.IssueStateChanged += TaskboardColumn_IssueStateChanged;
            }

            SetCalendarColumnSize();
        }