...
resultTripMethod: function(){
viewRoude(directionService, directionRenderer, this.from, this.to, function (result) {
console.log(result)
}.bind(this));
}
...
function viewRoude(directionService, directionRenderer, start, end, callback){
var request = {
origin: new google.maps.LatLng(start.pos.lat, start.pos.lng),
destination: new google.maps.LatLng(end.pos.lat, end.pos.lng),
travelMode: google.maps.TravelMode.DRIVING
};
directionService.route(request, function(result, status){
if(status == google.maps.DirectionsStatus.OK){
callback(result);
}
});
}
Может быть так?