Argh, this again. I have a list of objects:
var roles = [{
id: 1,
name: 'Administrator'
}];
I am using ng-options and I want to display the name and when selected, it should use the name, but there is a filter. I tried this:
role.name for role in (roleController.roles | filter: $select.search) track by role.id
But it is throwing an error. Does anyone know how to do this?