Skip to content

Commit

Permalink
improved breadcrumbs handling for "self" pages
Browse files Browse the repository at this point in the history
  • Loading branch information
1azyman committed Apr 11, 2016
1 parent 85e32f3 commit 5cf4f3f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
Expand Up @@ -1457,6 +1457,13 @@ public AdminGuiConfigurationType loadAdminGuiConfiguration() {
public void redirectBack() {
List<Breadcrumb> breadcrumbs = getSessionStorage().getBreadcrumbs();
if (breadcrumbs.size() < 2) {
if (WebComponentUtil.isAuthorized(AuthorizationConstants.AUTZ_UI_DASHBOARD_URL,
AuthorizationConstants.AUTZ_UI_HOME_ALL_URL)) {
setResponsePage(PageDashboard.class);
} else {
setResponsePage(PageSelfDashboard.class);
}

return;
}

Expand Down
Expand Up @@ -398,12 +398,7 @@ private List<PasswordAccountDto> getSelectedAccountsList(){
return selectedAccountList;
}
private void onCancelPerformed(AjaxRequestTarget target) {
if (WebComponentUtil.isAuthorized(AuthorizationConstants.AUTZ_UI_DASHBOARD_URL,
AuthorizationConstants.AUTZ_UI_HOME_ALL_URL)) {
setResponsePage(PageDashboard.class);
} else {
setResponsePage(PageSelfDashboard.class);
}
redirectBack();
}

private List<ShadowType> loadShadowTypeList() {
Expand Down

0 comments on commit 5cf4f3f

Please sign in to comment.