Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Nested form validation v1.6.4 #16249

Closed
2 tasks
yoki91 opened this issue Oct 2, 2017 · 3 comments
Closed
2 tasks

Nested form validation v1.6.4 #16249

yoki91 opened this issue Oct 2, 2017 · 3 comments

Comments

@yoki91
Copy link

yoki91 commented Oct 2, 2017

I'm submitting a ...

  • bug report
  • feature request
  • [x ] other (Please do not submit support requests here (see above))

Current behavior:
the isolate form validate doesn't perform correctly. It throws ctrlCopy.$setValidity is not a function error. I following the issue #5858 but the solution provided is no longer supporting the new version of angularjs.

Expected / new behavior:
I want the isolate form do its own validation without propagates any changes to the parent form and vice versa

Minimal reproduction of the problem with instructions:
http://jsfiddle.net/j3u1xed2/
Open developer tool on Chrome, you will see the error message in console.
AngularJS version: 1.6.4

Browser: [Chrome Version 61.0.3163.100]

Anything else:

@gkalpak
Copy link
Member

gkalpak commented Oct 2, 2017

The example/workaround stopped working, because some of the methods it relied on were moved to the prototype of the NgModuleController, instead of the NgModelController instance itself. This is a documented breaking change.

Here is a modified version that accounts for that.

Please note that we cannot guarantee that community-provided workarounds and custom solutions will continue to work (especially between breaking releases), so use them at your own risk and always try to understand how/why they work.

@yoki91
Copy link
Author

yoki91 commented Oct 2, 2017

@gkalpak Thanks for the answer. Could you provide the document which has registered breaking change?

Best regards

@gkalpak
Copy link
Member

gkalpak commented Oct 2, 2017

You can read about all breaking changes in the changelog.
Also, the migration guide has useful info on upgrading between minor (breaking) versions.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants