javascript - AngularJS: how to show an array of arrays? -
i want show array formed other arrays. array:
[{ "net": "192.168.1.1/28", "_id": "531d179acacc4a8115530c0e", "ips": [{ "ips": "192.168.1.1", "_id": "531d179acacc4a8115530c0f" }] }, { "net": "192.168.1.1/24", "_id": "531d1c2d857831021c48e3af", "ips": [{ "ips": "192.168.1.1", "_id": "531d1c2d857831021c48e3b3" }, { "ips": "192.168.1.33", "_id": "531d1c2d857831021c48e3b2" }, { "ips": "192.168.1.38", "_id": "531d1c2d857831021c48e3b1" }, { "ips": "192.168.1.106", "_id": "531d1c2d857831021c48e3b0" }] }]
i did 2 loops (one inside other) ng-repeat second loop doesn't show anything, know why? can me? code.
thank much.
<li ng-repeat="data in networks"> red <a href="#/ip/{{data._id}}">{{data.net}}</a> <lu> <li ng-repeat="ip in data">{{ ip }} red <a href="#/ip/{{ip._id}}">{{ip.ips}},,</a></li> </li> </lu> </li>
your inner array in data.ips
have iterate on that
<li ng-repeat="ip in data.ips">
Comments
Post a Comment