From d9760d35c2054c8c82c59c62ad95ea7a98a5f8dc Mon Sep 17 00:00:00 2001 From: WakeUpPig <1035465284@qq.com> Date: Fri, 4 Mar 2016 19:47:36 +0800 Subject: [PATCH] Update index.html change $viewValue --- 23.angular/9.validator/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/23.angular/9.validator/index.html b/23.angular/9.validator/index.html index c6d342d..5f867e0 100644 --- a/23.angular/9.validator/index.html +++ b/23.angular/9.validator/index.html @@ -58,7 +58,7 @@ console.log(scope.$eval(attrs['samePassword'])); return scope.$eval(attrs['samePassword']); },function(){ - ngModel.$setValidity('xxx',ngModel.modelValue == scope.$eval(attrs['samePassword'])); + ngModel.$setValidity('xxx',ngModel.$viewValue == scope.$eval(attrs['samePassword'])); }); @@ -66,4 +66,4 @@ } }); - \ No newline at end of file +