我正在努力處理動態的細分市場。這裏是我的代碼沒有emberdata的動態細分市場
App.Router.map(function(){
this.resource('stuff', {path: '/stuff/:stuff_id'}, function() {
this.route('make');
this.route('edit');
this.route('delete');
this.route('history');
});
});
App.StuffRoute = Ember.Route.extend({
model: function(param) {
},
setupController: function(){
},
renderTemplate: function() {
}
});
App.StuffView= Ember.View.extend({
defaultTemplate: Ember.Handlebars.compile(stuffTemplate)
});
App.StuffController = Ember.Controller.extend();
我應該把什麼在StaffRoute
,我停止獲取No route matched the URL 'crisis'
錯誤的模型?對於localhost/#stuff
以及如何正確設置動態段部分?我唯一的問題是,所有的例子都使用了不支持生產的ember-data,我不想使用它。