Multiple required fields in state

If there are two or more required enum[1] fields in state in workflow ( enter{something.required(); somethingElse.required();} ), the workflow field change behavior is a bit strange. If both of the required fields are empty and user tries to change the workflow field, first of the missing required fields is reported. If the user fills this field, the second missing required field is not reported and the workflow field shows the new value although the bug isn't saved and moreover it's readonly, so if user wants to save the issue, the page has to be reloaded. Is this a bug or a feature?

3 comments
Comment actions Permalink

Expected behavior is that all required fields are highlighted consequentially and issue won't be saved while all them won't be filled with non-empty values. Just note, "required" means to fill non-empty but not non-defaults values.

Do you see warning messages on the top on screen? Is issue really saved on page reloading while not all requred fields are filled?

Also, please attach workflow code.

0
Comment actions Permalink

Corresponding workflow code is:

state Closed {

  enter {

    Zapracováno v TEST.required("Potvrďte prosím, že bylo zapracováno/revidováno v TEST.");

    Zapracováno v TECH.required("Potvrďte prosím, že bylo zapracováno/revidováno v TECH.");

  }

}

The state variable is called "Stav" and on the pictures attached you can see that after changing Stav to Closed, it is not saved (which is OK), but the Stav field becomes readonly (which is not convenient) and the only missing field is the first one. After I fill it, the other field gets underlined but the big yellow error baner remains unchanged. After I fill the other one too, it's saved and everything is OK.



Attachment(s):
youtrack-bug-2.jpg
youtrack-bug.jpg
0

Please sign in to leave a comment.