150
rated 0 times
[
156]
[
6]
/ answers: 1 / hits: 20826
/ 12 Years ago, thu, february 14, 2013, 12:00:00
Cheers!
I have some model, and one attribute of it is an array, but for some reasons (I use mongoDB on the server and it's problem with embedded models and ember-data) I can't do somthing like this:
App.Foo = DS.Model.extend({
...
numbers: DS.hasMany('App.Bar')
)};
App.Bar = DS.Model.extend({
...
number: DS.attr('number')
});
I need something like this:
App.Bar = DS.Model.extend({
numbers: DS.attr('array')
});
But there is no array type of attributes in ember-data, how to be?
More From » ember.js