use of io.jmix.ui.app.navigation.notfoundwindow.NotFoundScreen in project jmix by jmix-framework.
the class ScreenNavigationHandler method handle404.
protected void handle404(String route, AppUI ui) {
MapScreenOptions options = new MapScreenOptions(ParamsMap.of("requestedRoute", route));
NotFoundScreen notFoundScreen = ui.getScreens().create(NotFoundScreen.class, OpenMode.NEW_TAB, options);
NavigationState state = new NavigationState(ui.getUrlRouting().getState().getRoot(), "", route, Collections.emptyMap());
((WindowImpl) notFoundScreen.getWindow()).setResolvedState(state);
notFoundScreen.show();
}
Aggregations