When I click on the span with
ng-click="click_subcat(opp.ct_nm);
, the content is loaded within the <span ng-click="click_pdms(opp.sbct_nm);" style="color:white;cursor:pointer">{{opp.sbct_nm}}</span>
. The issue arises when I click on that span as everything loads in <span ng-click="click_pdms(opp.sbct_nm);" style="color:white;cursor:pointer">{{opp.sbct_nm}}</span>
.
Check out the code below: (Before Click) https://i.sstatic.net/oNp3O.png (After Click) The same content loads in every category. I want electronics to display laptops and mobile devices, not fashion items. https://i.sstatic.net/DZSxl.png
<div id="mySidenav" class="sidenav" >
<a href="javascript:void(0)" class="closebtn" onclick="closeNav()">×</a>
<a ng-click="click_subcat(opp.ct_nm);">{{opp.ct_nm}}</a>
<a ng-repeat="opp in res">
<span ng-click="click_subcat(opp.ct_nm);" style="color:white;cursor:pointer;font-size:60px;" class="accordion">
{{opp.ct_nm}}
<ul ng-repeat="opp in inp">
<li>
<span ng-click="click_pdms(opp.sbct_nm);" style="color:white;cursor:pointer">{{opp.sbct_nm}}</span>
</li>
</ul>
</span>
</a>
</div>