Trying to get the value from the dropdown, but when i click button, instead its getting the value, it give an array
Object {id: "1", game: "SEAL ONLINE", $$hashKey: "object:4"}
I just want to get the id which is 1
Here is my code.
addlist.html
<select ng-model="addlist.games" ng-options="x.game for x in data">
<option value="{{x.id}}">{{x.game}}</option>
</select>
controller.js
.controller('AddListGamesCtrl', function($scope, $http, $ionicPopup, $state) {
$scope.addlist = {};
$scope.AddListSave = function() {
console.log($scope.addlist.games);
};
})