[英]How can i pass a dynamically generated form in angular form
Hi i have the following form that is dynamically created. 嗨,我有以下表格是动态创建的。 I need to send the form while submitting the form.
我需要在提交表格时发送表格。 How can i do it.
我该怎么做。
<form name="MCommForm{{item.Id}}" novalidate="">
<input type="text" name="MCommentN{{item.Id}}" ng-model="item.Comment">
<div ng-show="!(MCommForm{{item.Id}}.MCommentN{{item.Id}}.$pristine)" ng-click="grid.appScope.vm.saveComment(MCommForm(item.Id))"></div>
</form>
I have tried using MCommForm(item.Id) but its showing undefined ? 我尝试使用MCommForm(item.Id),但显示未定义?
Can any one suggest ? 有人可以建议吗?
Many Thanks in Advance ! 提前谢谢了 !
尝试使用ng-submit(ng-submit =“ submit(MCommForm(item.Id));”) https://docs.angularjs.org/api/ng/directive/ngSubmit
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.