private void SaveAction() { _model.Level = _viewModel.Level; _repo.EditItem(_model); CloseWindow(); //SaveComplete?.Invoke(this, null); }
private void SaveAction() { IsChanged = false; _model.Name = _viewModel.Name; _model.Number = _viewModel.Number; _model.Type = _viewModel.Type; _model.Url = _viewModel.Url; if (_isCreate) { _model.Id = Guid.NewGuid(); _repo.CreateItem(_model); } else { _repo.EditItem(_model); } CloseWindow(); SaveComplete?.Invoke(this, _model); }