2017-12-01 4 views
0

Ich habe ein Problem mit dem Dropdown-Menü in einem Angular.JS-Format.AngularJS Dropdown-Optionen Probleme

Ich sollte die Optionen unter dem Dropdown-Menü anzeigen, das ist das "Update" und "Löschen". Leider hat es nichts gezeigt.

<ui-select ng-model="ctrl.OptionChoices" title="Update or Delete"> 

<ui-select-match placeholder="Choose the option for the item">{{select.option.name}}</ui-select-match> 

<ui-select-choices repeat="existingUOMx.UnitOfMeasurementID as existingUOMx in ctrl.existingUOMsx | filter: $select.search"> 

<small ng-bind-html="existingUOMx.UnitOfMeasurementID | highlight: $select.search"> - </small> 

<span ng-bind-html="existingUOMx.Description | highlight: $select.search"></span> 

</ui-select-choices> 

</ui-select> 

Option-menu.js

app.controller('myCtrl', function $scope) { 

var option = this; 
$scope.optionChoice = 0; // choice int are 0 
$scope.toggleOption = true; 
$scope.option = [ 
    { name: "Update" }, 
    { name: "Delete" }, 

] 

Vielen Dank für die Hilfe

Antwort

2

Sie so verwenden können, für Drop-Down-Wert

<select> 
<option>Choose the option for the item</option> 
    <option ng-repeat="ItemsPerPageCount in option" value="{{ItemsPerPageCount.name}}" ng-bind="ItemsPerPageCount.name"></option> 
</select> 
+0

Hallo Brian Nebres, ist diese Arbeit zu binden Sie – Vinoth

+0

Entschuldigung für die späte Antwort. Ja, es hat mir geholfen und gearbeitet. Vielen Dank! –