Ejemplo n.º 1
0
		String DataRowWindow_DefineSelectionWindowControlsCall (CVM.SelectWindow Parent, Grid RootGrid, string Bereich,
			object Sender, string TableName, string ID, string [] Additionals, string [] BackAdditionals)
			{
			m_CallBackParent = Parent;
			//if (m_AdressenSelectionControl == null)
				{
				m_AdressenSelectionControl = new SelectAdressen ();
				m_AdressenSelectionControl.SelectionFinishedEventCall += 
					new SelectWindow.SelectionFinishedEvent (SelectionFinishedEventCall);
				m_AdressenSelectionControl.m_DataBase = DataBase;
				m_AdressenSelectionControl.HandleShowAndEditListBoxEntry_MouseRightButtonUpCall 
					+=new HandleShowAndEditListBoxEntry_MouseRightButtonUpEvent
						(SelectionControl_HandleShowAndEditListBoxEntry_MouseRightButtonUpCall);
				}
			//if (m_TypenSelectionControl == null)
				{
				m_TypenSelectionControl = new SelectTypen ();
				m_TypenSelectionControl.SelectionFinishedEventCall +=
					new SelectWindow.SelectionFinishedEvent (SelectionFinishedEventCall);
				m_TypenSelectionControl.DataBase = DataBase;
				}
			//if (m_PersonenTypenSelectionControl == null)
				{
				m_PersonenTypenSelectionControl = new SelectPersonenTypen ();
				m_PersonenTypenSelectionControl.SelectionFinishedEventCall +=
					new SelectWindow.SelectionFinishedEvent (SelectionFinishedEventCall);
				m_PersonenTypenSelectionControl.DataBase = DataBase;
				}
			//if (m_PersonenSelectionControl == null)
				{
				m_PersonenSelectionControl = new SelectPersonen ();

				m_PersonenSelectionControl.SelectionFinishedEventCall +=
					new SelectWindow.SelectionFinishedEvent (SelectionFinishedEventCall);
				m_PersonenSelectionControl.DataBase = DataBase;
				m_PersonenSelectionControl.HandleShowAndEditListBoxEntry_MouseRightButtonUpCall +=
					new HandleShowAndEditListBoxEntry_MouseRightButtonUpEvent
						(SelectionControl_HandleShowAndEditListBoxEntry_MouseRightButtonUpCall);
				}
			RootGrid.Children.Clear ();
			String Title = "Not defined";
			if (TableName == "Adressen")
				{
				RootGrid.Children.Add (m_AdressenSelectionControl);
				m_AdressenSelectionControl.Visibility = Visibility.Visible;
				m_AdressenSelectionControl.SetData (Bereich, Sender, TableName, ID, Additionals, BackAdditionals);
				Title = "Bitte wählen Sie die neue Adresse aus";
				m_AdressenSelectionControl.SetSelectionPossible (true);
				m_TypenSelectionControl.Visibility = Visibility.Collapsed;
				m_PersonenTypenSelectionControl.Visibility = Visibility.Collapsed;
				m_PersonenSelectionControl.Visibility = Visibility.Collapsed;
				}
			if (TableName == "Personen")
				{
				RootGrid.Children.Add (m_PersonenSelectionControl);
				m_PersonenSelectionControl.Visibility = Visibility.Visible;
				m_PersonenSelectionControl.SetData (Bereich, Sender, TableName, ID, Additionals, BackAdditionals);
				Title = "Bitte wählen Sie die neue Person aus";
				m_AdressenSelectionControl.Visibility = Visibility.Collapsed;
				m_TypenSelectionControl.Visibility = Visibility.Collapsed;
				m_PersonenTypenSelectionControl.Visibility = Visibility.Collapsed;
				//if (SelectionApplyEventCall != null)
				m_PersonenSelectionControl.SelectionApplyEventCall
					+= new SelectWindow.SelectionApplyEvent
						(WindowSelectionApplyEventCall);
						
				}
			if (TableName == "PersonenTypen")
				{
				RootGrid.Children.Add (m_PersonenTypenSelectionControl);
				m_PersonenTypenSelectionControl.Visibility = Visibility.Visible;
				m_PersonenTypenSelectionControl.SetData (Bereich, Sender, TableName, ID, Additionals, BackAdditionals);
				Title = "Bitte wählen Sie den neuen Personen Typ aus";
				m_PersonenSelectionControl.Visibility = Visibility.Collapsed;
				m_AdressenSelectionControl.Visibility = Visibility.Collapsed;
				m_TypenSelectionControl.Visibility = Visibility.Collapsed;
				}
			if (TableName == "OrganisationsTypen")
				{
				RootGrid.Children.Add (m_TypenSelectionControl);
				m_TypenSelectionControl.Visibility = Visibility.Visible;
				m_TypenSelectionControl.SetData (Bereich, Sender, TableName, ID, Additionals, BackAdditionals);
				Title = "Bitte wählen Sie den neuen OrganisationsTyp aus";
				m_PersonenTypenSelectionControl.Visibility = Visibility.Collapsed;
				m_PersonenSelectionControl.Visibility = Visibility.Collapsed;
				m_AdressenSelectionControl.Visibility = Visibility.Collapsed;
				}
			if (TableName == "OrganisationsSubTypen")
				{
				RootGrid.Children.Add (m_TypenSelectionControl);
				m_TypenSelectionControl.Visibility = Visibility.Visible;
				m_TypenSelectionControl.SetData (Bereich, Sender, TableName, ID, Additionals, BackAdditionals);
				Title = "Bitte wählen Sie den neuen OrganisationsSubTyp aus";
				m_PersonenTypenSelectionControl.Visibility = Visibility.Collapsed;
				m_PersonenSelectionControl.Visibility = Visibility.Collapsed;
				AdressenSelectionControl.Visibility = Visibility.Collapsed;
				}
			return Title;
			}
