I have the following arrays:
owner_users = [{username : "sam", name:"Sampath", email:"xyz" },
{username : "ram", name:"Ram Mohan", email:"asd" },
{username : "shyam", name:"Shyam pandey", email:"wer" }]
and
admin_users = [{username : "sam", name:"Sampath", email:"xyz" },
{username : "pandey", name:"Mangal Pandey", email:"yuy" },
{username : "ameer", name:"Gajini", email:"tyrt" },
{username : "shyam", name:"Shyam pandey", email:"wer" }]
and
test_users = [{username : "kiran", name:"Kiran", email:"kiran" },
{username : "pandey", name:"Mangal Pandey", email:"yuy" },
{username : "balu", name:"Balakrishna", email:"balu.krsh" },
{username : "shyam", name:"Shyam pandey", email:"wer" }]
I am making ng-repeat of project_details in a table. project_details array is with object properties -- project_type, owner_name, comment. for owner_name i have to list this combination of user types in ng-options. Like if project_type is new then i have to show combined list of owner_user and test_users. if project_type is old, then i have to show combined list of owner_users and admin_users without duplicates.
How can I achieve this in angularJS?