can you give us a screen shot how you are adding postfunction to your workflow?
The Problem is solved now.
here we are adding the configured user to the watcher list based on the configured project and configure supplier (custom field).
The problem was with module where we are checking the configure supplier is equal to the issue supplier.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
following code worked for us
WatcherManager wm = ComponentAccessor.getWatcherManager(); wm.startWatching(user, issue);
following code what we used in our jira 5.0
private UserAssociationStore userAssociationStore = ComponentManager.getComponentInstanceOfType(UserAssociationStore.class); public static final String ASSOCIATION_TYPE = "WatchIssue"; userAssociationStore.createAssociation(ASSOCIATION_TYPE,user, issue.getGenericValue());
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you so much.
i used the same code but when i build the post function plugin it is not working.
Do i need to make any changes in jira before adding user to watcher list.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
we are also using same jira version and it is working foe us!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
check my answers, i have updated!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You can use JJupin plugin to make your work easier. To add the user to watchers, you can do it in 3 lines of SIL code:
if (arrayElementExists(watchers, currentUser()) == false) { watchers = arrayAddElement(watchers, currentUser()); }
Yes, that's all! You can read more about JJupin here: http://confluence.kepler-rominfo.com/display/JJUPIN/JJupin+Documentation+%28v+2.5.x+and+v+2.6.x%29
Regards,
Silviu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think that it is way easier to use existing plugins instead of rolling your own and reinvent the wheel. Also, you get a lot of flexibility with JJupin, there are a lot of things simplified to meet user/administrator needs.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Instead of currentUser(), is there a variable for adding the component lead? I see that you can set "complead" using admAddProjectComponent - but I don't see it listed on the page here: http://confluence.kepler-rominfo.com/display/SIL/Variable+Resolution
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
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.