当我从Angularjs中的响应绑定数据时,Bootstrap multiselect不起作用

当我从Angularjs中的响应绑定数据时,Bootstrap multiselect不起作用

angular.module('ngvalueSelect', []) .controller('ExampleController', ['$scope','$http', function($scope,$http) { $http.get('https://reqres.in/api/unknown') .then(function (result) { console.log(result.data); $scope.exampleData = result.data; $scope.data = result.data; }) $scope.data = { availableOptions: [ {value: '001', name: 'Hello'}, {value: '002', name: 'integer'}, ] }; console.log( $scope.data ); }]); 
             
{{option.value}}-{{option.name}}

model = {{data.model | json}}

{{option.name}}

model = {{data.model | json}}

jQuery(function () { jQuery('#multiselect').multiselect(); });

两个JSON都具有相同的格式,但是当我硬编码值availableOptions时它工作正常。 当我从响应中获取值时,它不起作用。 任何修复,请帮助我。 TIA。 即使我为选择框尝试了多个标签,但我没有得到下拉列表。它直接显示所有值

我用semantic-ui找到了解决方案。 最后,它成功了。

 angular.module('ngvalueSelect', []) .controller('ExampleController', ['$scope','$http', function($scope,$http) { $http.get('https://reqres.in/api/unknown') .then(function (result) { console.log(result.data); $scope.exampleData = result.data; $scope.data = result.data; }) }]);