Skip to content

state navigation not happening #69

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
xtreme1397 opened this issue Apr 19, 2018 · 1 comment
Open

state navigation not happening #69

xtreme1397 opened this issue Apr 19, 2018 · 1 comment

Comments

@xtreme1397
Copy link

Hi all,
There is some issue i am facing in state navigation , i have two module lets say main module and list module.where list module is child of main module and getting loaded lazily.

but when i am trying to change the state from child module to parent module its not happening.
below is the snippet of code i am trying to do.

main module route

const mainState = {
name: "main",
url: "/main",
isLoginRequired: true,
component: "mainComponent"
};
const homeState = {
parent: 'main',
name: "home",
url: '/home',
component: "homeComponent",
isLoginRequired: true,
lazyLoad: ($transition$) => {
return moduleResolver($transition$, () =>
import('../home/home.module'), 'HOME_MODULE');
}
};

const canvasListState = {
parent: 'main',
name: "canvasList.**",
url: '/canvas-list/:projectCode?viewType',
component: "listComponent",
isLoginRequired: true,
lazyLoad: ($transition$) => {
return moduleResolver($transition$, () =>
import('../canvas/list/list.module'), 'LIST_MODULE');
}
};

const drawCanvasState = {
parent: "main",
name: "drawCanvas.**",
url: '/draw-canvas',
lazyLoad: ($transition$) => {
return moduleResolver($transition$, () =>
import('../canvas/draw/draw.module'), 'DRAW_CANVAS_MODULE');
}
};

canvaslist module route
const canvasListState = {
parent: 'main',
name: "canvasList",
url: "/canvas-list/:projectCode?viewType",
params: {
redirecturi: null,
projectCode: null,
viewType: null
},
accessCode: ENUM.ACCESS_CONTROL_LIST.CANVAS_VIEW,
component: "listComponent"
};

now from listComponent if i am saying $state.go('main.drawCanvas.compose').then its not navigating anymore.but if i say $state.go('main') then navigation is getting triggered.

@xtreme1397
Copy link
Author

any update?please help me out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant