This repository has been archived by the owner on Sep 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
md-autocomplete : $http promise fails to work #1798
Milestone
Comments
Workaround is like this $scope.loadSkillTags = function (query) {
var data = {qData: query};
return SkillService.querySkills(data).then(function(response) {
return response.data;
});
}; |
@robertmesserle - I think we should check the return value from the promise and check it is is the standard $http |
Agreed, will add this when I get a chance.
|
Great. Thx. |
smehrbrodt
added a commit
to digitaldeacon/memberhive1
that referenced
this issue
Apr 29, 2015
Needed to switch to angular-material master branch because of angular/material#1798 Should switch back to release branch when 0.10 is released (due May 1st)
would be great if the docs get updated too to support promises is a great thing and it's not mentioned in md-items |
md-autocomplete : $http promise never fails to work, it will work perfectly. .then is a part of $http service Kindly refer the post: Live code is available in the following post: http://stackoverflow.com/questions/35652828/http-issue-values-cant-be-returned-before-a-promise-is-resolved-in-angular-m |
|
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
When the items are returned from an $http promise the md-autocomplete fails to work.
From a $http promise the data items are returned as response.data. md-autocomplete expects the data is passed back as an array.
The array is contained in the response.data object but md-autocomplete is reading response as the array which fails.
The text was updated successfully, but these errors were encountered: