I have something challenging requirement and looking for solution to render it dynamically. I would request experts to help me on below requirement.
I need to render the data as per the above format and json data looks below
[ { Region: 'India' State: 'MH' Month: 'jan-16' visits: 10230157 }, { Region: 'India' State: 'DL' Month: 'jan-16' visits: 20023423 }, { Region: 'India' State: 'TL' Month: 'jan-16' visits: 38023804 }, { Region: 'India' State: 'RJ' Month: 'jan-16' visits: 65102322 }, { Region: 'India' State: 'KN' Month: 'jan-16' visits: 80234109 } ]
use below template and update as per the your solution if required.
<div class="tablecontainer" ng-if="groups.length > 0" ng-repeat="cat in groups">
<div class="row rowspace">
<div>{{cat.group.name}}</div>
<div ng-if="cat.group.columns.length>0" ng-repeat="column in cat.group.columns">
<div>{{column.name}}</div>
</div>
</div>
<div class="row">
<table class="table table-striped table-bordered">
<tr>
<th ng-repeat="column in cat.cols">{{column}}</th>
</tr>
<tr ng-repeat="row in cat.rows">
<td ng-repeat="column in cat.cols">{{row[column]}}</td>
</tr>
</table>
</div>
</div>
It will be great helpful and appreciated your help.
Thanks
