我有一个表单内的div与ng-if条件。最初形式是封闭的。单击按钮,将显示表单。但在提交表单时,我得到了Cannot read property '$valid' of undefined
错误。如果我将ng-if更改为ng-show,它可以完美地工作。但我必须用n -if。我找不到出错的原因。还有一点,在获取错误时,我还会得到form object为null。如果有人知道答案,我将不胜感激。
我的代码