Programmatically selecting a tab with angularjs and bootstrapui

Let’s say you want to programmatically select a tab with angularjs and bootstrap ui:

[CODE MISSING]

According to the documentation for 3.1.1 it should be enough to modify the model; here controller.tabUsers or controller.tabGroups. Only: it doesn’t work. We’ll never know why.

The way out is simulating the click with jquery:

$("#tab_users a").trigger("click");

2 thoughts on “Programmatically selecting a tab with angularjs and bootstrapui

Leave a reply to OneStop Shop of Information Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.