priyanka.sarkar priyanka.sarkar - 1 year ago 88
AngularJS Question

Column value merging in AngularJS

How to perfom column value merging in AngularJS?

Answer Source

Make your JSON

var jsonData = [
                    "bucket": ">120",
                    "productCodes": ["SBML", "SBHL"]                  
                    "bucket": "1-30",
                    "productCodes": ["SBHL", "SBML", "SBML+"]
                    "bucket": "X",
                    "productCodes": ["SBNL++"]

and you view

<body ng-app="myApp">       
    <div ng-controller="MyCtrl" align="center">  
        <table border="1">

                  <th>Allocated #</th>                   
            <tr ng-repeat="p in products">

                  <td><span ng-repeat="c in p.productCodes">{{c}}</span></td>
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download