I used below syntax to display username. I want to display username when (user.company==userData.company)
in the below list. Please help me to achieve this.
<select ng-options="user.FirstName+' 'user.LastName for user in companyUsers | orderBy:'FirstName' track by user.Id" ng-if="user.company==userData.company" ng-model="selectedUser" ng-change="loadListNew()">
</select>
Using ng-if="user.company==userData.company"
does not work because that would be applied to the select element.
Filters Options
Instead, you can use a filter directly inside your ng-options
like in this example.
Filter Document