You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But it seems a very nasty way of doing it.. Basically I have my Languages as objects in an array (campaign.Languages) but in order to have the first language selected by default I have to add the first and do ng-repeat on an array with 1 single item which i initialize it to be the first language of the main language array.
There must be a better way of doing this..
The text was updated successfully, but these errors were encountered:
<select selectpicker
ng-model=".currentLanguage"
ng-options="language.value as language.label for language in languages track by language.value">
</select>
if language.value = ng-model, it will be selected
with somethin like this in your controller (coffeescript syntax)
Hi there.
I am using this and I am very happy with it.
However I am not sure how to go about selecting the default choice for the picker...
Currently i do this:
But it seems a very nasty way of doing it.. Basically I have my Languages as objects in an array (campaign.Languages) but in order to have the first language selected by default I have to add the first and do ng-repeat on an array with 1 single item which i initialize it to be the first language of the main language array.
There must be a better way of doing this..
The text was updated successfully, but these errors were encountered: