javascript - Multiple Contrllers in UI-router -


i have application uses angularjs , use ui-rourer routing

i need have multiple controller single page, possible ?

this route.js code

  .state(route.appgroup, {                     abstract: true,                     views: {                         'content@': {                             templateurl: global.viewpath + '/index.html',                             controller: 'appctrl'                         }                     }                 }) 

i need

  .state(route.appgroup, {                     abstract: true,                     views: {                         'content@': {                             templateurl: global.viewpath + '/index.html',                             controller: 'appctrl,mainctrl'                         }                     }                 }) 

can help?

each view, has controller.

and while state can have more views (differently named) -

each view can have 1 controller (default created if none passed)

either create more views (to more controllers play)
or move functionality services


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -