-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Description
Example:
Schedule = Backbone.Model.extend({
parse: function (attributes) {
attributes.at = moment(attributes.at);
return attributes;
}
});
Agenda = Backbone.NestedModel.extend({
relations: [
{
type: "one",
key: "schedule",
relatedModel: function () { return Schedule }
}
],
parse: function (attributes) {
attributes.created_at = moment(attributes.created_at);
return attributes;
}
});
new Agenda(window.agenda, { parse: true });Agenda.prototype.parse is called but Schedule.prototype.parse don't.
Do you think that makes sense to propagate the options from the higher model to lower models?
Metadata
Metadata
Assignees
Labels
No labels