Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angularjs/21.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/excel/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Angularjs 角度ng模型选项getterSetter不工作_Angularjs - Fatal编程技术网

Angularjs 角度ng模型选项getterSetter不工作

Angularjs 角度ng模型选项getterSetter不工作,angularjs,Angularjs,我正在尝试使用ng模型选项getterSetter。但是我不能让它调用我的模型函数 <input id="idShowDisabled2" type="checkbox" ng-model="myObj.Trev" ng-model-options="{ getterSetter: true }" />Show disabled feeds 如果我只使用一个常规模型,它就会工作:ng model=showdabled。我也留下了这条线 <input id="idShowDis

我正在尝试使用ng模型选项getterSetter。但是我不能让它调用我的模型函数

<input id="idShowDisabled2" type="checkbox" ng-model="myObj.Trev" ng-model-options="{ getterSetter: true }" />Show disabled feeds
如果我只使用一个常规模型,它就会工作:ng model=showdabled。我也留下了这条线

<input id="idShowDisabled" type="checkbox" ng-model="ShowDisabled" />Show disabled feeds

Fiddle here:

该功能使用1.3,但使用ng change在1.2中实现并不困难

您使用的是哪个版本的angularjs?Fiddle使用1.2.1我看到该功能需要1.3。我想这就是问题所在?是的,我也在期待