We want to set default values with help from behaviours(scriptrunner) for an systemfield.
Here an example Code:
def desc = getFieldById("description")
def defaultValue="*Test*\n"
if(!desc.getValue())
{
desc.setFormValue(defaultValue)
}
That works fine until you get in the following example:
Not a real Workaround:
If i remove the default values after stepp 6 and click outside the form it correctly show the defaults for issuetype2 or if not defined let the field empty as expected.
How can we solve this problem?
The same problem appears when i try to set default values with the field configuration shown here:
Is there any other solution for this problem? Or is this just a bug in scriptrunner?
Pls DONT recommend any other paied plugins, that wont help people.
Thanks a lot!
I don't think it's a bug, but rather Jira expected behavior. Even without a Behaviour, if you change the selected project and/or issue type, the summary, description (and likely any other shared fields) remain populated. I see that as desired behavior, in that if I take the time to type an elaborate description and then realize that I chose the wrong issue type and change it, I'd be bummed to see my description disappear.
If that is an expected behavior then there should be an option for disabling that.
Cant imagine that nobody else run into these trouble.
Any other possible solutions for this case?
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.