void ViewModel_EventOpenItemDialog(ItemType itemType) { if (itemType == ItemType.Contact) { ContactInfoPopup cip = new ContactInfoPopup(); cip.ShowDialog(); } }
void ViewModel_EventOpenItemDialog(ItemType itemType) { if (itemType == ItemType.ServiceCall) { ServiceCallInfoPopup scip = new ServiceCallInfoPopup(); scip.ShowDialog(); } else if (itemType == ItemType.Contact) { ContactInfoPopup cip = new ContactInfoPopup(); cip.ShowDialog(); } }
private void datagridContactInfo_MouseDoubleClick(object sender, System.Windows.Input.MouseButtonEventArgs e) { // Should probably be in ViewModel, but will require wiring up a command if (ViewModel.WorkingTenant.PropertyListed != null && string.IsNullOrEmpty(ViewModel.WorkingTenant.Contact.address1)) { ViewModel.WorkingTenant.Contact.address1 = ViewModel.WorkingTenant.PropertyListed.address1; ViewModel.WorkingTenant.Contact.address2 = ViewModel.WorkingTenant.PropertyListed.address2; ViewModel.WorkingTenant.Contact.city = ViewModel.WorkingTenant.PropertyListed.city; ViewModel.WorkingTenant.Contact.state = ViewModel.WorkingTenant.PropertyListed.state; ViewModel.WorkingTenant.Contact.zip = ViewModel.WorkingTenant.PropertyListed.zip; } ViewModel.WorkingContact = ViewModel.WorkingTenant.ContactListed; ContactInfoPopup cip = new ContactInfoPopup(); cip.ShowDialog(); }