Angular ng messages show errors on ng repeat form

后端 未结 3 1534
醉酒成梦
醉酒成梦 2021-02-19 22:49

I want to generate inputs with ng repeat, the problem is when i have an error this is only apply on the last element, how can i make this apply per element?

<         


        
3条回答
  •  孤街浪徒
    2021-02-19 23:39

    I don't know if I understood your question but I use this approach to deal with inputs within ng-repeat. Consider the following codes

    This field is required
    This field is required

    Just follow the code. Just comment below if there's somethings not clear

提交回复
热议问题