public MeasurableQuantityEditViewModel() { AddMeasurementUnitCommand = new DelegateCommand( () => { Views.MeasurementUnitCreationDialog creationDialog = new Views.MeasurementUnitCreationDialog(); creationDialog.MeasurableQuantityInstance = _measurableQuantityInstance; creationDialog.CanModifyQuantity = false; if (creationDialog.ShowDialog() == true) { RaisePropertyChanged("UnitOfMeasurementList"); } }); }
public MeasurementUnitMainViewModel(IEventAggregator eventAggregator, IDataService <LabDbEntities> labDbData) { _eventAggregator = eventAggregator; _labDbData = labDbData; NewUnitCommand = new DelegateCommand( () => { Views.MeasurementUnitCreationDialog creationDialog = new Views.MeasurementUnitCreationDialog(); if (creationDialog.ShowDialog() == true) { RaisePropertyChanged("UnitOfMeasurementList"); } }); }