Ejemplo n.º 2
0
		void SetBereich (String NewBereich)
			{
			if (NewBereich == "All")
				{
				BereichsSelektionListBox.Visibility = Visibility.Visible;
				HeadLineText.Text = "Bitte wählen Sie den Bereich aus, in dem Sie arbeiten möchten";
				RemoveUnauthorizedBereichEntries ();
				OrganisationenListBox.Visibility = Visibility.Collapsed;
				OrganisatiosTypenListBox.Visibility = Visibility.Collapsed;
				NewOrganisationButton.Visibility = Visibility.Collapsed;
				ModifyOrganisationButton.Visibility = Visibility.Collapsed;
				DeleteOrganisationButton.Visibility = Visibility.Collapsed;
				OrganisationTabItem.Visibility = Visibility.Collapsed;
				PersonenTabItem.Visibility = Visibility.Collapsed;
				AdressenTabItem.Visibility = Visibility.Collapsed;
				StrassenTabItem.Visibility = Visibility.Collapsed;
				SchreibweisenTabItem.Visibility = Visibility.Collapsed;

				return;
				}
			m_Bereich = NewBereich;
			Organisationen = null;
			m_SelectPersonen = null;
			m_SelectAdressen = null;
			m_SelectTypen = null;
			m_SelectPersonenTypen = null;

			OrganisationenListBox.Visibility = Visibility.Visible;
			OrganisatiosTypenListBox.Visibility = Visibility.Visible;
			NewOrganisationButton.Visibility = Visibility.Visible;
			OrganisationTabItem.Visibility = Visibility.Visible;
			PersonenTabItem.Visibility = Visibility.Visible;
			AdressenTabItem.Visibility = Visibility.Visible;
			StrassenTabItem.Visibility = Visibility.Visible;
			SchreibweisenTabItem.Visibility = Visibility.Visible;
			AdressenPersonenAnAdresseListBox.Items.Clear ();
			PersonenListBox.Items.Clear ();
			OrganisationenListBox.Items.Clear ();
			AdressenStrassenListBox.Items.Clear ();
			AdressenHaeuserListBox.Items.Clear ();
			AdressenListBox.Items.Clear ();
			AdressenOrgAnAdresseListBox.Items.Clear ();
			AdressenPersonenAnAdresseListBox.Items.Clear ();
			OrganisatiosTypenListBox.SelectedItem = -1;
			FillOrganisatiosTypenListBox (m_StartupOrganisation);
			HeadLineText.Text = "Wartung für den Bereich \"" + m_Bereich + "\"";
			}