Class DashboardMacroSupport
java.lang.Object
com.atlassian.confluence.plugins.macros.dashboard.DashboardMacroSupport
This support class provides common functionality used by the macros that are used on the dashboard.
-
Constructor Summary
ConstructorsConstructorDescriptionDashboardMacroSupport
(LabelManager labelManager, SpaceManager spaceManager, LocaleManager localeManager, FormatSettingsManager formatSettingsManager, UserAccessor userAccessor, PermissionManager permissionManager, boolean includeArchivedSpaces) -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.Since 3.5.Get an ListBuilder of all spaces the current user can see.javax.servlet.http.HttpServletRequest
There are two possible cases here - You are within an HTTP request thread, in which case the request will be retrieved from a ThreadLocal You are not a 'web related' thread (e.g.protected String
protected UserInterfaceState
protected String
sanitiseSelectedSpacesTab
(String spacesSelectedTab) four cases to sanitise on "new" tab when there are no new spaces "my" tab when there are no favourite spaces "team" tab when there are no teams
-
Constructor Details
-
DashboardMacroSupport
public DashboardMacroSupport(LabelManager labelManager, SpaceManager spaceManager, LocaleManager localeManager, FormatSettingsManager formatSettingsManager, UserAccessor userAccessor, PermissionManager permissionManager, boolean includeArchivedSpaces)
-
-
Method Details
-
getFavouriteSpaces
-
getDateFormatter
-
getNewSpaces
-
getTeamSpaces
-
getPermittedSpaces
Deprecated.Since 3.5. UsegetPermittedSpacesBuilder()
.Get a set of all spaces the current user can see.- Returns:
- all spaces the current user can see
-
getPermittedSpacesBuilder
Get an ListBuilder of all spaces the current user can see.- Returns:
- a ListBuilder of all spaces the current user can see
-
getSelectedTeamLabelName
-
getViewableTeamLabels
-
getUserInterfaceState
-
getSpacesSelectedTab
-
sanitiseSelectedSpacesTab
four cases to sanitise on- "new" tab when there are no new spaces
- "my" tab when there are no favourite spaces
- "team" tab when there are no teams
- Parameters:
spacesSelectedTab
- currently selected tab- Returns:
- spacesSelectedTab if the tab contains spaces, return the tab, else return "all"
-
getRequestParameter
-
getRequest
public javax.servlet.http.HttpServletRequest getRequest()There are two possible cases here -- You are within an HTTP request thread, in which case the request will be retrieved from a ThreadLocal
- You are not a 'web related' thread (e.g. a Long running task) in which case null will be returned.
- Returns:
- The HttpServletRequest associated with the current thread.
-
getAllViewableSpaces
-