2013-07-24 2 views

답변

1

응용 프로그램 컨트롤러 : 아래

App.ApplicationController = Ember.ObjectController.extend({ 

    findPersonById: function(id) { 
    ..... 
    .... 
    } 
}); 

는 의견 컨트롤러 내부 응용 프로그램 제어 기능에 액세스 할 수있는 방법입니다.

댓글 컨트롤러

App.CommentsController = Ember.ArrayController.extend({ 

    needs: ["application"], 

    getComments: function() { 

    var person = this.get("controllers.application").findPersonById(id); 
    .... 
    .... 
    } 

}); 
관련 문제