How to get related model data in HBS and JS?

Hi all
I am in opportunity record view and i want to get the related module data, like related calls,meetings,contacts etc related to the current opportunity record.

Any help will be appreciated.
Parents
  • Something like this?  

    var request =  App.api.call('read',app.api.buildURL('Accounts/') + self.model.get('account_id'));
                    request.xhr.done(function(data){
                        // console.log(data);
                        // alert(data.name);
                        self.model.set('test_field_c', data.name);
                    });

Reply
  • Something like this?  

    var request =  App.api.call('read',app.api.buildURL('Accounts/') + self.model.get('account_id'));
                    request.xhr.done(function(data){
                        // console.log(data);
                        // alert(data.name);
                        self.model.set('test_field_c', data.name);
                    });

Children
No Data