|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object webwork.action.ActionSupport com.atlassian.jira.action.JiraActionSupport com.atlassian.jira.web.action.JiraWebActionSupport
public class JiraWebActionSupport
All web actions should extend this class - it provides basic common functionality for all web actions.
When adding to this class, be sure that what you are adding is used by a large number of actions - otherwise add it to a sub class of this.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface com.atlassian.jira.util.I18nHelper |
---|
I18nHelper.BeanFactory |
Field Summary | |
---|---|
static String |
ISSUE_NOT_FOUND_RESULT
|
static String |
PERMISSION_VIOLATION_RESULT
|
protected javax.servlet.http.HttpServletRequest |
request
|
static String |
RETURN_URL_PARAMETER
|
protected Collection |
savedFilters
|
Fields inherited from class com.atlassian.jira.action.JiraActionSupport |
---|
log |
Fields inherited from class webwork.action.ActionSupport |
---|
command, errorMap, errorMessages |
Fields inherited from interface webwork.action.Action |
---|
ERROR, INPUT, LOGIN, NONE, SUCCESS |
Constructor Summary | |
---|---|
JiraWebActionSupport()
|
Method Summary | |
---|---|
void |
addErrorCollection(ErrorCollection errors)
Populate this ErrorCollection with general and field-specific errors. |
protected String |
forceRedirect(String redirect)
This method will force a server redirect. |
Map |
getAssignableUsers(org.ofbiz.core.entity.GenericValue entity)
|
Map |
getAssignableUsers(org.ofbiz.core.entity.GenericValue project,
org.ofbiz.core.entity.GenericValue issue)
|
protected Collection |
getCachedGroups()
|
ComponentManager |
getComponentManager()
|
ConstantsManager |
getConstantsManager()
|
String |
getDateFormat()
|
String |
getDateTimeFormat()
|
String |
getDescTranslation(org.ofbiz.core.entity.GenericValue issueConstantGV)
|
static ExternalLinkUtil |
getExternalLinkUtils()
|
Field |
getField(String id)
|
Collection |
getFlushedErrorMessages()
Get error messages, then get rid of them. |
protected GlobalPermissionManager |
getGlobalPermissionManager()
|
JiraServiceContext |
getJiraServiceContext()
Provides a service context with the current user which contains this action as its ErrorCollection . |
String |
getLanguage()
|
String |
getNameTranslation(org.ofbiz.core.entity.GenericValue issueConstantGV)
|
OutlookDate |
getOutlookDate()
|
protected PermissionManager |
getPermissionManager()
|
ProjectManager |
getProjectManager()
|
com.opensymphony.module.propertyset.PropertySet |
getPropertySet(org.ofbiz.core.entity.GenericValue gv)
|
String |
getRedirect(String defaultUrl)
Get a definitive result with a redirect upon success. |
User |
getRemoteUser()
|
String |
getReturnUrl()
|
List<String> |
getSearchSortDescriptions(SearchRequest searchRequest)
|
org.ofbiz.core.entity.GenericValue |
getSelectedProject()
Gets the "active" project. |
Project |
getSelectedProjectObject()
|
String |
getServerId()
|
String |
getText(String key)
If called from a JSP page that is not associated with an action, look for key in the default JiraWebActionSupport.properties file |
String |
getTimeFormat()
|
String |
getUserFullName(String username)
|
protected UserProjectHistoryManager |
getUserProjectHistoryManager()
|
VersionManager |
getVersionManager()
|
String |
getWebworkStack()
For debugging JSPs; prints the webwork stack. |
String |
getWebworkStack(String selected)
For debugging JSPs; prints the webwork stack, highlighting the specified node. |
String |
htmlEncode(String encodeMe)
Convenience instance method to call static utility from webwork EL. |
boolean |
isHasIssuePermission(int permissionsId,
org.ofbiz.core.entity.GenericValue issue)
|
boolean |
isHasIssuePermission(String permName,
org.ofbiz.core.entity.GenericValue issue)
|
boolean |
isHasPermission(int permissionsId)
|
boolean |
isHasPermission(String permName)
|
boolean |
isHasPermission(String permName,
org.ofbiz.core.entity.GenericValue entity)
Deprecated. Please use either isHasIssuePermission(String,GenericValue) ,
isHasIssuePermission(int,GenericValue) or isHasProjectPermission(String,GenericValue) ,
isHasProjectPermission(int,GenericValue) . |
boolean |
isHasProjectPermission(int permissionsId,
org.ofbiz.core.entity.GenericValue project)
|
boolean |
isHasProjectPermission(String permName,
org.ofbiz.core.entity.GenericValue project)
|
boolean |
isSystemAdministrator()
|
boolean |
isUserExists(String username)
|
void |
setReturnUrl(String returnUrl)
|
void |
setSelectedProjectId(Long id)
|
Methods inherited from class com.atlassian.jira.action.JiraActionSupport |
---|
addErrorMessages, addErrorMessages, addErrors, addIllegalArgumentException, execute, getActionName, getApplicationProperties, getDefaultResourceBundle, getDelegator, getJiraLocaleUtils, getLocale, getResult, getText, getText, getText, getText, getText, getText, getText, getText0, getUnescapedText, getUserPreferences, getWatcherManager, hasAnyErrors, isEnterprise, isIndexing, isProfessional, isProfessionalOrEnterprise, isStandard, removeKeyOrAddError |
Methods inherited from class webwork.action.ActionSupport |
---|
addError, addErrorMessage, doDefault, doExecute, doValidation, getErrorMessages, getErrors, getHasErrorMessages, getHasErrors, getPropertyEditorMessage, getTexts, getTexts, getTimezone, invalidInput, invokeCommand, isCommand, setCommand, setErrorMessages, setErrors, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.atlassian.jira.util.ErrorCollection |
---|
addError, addErrorMessage, addErrorMessages, addErrors, getErrorMessages, getErrors, hasAnyErrors, setErrorMessages |
Methods inherited from interface webwork.action.CommandDriven |
---|
setCommand |
Field Detail |
---|
public static final String RETURN_URL_PARAMETER
public static final String PERMISSION_VIOLATION_RESULT
public static final String ISSUE_NOT_FOUND_RESULT
protected javax.servlet.http.HttpServletRequest request
protected Collection savedFilters
Constructor Detail |
---|
public JiraWebActionSupport()
Method Detail |
---|
public User getRemoteUser()
getRemoteUser
in class JiraActionSupport
public String getRedirect(String defaultUrl)
Action.ERROR
if there are error messages, otherwise redirects to another URL if
successful. If URL starts with '/', interpreted as context-relative
Since 3.1 now redirects to a the "returnUrl" if one exists. Will clear this value once this occurs
defaultUrl
- default URL to redirect to
protected String forceRedirect(String redirect)
redirect
- redirect URL
Action.NONE
. It'll just redirect to where you've specifiedpublic com.opensymphony.module.propertyset.PropertySet getPropertySet(org.ofbiz.core.entity.GenericValue gv)
public boolean isHasPermission(String permName)
public boolean isHasPermission(int permissionsId)
public boolean isHasIssuePermission(String permName, org.ofbiz.core.entity.GenericValue issue)
public boolean isHasIssuePermission(int permissionsId, org.ofbiz.core.entity.GenericValue issue)
public boolean isHasProjectPermission(String permName, org.ofbiz.core.entity.GenericValue project)
public boolean isHasProjectPermission(int permissionsId, org.ofbiz.core.entity.GenericValue project)
public boolean isHasPermission(String permName, org.ofbiz.core.entity.GenericValue entity)
isHasIssuePermission(String,GenericValue)
,
isHasIssuePermission(int,GenericValue)
or isHasProjectPermission(String,GenericValue)
,
isHasProjectPermission(int,GenericValue)
.
permName
- permission typeentity
- entity to check the permission for, e.g. project, issue
public boolean isSystemAdministrator()
protected GlobalPermissionManager getGlobalPermissionManager()
protected PermissionManager getPermissionManager()
protected UserProjectHistoryManager getUserProjectHistoryManager()
protected Collection getCachedGroups()
public ConstantsManager getConstantsManager()
public boolean isUserExists(String username)
public String getUserFullName(String username)
public Map getAssignableUsers(org.ofbiz.core.entity.GenericValue entity) throws Exception
Exception
public Map getAssignableUsers(org.ofbiz.core.entity.GenericValue project, org.ofbiz.core.entity.GenericValue issue) throws Exception
Exception
public ProjectManager getProjectManager()
public VersionManager getVersionManager()
public String getText(String key)
getText
in interface I18nHelper
getText
in class JiraActionSupport
key
- message resource keypublic void addErrorCollection(ErrorCollection errors)
ErrorCollection
addErrorCollection
in interface ErrorCollection
errors
- ErrorCollection whose errors/messages we obtain.public Field getField(String id)
public List<String> getSearchSortDescriptions(SearchRequest searchRequest)
public ComponentManager getComponentManager()
public OutlookDate getOutlookDate()
public String getNameTranslation(org.ofbiz.core.entity.GenericValue issueConstantGV)
public String getDescTranslation(org.ofbiz.core.entity.GenericValue issueConstantGV)
public String getReturnUrl()
public void setReturnUrl(String returnUrl)
public Collection getFlushedErrorMessages()
ErrorCollection
getFlushedErrorMessages
in interface ErrorCollection
public String getLanguage() throws IOException
IOException
public Project getSelectedProjectObject()
public org.ofbiz.core.entity.GenericValue getSelectedProject()
GenericValue
as a projectpublic void setSelectedProjectId(Long id)
public String getDateFormat()
public String getDateTimeFormat()
public String getTimeFormat()
public static ExternalLinkUtil getExternalLinkUtils()
public String getWebworkStack(String selected)
selected
- selected value in the webwork stack
public String getWebworkStack()
public String getServerId()
public JiraServiceContext getJiraServiceContext()
ErrorCollection
.
public String htmlEncode(String encodeMe)
encodeMe
- a String to be HTML encoded.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |