I am working on cordova application that consist of angularJS. I have a code snippet as follows:
<label class="item item-input item-select">
<div class="input-label">
Select Team
</div>
<select>
<option ng-repeat="deviceEach in devices" id="{{deviceEach.id}}">{{deviceEach.name}}</option>
</select>
</label>
<label class="item item-input">
<input type="text" placeholder="Enter user Email" ng-model="newuser.username">
</label>
<br>
<button ng-click="userSubmit(newuser)" class="button button-calm">
Add User
</button>
When user click on add User button it should capture the value of selected option Id and username entered. I can capture the value of input tag but how to capture the value of select tag selected option?
on the select element use ng-model
<select ng-model="selectedValue" >
<option ng-repeat="deviceEach in devices" id="{{deviceEach.id}}">{{deviceEach.name}}</option>
</select>