public class DeleteComment extends AbstractIssueSelectAction
JiraWebActionSupport.MessageType
ErrorCollection.Reason
I18nHelper.BeanFactory
ISSUE_PERMISSION_ERROR, PREPOPULATED_ISSUE_OBJECT
attachmentManager
projectManager
ISSUE_NOT_FOUND_RESULT, PERMISSION_VIOLATION_RESULT, request, RETURN_URL_PARAMETER, savedFilters, SECURITY_BREACH_RESULT
log
Constructor and Description |
---|
DeleteComment(FieldScreenRendererFactory fieldScreenRendererFactory,
CommentService commentService) |
Modifier and Type | Method and Description |
---|---|
String |
doDefault()
Handles the initial request to delete a comment coming from the user.
|
protected String |
doExecute()
Handles a request to delete a comment.
|
String |
getCommentAuthorKey() |
Long |
getCommentId()
Gets the id of the comment to be deleted.
|
Comment |
getCommentObject() |
String |
getCommentUpdateAuthorKey() |
FieldScreenRenderLayoutItem |
getFieldScreenRendererLayoutItemForField(OrderableField field) |
protected FieldScreenRenderer |
getFieldScreenRendererWithAllFields() |
String |
getIssuePath()
Gets the relative path to the current issue.
|
String |
getRenderedContent() |
void |
setCommentId(Long id)
Sets the id of the comment to be deleted.
|
addErrorMessage, assertIssueIsValid, cameFromIssue, cameFromParent, getId, getIssue, getIssueObject, getIssueObjectWithoutDatabaseRead, getKey, getLayoutBean, getMutableIssue, getParentIssueObject, getProject, getProjectObject, getSecurityLevel, getSubTaskManager, getSummaryIssue, getViewIssueKey, getViewUrl, isEditable, isEditable, isHasEditIssuePermission, isIssueExists, isIssueValid, isSubTask, isSubTaskCreatable, isWorkflowAllowsEdit, redirectToView, refreshIssueObject, setId, setIssueObject, setKey, setViewIssueKey
addIssueToHistory, getAttachmentManager, getCurrentDateTimeInUsersTimezone, getCurrentFailedLoginCount, getCurrentJQL, getCustomFieldManager, getDaysPerWeek, getEverLoggedIn, getFormToken, getHoursPerDay, getIssueManager, getLastFailedLogin, getLastLogin, getLoginCount, getPossibleVersions, getPossibleVersionsReleasedFirst, getPrettyDuration, getPreviousLogin, getSearchRequest, getSelectedIssueId, getSessionPagerFilterManager, getSessionSearchRequestManager, getSessionSearchRequestManagerFactory, getSessionSelectedIssueManager, getTotalFailedLoginCount, getUrlEncoded, getWorkflow, getWorkflowTransitionDescription, getWorkflowTransitionDisplayName, isCustomFieldHidden, isElevatedSecurityCheckRequired, isFieldHidden, isFieldHidden, isTimeTrackingEnabled, setFormToken, setSearchRequest, setSelectedIssueId, updateSearchRequest
getBrowsableProjects, getSelectedProjectId, setSelectedProject, setSelectedProject
addError, addErrorCollection, addErrorMessage, addErrorMessageByKeyIfAbsent, addErrorMessageIfAbsent, addMessageToResponse, addReason, addReasons, forceRedirect, getAdministratorContactLink, getApplicationProperties, getAuthorizationSupport, getConglomerateCookieValue, getConstantsManager, getDateFormat, getDateTimeFormat, getDateTimeFormatter, getDescTranslation, getDescTranslation, getDmyDateFormatter, getEmptyResponse, getErrorMessages, getErrors, getField, getFlushedErrorMessages, getGlobalPermissionManager, getHint, getHintManager, getHttpRequest, getHttpResponse, getHttpSession, getJiraContactHelper, getJiraServiceContext, getLanguage, getLoggedInApplicationUser, getLoggedInUser, getNameTranslation, getNameTranslation, getOutlookDate, getPermissionManager, getProjectManager, getRandomHint, getReasons, getRedirect, getRedirect, getRedirectSanitiser, getRequestSourceType, getReturnUrl, getReturnUrlForCancelLink, getSearchSortDescriptions, getSelectedProject, getSelectedProjectObject, getServerId, getServletContext, getTimeFormat, getUriValidator, getUserFullName, getUserManager, getUserProjectHistoryManager, getVersionManager, getWebworkStack, getWebworkStack, getXsrfToken, hasErrorMessage, hasErrorMessageByKey, hasGlobalPermission, hasGlobalPermission, hasIssuePermission, hasIssuePermission, hasIssuePermission, hasPermission, hasProjectPermission, hasProjectPermission, htmlEncode, insertContextPath, isInlineDialogMode, isSystemAdministrator, isUserExists, isUserExistsByKey, isUserExistsByName, returnComplete, returnComplete, returnCompleteWithInlineRedirect, returnCompleteWithInlineRedirectAndMsg, returnCompleteWithInlineRedirectAndMsg, returnMsgToUser, returnMsgToUser, setConglomerateCookieValue, setInline, setReasons, setReturnUrl, setSelectedProjectId, tagMauEventWithApplication, tagMauEventWithProject, urlEncode
addErrorMessages, addErrorMessages, addErrors, addIllegalArgumentException, execute, getActionName, getComponentInstanceOfType, getDefaultResourceBundle, getI18nHelper, getKeysForPrefix, getLocale, getOfBizDelegator, getResourceBundle, getResult, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getText, getUnescapedText, getUntransformedRawText, getUserPreferences, hasAnyErrors, isIndexing, isKeyDefined, removeKeyOrAddError
addError, doValidation, getCommandName, getHasErrorMessages, getHasErrors, getPropertyEditorMessage, getTexts, getTexts, getTimezone, invalidInput, invokeCommand, isCommand, setCommand, setErrorMessages, setErrors, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getLoggedInApplicationUser
addError, addErrorMessages, addErrors, hasAnyErrors, setErrorMessages
public DeleteComment(FieldScreenRendererFactory fieldScreenRendererFactory, CommentService commentService)
public String doDefault()
It will return the view to render the confirm delete comment form, if the user is authorised to delete the comment.
doDefault
in class webwork.action.ActionSupport
INPUT
),
if the user has authorisation to delete the comment.
Otherwise, ERROR_NO_PERMISSION
will be returned so that a screen with an error message can be
rendered.
protected String doExecute() throws Exception
It will delete the comment and redirect the user to the current issue if the user is authorised to the delete the comment and there are no input errors.
doExecute
in class webwork.action.ActionSupport
ERROR_NO_PERMISSION
will be returned if the user is not authorised to delete the comment,
so that a screen with an error message can be rendered.
Exception
public void setCommentId(Long id)
id
- The id of the comment to be deleted.public Long getCommentId()
public String getIssuePath()
AbstractIssueSelectAction
context path
.getIssuePath
in class AbstractIssueSelectAction
public String getRenderedContent()
public FieldScreenRenderLayoutItem getFieldScreenRendererLayoutItemForField(OrderableField field)
protected FieldScreenRenderer getFieldScreenRendererWithAllFields()
public Comment getCommentObject()
public String getCommentAuthorKey()
public String getCommentUpdateAuthorKey()
Copyright © 2002-2022 Atlassian. All Rights Reserved.