我使用這個jQuery選擇n個子angularjs在NG選項選擇n個子
<select class="perf-select">
<option selected>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
</select>
jQuery的
jQuery('.perf-select>option:eq(2)').prop('selected', true);
我如何在angularjs NG選項
<select class="perf-select" ng-model="viewProfileCtrl.graphsForm.institution"
ng-options="inst.institution.institution_id as inst.institution.name for inst in viewProfileCtrl.perfiosAnalysisData.institutions"
ng-change="viewProfileCtrl.setGraphInsti(viewProfileCtrl.graphsForm.institution)">
<option value="" selected>Select a Bank </option>
</select>
初始化模式選擇默認值 –
如何實現這一目標我來自Angularjs新 – Develop
的可能的複製[如何使用ng-option設置select元素的默認值](http://stackoverflow.com/questions/17329495/how-to-use-ng-option-to-set-default-value-of-select-element) –