-
Notifications
You must be signed in to change notification settings - Fork 58
How to reset form? #39
Comments
Added $setUntounched() and I guess it works now :) |
Hello, yes I use the I could had a comment in the Wiki documentation if you want, but yes that is the correct way of resetting a form. Thanks for using it ;) |
Added a Wiki - Reset Form, that should explain it well. Let me know if you have other comments about it. :) Actually I did not try it, but does it reset the |
Ok I tried it and that is actually not enough, doing the I will re-open this issue and add a new function in the Service, should be done in the next couple days. Since I also add Protractor tests, it's a bit longer to do both. Thanks for the feedback |
How to Reset a Form. You can see the Wiki link https://github.com/ghiscoding/angular-validation/wiki/Reset-Form
This functionality was added in v1.3.31, there is a lot more options than I imagined at first. So the possible options you can pass the function should cover all cases. Make sure to update to latest v1.3.31 to see the changes |
@ghiscoding, thank you for taking time to take a look at this issue. I will try the new version when I'll have time. If anything comes up, will report back here. Thanks again! :) |
I'm trying to reset form to it's pristine state, but cannot succeed. I looked for a working example here, but couldn't find that either. I am changing all the input values to empty text (""), and then calling myform.$setPristine(); I think that is the way to do it. But the $setPrisitine() doesn't seem to do anything.
Can anyone guide me where to check or what could be the issue?
The text was updated successfully, but these errors were encountered: