Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Issue Picker is set Required but behaves semi-optional in the edit/view screen

Michael H February 12, 2024

I have a custom field of type Multiple Issue Picker which I had set required in the field configuration which is associated with a field configuration scheme which is associated with the Project itself and the correct issue.

For some reason it functions correctly requiring the user to select an issue during the create screen, but during edit/view screen even though it is required and has the red asterisk next to it people can delete the issue selected.

Interestingly enough when I try editing the issue again, the custom field starts yelling at me about how its required.

I will note I use a behavior such that the Issue picker only appears and becomes required when another custom field of single select list has specific values selected in that list. This shouldn't impact things though as the value chosen is one that makes the multi issue picker required and appear, and it isn't being edited after creating the issue.

During some testing it seems that after deleting the issue picker fields contents and submitting said changes, and editing the issue again, although it says I must enter an issue in as it is required (as mentioned previously above) If I enter an issue in the issue picker and then delete it, the issue picker custom field doesn't care anymore that it is empty and will allow me to update even though it has the red asterisk next to it. 

This is a very long question but if someone could please help It would be greatly appreciated. I can't begin to understand why this single custom field is behaving so weirdly

3 answers

1 vote
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 16, 2024

My first question is what app are you using to provide this multiple issue picker?

The way Jira usually works is that if you flag a multi-select type field as mandatory in the field configuration, Jira will not let you create an issue without at least one option selected, and it would not let people clear the field out completely on edit, it should always have at least one item selected.

You mention a behaviour, but behaviours can't override the basic "must fill it in" requirement, so I don't think it's that.

Jira doesn't have an issue picker built in (Atlassian expect us to use issue links), so there must be an app providing it, and I suspect its something in that which is doing something odd.

Michael H February 20, 2024

Hi Nic,

Thanks for responding to my question. 

The issue picker is provided by the 3rd party app Groovy. I'm actually confused about your statement on behaviours not being able to override the basic "must fil it in" requirement as you can in behaviours for a custom field set a field to hidden, required,  and change its value with setformvalue.

 

For the first paragraph, my issue doesn't let me create with out one option selected but when i delete the issue picker I selected it will let me create even if the issue picker field is empty.

If there is any more contextual info you would like please let me know.

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 20, 2024

If you set a field as mandatory in the field configuration, then Behaviours can not stop the mandatory flag from kicking in and demanding that you fill the field in.  That mandatory check is not done on the screen, it's done after you try to commit the issue.

You don't say what app you are using to provide the issue-picker, could you explain which one it is?

Michael H February 20, 2024

Sorry Nic, the app is Adaptavist Scriptrunner for Jira. 

 

in regards to the Field configuration not being stoppable by behaviours, why can behaviours then set fields as required or not required? I have in multiple instances used behaviours to set a required field to unrequired (and vice versa) dependent on whether or not another custom field has a specific value and it has worked. This is given that the field was set default required in the Field Configurations. Maybe there is some level of understanding I'm lacking here

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 21, 2024

Behaviours works on the front end - the page in your browser.  Field configurations work on the back end, as I said.  

0 votes
Michael H February 16, 2024

@Nic Brough -Adaptavist- @John Funk @Walter Buggenhout @Trudy Claspill 

Sorry if pinging you for this issue is considered rude, its just I think this is such a weird niche case I'm experiencing here and I feel like if anyone was able to help me on this it would be community leaders with experience like you all. I've been stuck on this for the past week. If you need any extra information I'm glad to provide it.

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 16, 2024

Never rude to ask.  I only get annoyed by mentions if it is not an interesting problem that could have been answered with RTFM.

0 votes
GNarsimhagowda - Empyra
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 12, 2024

Hi @Michael H ,

 

The problem that is happening is on the create screen it is marked as mandatory so it will ask us to upadate a value in the field , However this is not required when we edit the issue. I think this is the issue that you are facing.

 

Thanks.

Michael H February 13, 2024

This isn't the issue I'm facing as the field should always be required and all other custom fields that are required function properly in that it won't allow updates if we delete the contents of said required fields.

I don't understand also what you mean when you say this is not required when we edit the issue as that is the whole purpose of making a field required, so any more clarification would be appreciated

 

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 21, 2024

I'm afraid that answer is wrong - if a field is mandatory by the field configuration, you it is mandatory on create and edit.  You can not blank it out.

Suggest an answer

Log in or Sign up to answer