我正在使用Accordian,但试图显示树视图
请参阅以下样本以供参考。 Preview
var app = angular.module('plunker', ['ui.bootstrap']);
app.controller('MainController',
function($scope) {
$scope.items = [{
name: "Products",
desc: "Products",
subitems: [{
name: "Pricing",
desc: "Pricing",
subitems: [{
name: "Personal",
desc: "Personal",
subitems: [{
name: "R and d",
desc: "R and d",
}]
}, {
name: "subitem2",
desc: "Sub-Item 2"
}]
}, {
name: "Software",
desc: "Software"
}, {
name: "Hardware",
desc: "Hardware"
}]
}, {
name: "HP",
desc: "HP",
}];
$scope.default = $scope.items[2];
});
我需要将手风琴显示如下图所示。