Exemple #1
0
 public DisplayComponentConfigurationCommand
 (
     SelectedComponentsDelegate selectedComponents,
     DatabaseComponents component,
     ConnectionConfiguration configControl
 )
 {
     SelectedComponents = selectedComponents;
     Database           = component;
     ConfigControl      = configControl;
 }
Exemple #2
0
        private void HandleUserCredentialsEnableState()
        {
            if (InvokeRequired)
            {
                Invoke(new MethodInvoker(HandleUserCredentialsEnableState));
            }
            else
            {
                // If patient Updater is the only supported componenet, disable "Create new Databases"
                if (SupportedDatabases == DatabaseComponents.PatientUpdater || DisableCreateFromConfiguration( ))
                {
                    ConnectToDbRadioButton.Checked = true;
                    CreateNewDbRadioButton.Enabled = false;
                }

                bool supportedUserManagementDb = UserManagementDbCheckBox.Checked && CreateNewDbRadioButton.Checked && ((SupportedDatabases & DatabaseComponents.UserManagement) == DatabaseComponents.UserManagement);
                bool supportedStorageServerDb  = StorageServerDbCheckBox.Checked && CreateNewDbRadioButton.Checked && ((SupportedDatabases & DatabaseComponents.StorageServer) == DatabaseComponents.StorageServer);
                bool enabled = supportedUserManagementDb || supportedStorageServerDb;
                WorkstationUserNameTextBox.Enabled            = enabled;
                WorkstationUserPasswordTextBox.Enabled        = enabled;
                WorkstationUserPasswordConfirmTextBox.Enabled = enabled;
                ShowPasswordCheckBox.Enabled = enabled;

                DatabaseComponents patientUpdaterDb = (DatabaseComponents)PatientUpdaterDbCheckBox.Tag;
                bool bPatientUpdaterSupported       = (SupportedDatabases & patientUpdaterDb) == patientUpdaterDb;
                PatientUpdaterDbCheckBox.Enabled = ConnectToDbRadioButton.Checked && bPatientUpdaterSupported;

                DatabaseComponents storageServerOptionsDb = (DatabaseComponents)LoadBalancePanel.Tag;
                bool bStorageServerOptionsSupported       = (SupportedDatabases & storageServerOptionsDb) == storageServerOptionsDb;
                LoadBalancePanel.Enabled = ConnectToDbRadioButton.Checked && bStorageServerOptionsSupported && StorageServerDbCheckBox.Checked;

                if (CreateNewDbRadioButton.Checked)
                {
                    // Create new databases
                    StorageServerOptionsDbCheckBox.Checked = false;
                    PatientUpdaterDbCheckBox.Checked       = false;
                }
            }
        }
 public static bool IsDatabaseSupported(DatabaseComponents database)
 {
     return(true);
 }