私は次のことをしようとします
if ($scope.RetypePassword != $scope.resource.Password) {
$scope.resource.Password.$setValidity("missmatch", false);
} else {
$scope.resource.Password.$setValidity("missmatch", true);
}
しかし、このエラーで失敗します
TypeError: Object doesn't support property or method '$setValidity'
その理由は何ですか?
resource.Password は、このような入力にデータバインドされています
<input type="password" ng-model="resource.Password" name="Password" />