I have a problem with the Accordion:
I try to do pretty much the same what the demo shows, I have an Array of objects. Every object contains a string, which is the header title. It also contains a string which is the relative path to another HTML-File, which should be the content of the accordion-group.
$scope.groups = [{
groupTitle: "Title1",
templateUrl: "sites/file1.html"
}, {
groupTitle: "Title2",
templateUrl: "sites/file2.html"
}];
This code is in a controller called AccordionController
.
In my HTML I have this code inside of my controller
<accordion>
<accordion-group ng-repeat="group in groups" heading="{{group.groupTitle}}">
<div ng-include="group.templateUrl"></div>
</accordion-group>
</accordion>
The ng-include and that stuff works, but the groups basically don't react on clicks to then open or close, I also tried to add the is-open
directive. With the parameter I pointed to a boolean Array which changes the specific values on ng-click
The annoying thing - which I really don't understand anyway - is that all this works here in Plunker
I also linked
<link rel="stylesheet" type="text/css" href="styles/bootstrap.min.css" />
<script type="text/javascript" src="scripts/angular.js"></script>
<script type="text/javascript" src="scripts/ui-bootstrap-tpls-0.12.0.js"></script>
and added bootstrap.ui
to my module.
I get the error-message: TypeError: undefined is not a function
in the console when I load it.
I would appreciate any help!
app
andsettings
) and in the accordion 3 Controllers with that scope. In both modules I addedbootstrap.ui
and the modules know wach other too – Fia