How to return the data in loading service, success function since we are not able to access the scope?