Based on toggle button(YES, NO) i have select drop down, those toggle button change the value of the drop down, that does not support ng-selected when we select the item on any of the toggle button selection.
1) when we select the "YES" toggle button and on that click drop down option will change and we select the option from the drop down that's work fine for now.
2) But when we select the "No" toggle button and on that click drop option will change but ng-selected does not work and selected value will not be visible that's the
<!doctype html>
<html ng-app="ui.bootstrap.demo">
<head>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.4.5/angular.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.4.5/angular-animate.js"></script>
<script src="//angular-ui.github.io/bootstrap/ui-bootstrap-tpls-0.13.4.js"></script>
<script src="example.js"></script>
<link href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css" rel="stylesheet">
</head>
<body>
<div ng-controller="ButtonsCtrl">
<h4>Radio & Uncheckable Radio</h4>
<select ng-model="selectedItem">
<option ng-repeat="item in items"
ng-selected="$first" value="{{item}}">{{item}}</option>
</select>
<div class="btn-group">
<label class="btn btn-primary" ng-model="radioModel"
ng-click="getItems('1')" btn-radio="'Left'">YES</label>
<label class="btn btn-primary"
ng-click="getItems('2')" ng-model="radioModel" btn-radio="'Middle'">NO</label>
</div>
</div>
</body>
</html>
*************Below is the angularJS code ***************
angular.module('ui.bootstrap.demo', ['ngAnimate', 'ui.bootstrap']);
angular.module('ui.bootstrap.demo').controller('ButtonsCtrl',
function($scope) {
$scope.radioModel = 'Middle';
$scope.items = ['one', 'two', 'three', 'four']
$scope.getItems = function(criateria){
if(criateria == '1'){
$scope.items = ['one', 'two', 'three', 'four'];
}else{
$scope.items = ['Ele', 'Twlv', 'Thirteen', 'Fourteen'];
}
}
});