Hi People,
how to achieve User Properties through script runner?
under user properties, we have several values like employee First Name Company etc. PFA
Thanks.
Hi,
You can try something like this:
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.user.ApplicationUser
import com.atlassian.jira.user.util.UserManager
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.user.UserPropertyManager
def userManager = ComponentAccessor.getUserManager()
ApplicationUser user = userManager.getUserByName("MBD7C62N")
def userpropertiesManager = ComponentAccessor.getComponent(UserPropertyManager)
def properties = userpropertiesManager.getPropertySet(user).getKeys("jira.meta", "your integer type")
def intType = userpropertiesManager.getPropertySet(user).getType("jira.meta.HRO")
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.