我想从输入类型广播获得价值,但我得到未定义的输出。无法从输入类型无线电广播获得价值
这里是我的HTML代码:
<div ng-repeat="option in options" style="font-size : 20px;padding: 10px">
<input type="radio" ng-model="inpt" value = "{{option.poll_option_id}}"> {{option.poll_option}}</input>
</div>
<br>
<button ng-disabled="rd" ng-click="pollSubmit()">Submit </button>
我的角码是
$scope.pollSubmit = function(){
console.log($scope.inpt);
}
,而不是 ;-) – Nico