Hi Reza,

Hmm, Somehow my earlier response to this got lost. Well, I need to type it 
up again then :)
I refactored the sample a bit, so it pushed all the "business" logic to 
where it belongs, inside the service. In your case you can do the same, and 
inject the service(s) where you need them. The sample has just 1 service, 
but you can have as many as you need. Also, remember, you can inject 
services into services. Ideally The components should have no logic at all. 
they are just there to hook up your view. 
Check the repo, to see the changes I did.

Regards
Sander

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to