I have this table:
<table class="table table-striped table-bordered table-responsive" ng-show="viewBusinessUnits">
<thead>
<tr>
<th>Business Unit</th>
<th>Sales</th>
<th>Percentage Last Year</th>
<th>WTD Percentage Last Year</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="row in tableData">
<td><a ng-click="toggleTable('{{row.name}}')">{{row.name}}</a></td><!---->
<td>{{row.sales}}</td>
<td>{{row.perc_ly}}</td>
<td>{{row.wtd_perc_ly}}</td>
</tr>
</tbody>
<table>
My problem here is that toggleTable('{{row.name}}') is never executed.
When I add the href="#" attribute to the <a> tag, only the anchor works.
When I try and give it a unique ng-model, ng-model='{{row.name}}', then all the columns show the strings {{row.sales}} {{row.perc_ly}} {{row.wtd_perc_ly}} as litterals instead of the corresponding values.
If I create a hardcoded link outside of a table, <a href="#" ng-click="toggleTable('view')">something</a>, it works.
I'm using bootstrap and flot charts in the same page. Could this be the reason why I'm getting this problem?
In every other angular page I'm using this it works, but not this one.
ng-click="toggleTable(row.name)"