I've searched high and low but haven't found a solution to my unique issue.
Just like many others, I'm facing the challenge of ng-include creating a new child scope that doesn't propagate to the parent.
I have a versatile template that I need to use with multiple form actions, but I'm stuck because it doesn't receive data from ng-include.
Here's the code snippet:
<form ng-controller='FormCtrl' name="form1" ng-submit="treatForm1(data)"><div ng-include src="'template'"></div></form>
<form ng-controller='FormCtrl' name="form2" ng-submit="treatForm2(data)"><div ng-include src="'template'"></div></form>
Unfortunately, I can't utilize notations like vm. or form.. Is there any way to access the ng-include scope upon submission? I attempted using $parent, but no luck.