Skip to content

state navigation not happening #69

@xtreme1397

Description

@xtreme1397

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions