Having trouble displaying a dropdown menu when trying to print a menu from a JSON file.
https://i.sstatic.net/fNLxw.png
JSON Data
[{
"Option": "Request",
"Name": "<a href=\"#/request\"><i class=\"material-icons left\">flight</i>Request</a> ",
"Description": "Form for Request",
"Submenu": []
}, {
"Option": "Queries",
"Name": "<a href=\"#/queries\"><i class=\"material-icons left\">search</i>Queries</a> ",
"Description": "Form for Queries",
"Submenu": []
}, {
"Option": "Transfer",
"Name": "<a href=\"#/transfer\"><i class=\"material-icons left\">attach_money</i>Transfer</a> ",
"Description": "Transfer",
"Submenu": []
}, {
"Option": "Administration",
"Name": "<a class=\"dropdown-button\" data-activates=\"administration\"><i class=\"material-icons left\">settings</i>Administration<i class=\"material-icons right\">arrow_drop_down</i></a> ",
"Description": "Administration Menu",
"Submenu": [{
"Option": "Reservations",
"Name": "#/reservations ",
"Description": "Reservations",
"Submenu": null
}, {
"Option": "Global",
"Name": "#/global ",
"Description": "Global",
"Submenu": null
}, {
"Option": "Conventions",
"Name": "#/conventions ",
"Description": "Conventions",
"Submenu": null
}, {
"Option": "Application",
"Name": "#/application ",
"Description": "Application",
"Submenu": null
}]
}]
HTML Code:
<li ng-repeat="item in menu" ng-bind-html="item.Name" ng-hide="!authentication.isAuth">
<ul ng-if="item.Submenu.length>0" id="administration" class="dropdown-content">
<li ng-repeat="items in item.Submenu"><a href="#/reservations">Reservations</a></li>
<li><a href="#/reservations">Reservations</a></li>
<li><a href="#/global">Global</a></li>
<li><a href="#/conventions">Conventions</a></li>
<li><a href="#/application">Applications</a></li>
</ul>
</li>
Currently using angularjs 1.3.16 and frontend materializecss for the project.