Hi,
we are currently testing JIRA 5.0.6. We migrated our 4.4.3 prod JIRA to the new version and encounter a problem now.
The plugin "Set Issue Security Level Plugin" was used to set a security level for a customer ticket based on his customer group. Unfortunately, this is not working anymore. Creating a ticket with post function
Set the issue security level - Set the issue security level based on user's specified group
does not work - nothing happens when clicking on "Create".
We are using the original version 1.0 which worked from 3.13 until 4.4.3.
I found
http://forums.atlassian.com/thread.jspa?forumID=100&threadID=42900
but this does not help; I don't know how to "build" this new version.
I know that a few people are still using this plugin. What are your solutions for 5.x incompatibility?
Community moderators have prevented the ability to post new answers.
Problem solved by creating the plugin completely new using new methods.
Hi Jan,
Could you please share the plug-in details. We are stuck with our JIRA migration due to this plug-in.
Please help.
Thanks,
Sanu P Soman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
you can build this plugin using the instructions at
https://github.com/processone/jira-security-level-plugin
after building the jar, just place it at /home/jira/jira/jira-standalone/atlassian-jira/WEB-INF/lib
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
package securitylevel.jira.plugin.postfunction; import com.atlassian.crowd.embedded.api.User; import com.atlassian.jira.component.ComponentAccessor; import com.atlassian.jira.issue.IssueManager; import com.atlassian.jira.issue.MutableIssue; import com.atlassian.jira.issue.security.IssueSecurityLevel; import com.atlassian.jira.issue.security.IssueSecurityLevelManager; import com.atlassian.jira.security.groups.GroupManager; import com.atlassian.jira.event.type.EventDispatchOption; import com.opensymphony.module.propertyset.PropertySet; import com.opensymphony.workflow.FunctionProvider; import java.util.Collection; import java.util.Map; public class SetSecurityLevelFunction implements FunctionProvider { private final IssueSecurityLevelManager issueSecurityLevelManager = ComponentAccessor .getIssueSecurityLevelManager(); private final GroupManager groupManager = ComponentAccessor .getGroupManager(); @SuppressWarnings("rawtypes") public void execute(Map transientVars, Map args, PropertySet ps) { MutableIssue issue = (MutableIssue) transientVars.get("issue"); User reporter = issue.getReporterUser(); Collection<String> reporterGroups = groupManager .getGroupNamesForUser(reporter.getName()); try { Collection<IssueSecurityLevel> issueSecurityLevels = issueSecurityLevelManager .getUsersSecurityLevels(issue.getProjectObject(), reporter); for (String groupName : reporterGroups) { for (IssueSecurityLevel securityLevel : issueSecurityLevels) { String securityLevelName = securityLevel.getName(); if (securityLevelName.startsWith("#") && securityLevelName.subSequence(1, securityLevelName.length()).equals( groupName)) { issue.setSecurityLevelId(securityLevel.getId()); saveIssue(issue); return; } } } } catch (Exception e) { e.printStackTrace(); } } private void saveIssue(MutableIssue issue) { IssueManager issueManager = ComponentAccessor.getIssueManager(); User user = ComponentAccessor.getJiraAuthenticationContext().getLoggedInUser(); boolean sendEmail = false; issueManager.updateIssue(user, issue, EventDispatchOption.DO_NOT_DISPATCH, sendEmail); } }
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.
Hi everyone,
could You please provide a desired functionality or link to this plugin homepage?
We would like to implement this functionality in one of our free plugins.
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.
Hi again,
Anybody, would to provide a source code of set issue security level plugin, that works on jira 5.x? Or, maybe exists a good alternative of it?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi como
> Problem solved by creating the plugin completely new using new methods.
Would you publish a working version of this plugin? We urgent need of this functionality and can't migrate to actual version of jira without same actions. Will glad to received your answer and more glad to get working "set issue security level" plugin. :)
Regards
Peter
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Community moderators have prevented the ability to post new answers.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.