New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Calling SaveViewModelAsync() twice #1226
Comments
A model only has a single backup at a time. We don't have plans to support multiple backup scenarios at the same time. |
You don’t have to do this as default. Or what is the common scenario for this? Have I to change the view after calling cancel or save? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Hi, |
What do you mean by: "a new backup cycle"? Maybe we can make some methods protected virtual so you can customize the model behavior? |
Like I explained, Edit data - Save - Back up will be replaced with new data; All without closing the view, so that the view, the model and the viewmodel is all time the same. I dind't find this use case in the examples. |
Is this possible? |
We can't just reply instantly, we have other stuff to do as well (actually make some money to keep supporting this as well). As soon as we have time to answer this question, we will. For now, you can look at our options over at Open Collective: https://opencollective.com/catel |
At the moment, whenever a VM is saved, it will call |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
If I use the CancelViewModelAsync() Method, the ViewModel doesn't get the PropertyChanged of the Model anymore. So if I edit the ViewModel again, the changes will be written to the Model, but changes on other Properties will not be shown in the ViewModel.
Addtional to that, if i call CancelViewModelAsync() the second time, nothing happend.
Steps to reproduce
Done in this TestRepo: https://github.com/RCP161/IDataObjectTest/tree/master/M1Vm2
=> The TextBlock does not change the state anymore. You can trace the problem in the output window.
=> Nothing happened.
Platform:
.NET version: 4.6.1
Expected behaviour
The ViewModel should still listen on the PropertyChanged of the Model.
The CancelViewModelAsync (or SaveViewModelAsync) should be called more times than one.
Actual behaviour
ViewModel dosen't listen to the PropertyChanged of the Model anymore.
Can't call ((System.ComponentModel.IEditableObject)this).BeginEdit(); to use the functionality again. So nothing happened.
The text was updated successfully, but these errors were encountered: