Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9325021
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 19, 20262026-06-19T04:44:36+00:00 2026-06-19T04:44:36+00:00

When using the deferred method offered by angularjs and querying the database local storage,

  • 0

When using the deferred method offered by angularjs and querying the database local storage, the “resolve” doesn’t seem to work. See the following example. The “then” action is never fired.
When trying with a setTimeout instead of the “Person.all()” instruction, it works.

var defer = $q.deferred();

Person.all().list(null, function (persons) {
   defer.resolve(persons);
});

defer.promise.then(function (persons) {
   console.log('resolved');
});

Thanks for helping.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-19T04:44:37+00:00Added an answer on June 19, 2026 at 4:44 am

    For Angularjs’s promise, then only fires in digest cycle.

    If your Person object is in your service, you can inject $rootScope and
    call $apply() against it to let then fire.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I can't seem to wrap my head around the deferred method of the imagesLoaded
I'm using jQuery deferred objects so I can pull data from multiple sources ,
I'm having a bit of trouble with jQuery Deferred. I'm using a jQuery ajax
using this http://bl.ocks.org/950642 we can see how to add images to nodes, the question
Using Location.getBearing(); I seem to get randomly changing bearings. Aka, I can turn the
http://jsfiddle.net/f4hmL/235/ function showData() { alert(boop!); } function method1() { var dfd = $.Deferred(); setTimeout(dfd.resolve(),
I'm using the extension menthod Reverse(), but it does not seem to be doing
I have been reading a lot about JQuery's deferred object. And I can see
If you call the IgnoreNullItems extension method in the sammple code below the deferred
I'm using some deferred functions with the .done so, I'm having something like that:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.