Questions tagged [ember-model]

Ember Model (EM) is a simple and lightweight model library for Ember.

Ember Model (EM) is a simple and lightweight model library for Ember. It intentionally supports a limited feature set. The main goal is to provide primitives on top of $.ajax that are required by Ember.

EM is still very much a work in progress, but it's flexible enough to be used in apps today. It was extracted out of an Ember app. Please see the issues section for a list of bugs and planned features.

Github repository

135 questions
0
votes
1 answer

Emberjs linkTo doesnot update collection i.e department.find()

Learning emberjs I am not sure if this is a stackoverflow question or git issue. So I decided to put it on stackoverflow first. Here is my Jsbin (Open in firefox ..not in chrome as raw.github file is used) When I click on "<- All Department" in…
Rigel
  • 882
  • 1
  • 11
  • 32
0
votes
1 answer

How to use model data in template?

I have created FIXTURES using ember-model and I am trying to access it on template, but it is not showing any result if I use {{model.name}}. It is working fine with each helper. I want to access single node of model like {{model.name}} without…
Sachin
  • 2,321
  • 11
  • 31
  • 49
0
votes
1 answer

Using PHP as a Backend with Ember.js

I am trying to use Emberjs with PHP as backend. Here's my app.js, App = Ember.Application.create({}); App.IndexRoute = Ember.Route.extend({ renderTemplate : function(controller) { this.render('MyApp', { controller :…
John Altar
  • 141
  • 2
  • 13
0
votes
2 answers

How can I load a model and immediately have access to it

Say that when I load the page I include a json hash of the current user's info in an injection I load the info: user_data = JSON.parse(user_json) App.Model.load(user_data['id'], user_data) container.typeInjection('controller', 'currentUser',…
gone
  • 4,342
  • 2
  • 24
  • 29
0
votes
3 answers

Issue with Ember Model promises

I'm trying to do some basic stuff with Ember Model but I'm experiencing some weird behaviors with promises. Not sure I understand very well how it's supposed to work. So, I have this route: App.ProfilesIndexRoute = Ember.Route.extend { redirect:…
Vinch
  • 1,551
  • 3
  • 13
  • 15
0
votes
1 answer

Switch from Ember Data FixtureAdapter to Ember Model FixtureAdapter

After I learned that the BasicAdapter in Ember Data has been removed, I decided to switch from Ember Data to Ember Model because the API I work with is not totally RESTful (and I need more flexibility in general). I'm wondering how to "translate"…
Vinch
  • 1,551
  • 3
  • 13
  • 15
0
votes
2 answers

basic nested routes in emberjs

I have this router App.Router.map(function() { this.resource('about', function() { this.route('new'); }); }); and However when…
Jatin
  • 14,112
  • 16
  • 49
  • 78
0
votes
1 answer

associating a model with a route in emberjs

As I understad, a template in emberjs gets it's data from controller. So, it's a controller's job to get hold of model data and present it to the template. The docs here associate a model with a route like this: App.FavoritesRoute =…
0
votes
1 answer

How to fetch relationship with Ember Model if response doesn't include relationship?

It appears that Ember Model expects one of two things, the relationship key in the JSON response contains (1) the data of the records or (2) the ids of the records. The API that I am working with (and that I have no control over) provides neither.…
Bart Jacobs
  • 9,022
  • 7
  • 47
  • 88
0
votes
1 answer

Why does Ember complain when pushing an object onto an Ember array?

I am using Ember RC6.1 with Ember Model. When I set the adapter property of a model class to an instance of Ember Model's RESTAdpater class and perform a findAll, an assertion is thrown for each object that is added to the resulting Ember array. The…
Bart Jacobs
  • 9,022
  • 7
  • 47
  • 88
0
votes
1 answer

Handling errors with the RESTAdapter

How to get the errors returned when calling a RESTAdapter method (by example deleteRecord). I can see this code in the sources but I do not clearly understand. Is there a sample code available providing error handling management with ember-model…
fvisticot
  • 7,936
  • 14
  • 49
  • 79
0
votes
1 answer

Deleting a record with ember-model

I try to delete a record, a DELETE request is sent to the server but the request seems not correct: What is done: DELETE /books + body json format What I expect: DELETE /books/123 + no body What is really expected in ember-model ? How can I achieve…
fvisticot
  • 7,936
  • 14
  • 49
  • 79
0
votes
1 answer

Why {{#if isDirty}} not working as expected with Ember Model? ( with JSBin )

I'm trying to get my template to display a save button when the form is changed. The when the value of an input field is changed, the model is set to isDirty=true, but template tag is not activated. Pertinent Information Using Ember Model ( not…
Taras Mankovski
  • 1,639
  • 3
  • 16
  • 30
0
votes
2 answers

Parse.com manipulate Response Object

I am trying to work Ember with Parse.com using ember-model-parse-adapter by samharnack. I add added a function to make multiple work search(like search engine) for which I have defined a function on cloud using Parse.Cloud.define and run from…
Rigel
  • 882
  • 1
  • 11
  • 32