com.pyxis.greenhopper.jira.fields
Class Assignee

java.lang.Object
  extended by com.pyxis.greenhopper.jira.fields.AbstractIssueField
      extended by com.pyxis.greenhopper.jira.fields.AbstractSelectField
          extended by com.pyxis.greenhopper.jira.fields.Assignee
All Implemented Interfaces:
IssueField

public final class Assignee
extends AbstractSelectField


Field Summary
static java.lang.String AUTO_ASSIGN
           
 
Fields inherited from class com.pyxis.greenhopper.jira.fields.AbstractIssueField
GREENHOPPER_PLUGIN, GROUP_PICKER, id, idLong, label, log, MULTI_GROUP_PICKER, MULTI_SELECT, MULTI_USER_PICKER, NUMBER, SELECT, TEXT, TEXT_AREA, TEXT_FIELD, USER_PICKER
 
Constructor Summary
Assignee(PermissionService permissionService)
           
 
Method Summary
 boolean canEdit(BoardIssue boardIssue)
           
 java.util.LinkedList<FieldOption> getAllAvailableValuesForSelect(BoardIssue boardIssue)
           
 java.lang.String getCreateTemplate()
           
 java.lang.String getDefaultAssignee(com.atlassian.jira.project.Project project, com.atlassian.jira.bc.project.component.ProjectComponent component)
           
 java.lang.String getDefaultDisplayValue(BoardIssue boardIssue)
           
 java.lang.Object getDefaultValue(BoardIssue boardIssue)
           
 java.lang.String getDisplayTemplate()
           
 java.lang.String getDisplayValue(BoardIssue boardIssue)
           
 java.lang.String getEditTemplate()
           
 java.lang.String getInputType()
           
 java.lang.String getJsonDisplayTemplate()
          Temporary hack while transitioning the field VMs to JSON.
 java.lang.String getLink(BoardIssue boardIssue, java.lang.String value)
           
 int getMinQueryLength()
           
 java.lang.String getRestUrl()
           
 java.lang.String getTooltipValue(BoardIssue boardIssue)
           
 java.lang.Object getValue(BoardIssue boardIssue)
           
 java.lang.Object getValueFromString(java.lang.String values)
           
 boolean isClickable(BoardIssue boardIssue)
          This looks a little weird at the first glance, but the point is that if the user that's been assigned to the issue for some reason doesn't have the assign permission anymore, there's no assignee board for him, which means we don't want to allow someone to click on the assignee field (which would link there).
 void updateValue(BoardIssue boardIssue, java.lang.String newValue)
           
 
Methods inherited from class com.pyxis.greenhopper.jira.fields.AbstractSelectField
doValidate, getUpdateTemplate, lines, weight
 
Methods inherited from class com.pyxis.greenhopper.jira.fields.AbstractIssueField
equals, getCssType, getId, getIdAsLong, getLabel, getTransitionTemplate, hashCode, isCorner, isCustomField, validate
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

AUTO_ASSIGN

public static final java.lang.String AUTO_ASSIGN
See Also:
Constant Field Values
Constructor Detail

Assignee

public Assignee(PermissionService permissionService)
Method Detail

getDisplayValue

public java.lang.String getDisplayValue(BoardIssue boardIssue)

getValue

public java.lang.Object getValue(BoardIssue boardIssue)

getDefaultDisplayValue

public java.lang.String getDefaultDisplayValue(BoardIssue boardIssue)

getDefaultValue

public java.lang.Object getDefaultValue(BoardIssue boardIssue)

getTooltipValue

public java.lang.String getTooltipValue(BoardIssue boardIssue)

updateValue

public void updateValue(BoardIssue boardIssue,
                        java.lang.String newValue)
                 throws GreenHopperException,
                        java.lang.Exception
Throws:
GreenHopperException
java.lang.Exception

getAllAvailableValuesForSelect

public java.util.LinkedList<FieldOption> getAllAvailableValuesForSelect(BoardIssue boardIssue)
Specified by:
getAllAvailableValuesForSelect in class AbstractSelectField

canEdit

public boolean canEdit(BoardIssue boardIssue)

getDefaultAssignee

public java.lang.String getDefaultAssignee(com.atlassian.jira.project.Project project,
                                           com.atlassian.jira.bc.project.component.ProjectComponent component)

getDisplayTemplate

public java.lang.String getDisplayTemplate()
Specified by:
getDisplayTemplate in interface IssueField
Overrides:
getDisplayTemplate in class AbstractSelectField

getCreateTemplate

public java.lang.String getCreateTemplate()
Specified by:
getCreateTemplate in interface IssueField
Overrides:
getCreateTemplate in class AbstractSelectField

getJsonDisplayTemplate

public java.lang.String getJsonDisplayTemplate()
Description copied from class: AbstractIssueField
Temporary hack while transitioning the field VMs to JSON. Once all fields have JSON templates, this can be deleted.

Specified by:
getJsonDisplayTemplate in interface IssueField
Overrides:
getJsonDisplayTemplate in class AbstractIssueField

getEditTemplate

public java.lang.String getEditTemplate()
Specified by:
getEditTemplate in interface IssueField
Overrides:
getEditTemplate in class AbstractSelectField

getRestUrl

public java.lang.String getRestUrl()

getMinQueryLength

public int getMinQueryLength()

getInputType

public java.lang.String getInputType()
Specified by:
getInputType in interface IssueField
Overrides:
getInputType in class AbstractSelectField

getValueFromString

public java.lang.Object getValueFromString(java.lang.String values)
Specified by:
getValueFromString in interface IssueField
Overrides:
getValueFromString in class AbstractSelectField

getLink

public java.lang.String getLink(BoardIssue boardIssue,
                                java.lang.String value)
Specified by:
getLink in interface IssueField
Overrides:
getLink in class AbstractIssueField

isClickable

public boolean isClickable(BoardIssue boardIssue)
This looks a little weird at the first glance, but the point is that if the user that's been assigned to the issue for some reason doesn't have the assign permission anymore, there's no assignee board for him, which means we don't want to allow someone to click on the assignee field (which would link there).

Specified by:
isClickable in interface IssueField
Overrides:
isClickable in class AbstractIssueField


Copyright © 2007-2011 Atlassian. All Rights Reserved.