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

  • Home
  • SEARCH
  • 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 9133989
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T08:34:59+00:00 2026-06-17T08:34:59+00:00

Using the last version of ember-js and ember-data, I got an issue when deleting

  • 0

Using the last version of ember-js and ember-data, I got an issue when deleting a record.

My route :

App.ListContactsRoute = Em.Route.extend({
    model: function() {
        App.Contact.find();
    },
    setupController: function(controller, model) {
        controller.set('contacts', model);
    }
});

App.EditContactRoute = Em.Route.extend({
    setupController: function(controller, model) {
        this.transaction = controller.get('store').transaction();
        this.transaction.add(model);
        controller.set('content', model);
        controller.set('organizations', App.Organization.find());
    },
    events: {
        delete: function(contact) {
            contact.deleteRecord();
            this.transaction.commit();
            this.transaction = null;
            this.transitionTo("listContacts");
        },
        save: function(contact) {
            this.transaction.commit();
            this.transaction = null;
            this.transitionTo("editContact", contact);
        }
    }
});

When deleting a contact, I’m going back to the ListContactsRoute, so a call is made to the API wich returns me a list of contacts. At this point, the deleted contact hasn’t been deleted on the server yet.

In result, the deleted contact is still present on my contacts list template. Here’s the error :

"Uncaught Error: Attempted to handle event `loadedData` on <App.Contact:ember469:null> while in state rootState.deleted.inFlight. Called with undefined"

Am I doing something wrong or is there a way to fix this ?

  • 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-17T08:35:00+00:00Added an answer on June 17, 2026 at 8:35 am

    The record is no longer part of the this.transaction, once you commit a transaction a record is moved to the store default transaction. To reflect your deletion action, you need to commit the store.

    contact.deleteRecord()
    App.store.commit();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using the last version of Smarty, I'm tring to register a block but
I am using old good RichEdit control with last version of VB.NET I want
I am very new to nservicebus. I am using version 3.0.1, the last one
Currently I am using the Last.fm api to return concert data (returns a hash)
I want fetch last record using hibernate criteria Can u help me?
How do I close (using code) the last created CView in my MDI app.
I've got some of the following code: https://gist.github.com/c111cf9a240a078c9f6a (in rails) I'm using ember-latest: //
Using bootstrap Version 2.1.1 Using last chosen I'm experimenting a visual glitch when the
Is it possible to request last version of App from Android Market via API
I'm using the last version of Ubuntu which come with the gcc 4.4.5 version.

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.