![](/img/trans.png)
[英]AngularJs: ng-class is not working with ui-select-choices of ui-select
[英]How to dynamically change the choices of ui select in angularjs
我有幾個UI選擇,基於第一個選擇,我想將選擇加載到第二個中。 我該如何動態地進行第二個操作。 我確實做了一些廣泛的搜索,但找不到任何東西。
<ui-select append-to-body="true"
ng-model="requirementChoice" theme="bootstrap"
ng-disabled="disabled" close-on-select="true"
title="choose a requirement"
theme="selectize"
name="requirements" id="requirements">
<ui-select-match placeholder="
{{translations.SLA_CHOOSE_REQUIREMENTS}}">
{{requirementChoice}}
</ui-select-match>
<ui-select-choices repeat="choice in requirementTypes |
filter:$select.search">
{{choice}}
</ui-select-choices>
</ui-select>
這是我的ui選擇中的第一個,具有選擇,並且基於這些選擇,我想將數據加載到第二個UI選擇中,有沒有辦法實現這一目標?
調用第一個ui-select的函數on-select,並在該函數中相應地設置第二個ui-select。 請參閱此https://github.com/angular-ui/ui-select/wiki/ui-select
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.