Hello!
I want to have possibility to resolve issue with different options: with linking and without - 1-st button would just resolve issue, 2-nd would resolve and give abbility to link issue (duplicate, for example).
I don't wan't to add workflow transition. Is there some possibility to achieve this?
May be I can add somehow issue operation and link screen with it?
Thanks.
No, you'll need two transitions. No harm in having them end in the same place and using different screens, but your definition of "2 buttons and different screens" are exactly matched by having two transitions.
If you don't want to do it that way, then you'll need to write a new action that breaks the single transition link into two, and then somehow informs the transition screen what to show/hide. Or you'll need to hack all the webwork in Jira to do something similar
Okay, I see, thanks! Sounds, like adding new transition is correct way.
Also I would like to set field values - for example, for "Duplicate" button it will be "duplicates" etc. How can I achieve this? I saw this http://confluence.atlassian.com/display/JIRA/Creating+Issues+via+direct+HTML+links but can't figure out how to use it with CommentAssignIssue action.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There's a post-function that sets core field values, but you'll need to write or find one that can set custom-field values. I use the one in the Jira Suite Utilities most of the time.
The stuff about creating issues with direct html can get quite complex when you're trying to make changes, but basically, you need a scanner (livehttp headers is a plugin for firefox which will tell you most of what you need) to run through the human process of doing something on-screen, and you'll find you can extract the urls from it's log to make the changes you need.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Nice, just now I remembered about post functions - so, I can hide resolution and set it in post function - great!
But I'd also like to restrict selecton of link type - is it possible? I know, that I can write raw javascript in field desription ( http://confluence.atlassian.com/display/JIRA/Fields+Allowing+Custom+HTML+or+JavaScript ) and limit possibilities or lock link selection. But than means, that I will do it for all screens, where this field (link issues) is avaliable.
Do you have an idea, how can I limit link type for particular screen?
Thank you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tryed following: in issue.field.issuelinks field's description I've added following code:
<script type="text/javascript">
AJS.toInit(function() {
if (AJS.$('.aui-popup-heading').text().indexOf('Duplicate') != -1){
console.log('DEBUG MESSAGE'');
AJS.$('#issuelinks-linktype').val('duplicates')
AJS.$('#issuelinks-linktype').attr('disabled','disabled');
}
});
</script>
but it doesn't work - I suppose, it's because link dialog shows after toInit event. How can I make my code work as expected - to run after dialog is shown?
Or is there any other solution to solve my problem: restrict editing of link type for some screens?
Thanks in advance.
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.