Please can some one help me to write script runner script to " Copy fix version from parent to sub task while creating sub task ".
There is nothing functionally wrong with your code.
Where did you put it?
Showing/Hiding a field based on the current user is probably best done from the Initialiser.
Here is a simplified version:
import com.atlassian.jira.component.ComponentAccessor
def groupManager = ComponentAccessor.groupManager
def currentUser = ComponentAccessor.jiraAuthenticationContext.loggedInUser
def groupName = 'ut-state'
def isInGroup = groupmanager.isUserInGroup(currentUser, groupName)
getFieldById("customfield_12305").setHidden(isInGroup)
Hi Peter,
As you suggested i have put the code in Initializer but still it is viewable & editable for the mentioned group users.
Kindly help us to fix this
Regards,
Revathy Madhavan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please read-up on the behaviour limitations:
You can't hide a field from the view screen.
And while the field may appear editable, usually, if behaviour is working correctly, when you click on the in-line edit button, it will force the full edit screen to open where the behavior will enforce the field to be hidden.
Hiding fields with behaviours should only be done for the sake of convenience, it will not ensure any sort of privacy or confidentiality. It's quite easy to query this information either in a regular issue navigator or by accessing the REST api.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.