<tabset class="overflowhidden marginbottom0" tabset-name="clientTabset">
<tab heading="General" title="general">
<p>Hello</p>
<button ng-click="general()" class="btn btn-primary" has-permission='CREATE_CLIENT'>Next</button>
</tab>
<tab heading="Address" title="address" >
<p>hello world </p>
</tab>
</tabset>
我想在点击下一步按钮
后将标签从常规标签切换到地址标签答案 0 :(得分:2)
您好,您可以尝试使用active true
<强> JS 强>
$scope.active = {
one: false,
two: true
};
<强> HTML 强>
<tabset>
<tab heading="General" title="general">
One
<button ng-click="general()" class="btn btn-primary" has-permission='CREATE_CLIENT'>Next</button>
</tab>
<tab heading="Address" title="address" active="active.two">Two</tab>
</tabset>
答案 1 :(得分:0)
的javascript
$scope.general = function () {
$scope.active = 1;
}
HTML
<tabset class="overflowhidden marginbottom0" tabset-name="clientTabset" active="active">
<tab heading="General" title="general" index="0">
<p>Hello</p>
<button ng-click="general()" class="btn btn-primary" has-permission='CREATE_CLIENT'>Next</button>
</tab>
<tab heading="Address" title="address" index="1">
<p>hello world</p>
</tab>
</tabset>
参考:https://github.com/angular-ui/bootstrap/tree/master/src/tabs