Hi Daniel

There should be no trouble using the same controller for different routes. 
  Note that you will get a different instance of the controller for each 
route , each with a separate scope, so unless you use the service to share 
state, they will will not share state between them.  No idea about the 404 
error btw.

Michael

On Thursday, May 22, 2014 2:52:52 AM UTC+10, Daniel Lopez wrote:
>
> Hi,
>
> I have a situation, I'm creating an app that will show some charts and 
> initially i've insert all the code in the same file, but now i'm trying to 
> split it in some partial views as shown in angular tutorial. with this in 
> mind i have tryed to create a route and the controllers but a question 
> emarged:
>  -  can i use the same controller for all routes?
>
> I'm asking this because my controller receives the json variable from my 
> service and arranges all the data, i could duplicate all the controller 
> code to another one but it's all the same code in two controllers.
>
> Using the same controller i try to call the partial views (i'm using 
> jquery to create tabs) but when i select the tab i want it only shows me 
> the link to where it should go but the view itself won't change and the 
> function i have created to slideToggle a panel won't work and i have call 
> that js file in my index.
>
> Can someone help me with this?
>
> Thk
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to