I have 8 icons like this
each icon have different functionality. Multiple icons can also click, that have call different functions.
this is just an eg but I have to do something else.I need to know how I can give a proper if condition for this functionality
now I am doing the following way
html code first 2 icons
<input value="1" type="checkbox" name="function[]" id="checkbox_vs1" ng-model="selection[1]" ng-change="onFChange()"/>
and in controller
$scope.onFChange = function()
{
if(this.selection[1] == true && this.selection[2] == false && this.selection[3] == false && this.selection[4] == false && this.selection[5] == false && this.selection[6] == false && this.selection[7] == false && this.selection[6] == false)
{
//call function
}
}
Like this I have to check all the combination is there any simple way i can implement this
Here is the plunker https://plnkr.co/edit/HNqc2GaQFgoMwhO5S9Ot link
So this will have 40320 if conditions. I need to reduce this
Thank you