I have a ConfiForms Jira form field that is shown on the form when a certain selection is made from another dropdown. Else it is hidden. Hence this field cannot have the 'Required' checkbox selected. There is validation that will show a form error if the field is empty.
To select and submit a Jira issue;
If the user types in the Jira key e.g. ABCD-1234 but does not click to select the issue, then:
How can I do the following?
Hi @Adrian M
Is this a question about the ConfiForms? I believe so, but nothing tells me that for sure (no tags, no mentioning of ConfiForms...)
Alex
Ok, thanks for clarifying
You can add a conditional validation (Validate rule) for the "Jira field" to report when it is empty (not selected from the offered choices)
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am using 'Conditional validation for required field' as follows. getting the same result. If a value is typed in the textbox and not selected then the validation action does not get executed but no value from that field gets saved to Jira.
The user should select a value from the CSPJiraTicket Jira field and that should get saved to the Description field in Jira. Else a form error message is displayed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Alex Medved _ConfiForms_ I'm still trying to resolve this. I created a very simple form with a similar structure of my live form and I'm able to duplicate the issue.
Form has two fields. Summary set as required. And "Jira Issue" field has validation if field is empty.
----------------------------
On clicking the button with no value in the Jira Issue field the validation is triggered
----------------------------
Enter a Jira key in the Jira Issue field. Click to select the Jira Issue from the dropdown. Click the submit (Create Jira Issue) button. Issue is successfully created with "Jira Issue" field value in description field in Jira.
--------------------------------
Enter a Jira key in the Jira Issue field. Do not click to select the Jira Issue from the dropdown. Click outside the box. Click the submit (Create Jira Issue) button. Validation if empty does not get triggered. Issue is successfully created in Jira but "Jira Issue" field value is not in description field in Jira.
----------------------------------
How can I validate that the "Jira Issue" field has a valid Jira Object value?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Adrian M
In ConfiForms version 3.10 we have introduced a property that you can ask from a Jira field to see if that "exists" (links to a valid Jira issue)
That could be then used in the Validation rule, in the condition
JiraIssue.exists:false
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This is my Validation : (JiraTicket:[empty] OR (!JiraTicket:[empty] AND JiraTicket.exists:false))
#1
Input field has no value
Result on Submit - Validation error message is shown
#2
Input field has a Jira Issue selected
Result on Submit - No Error
#3
Input field value is - XXXX
Error message below Jira field - "Request could not be completed: Status: 404 with message: and response: '{"errorMessages":["Issue Does Not Exist"],"errors":{}}'"
Result on Submit - No validation error message is shown and form can be successfully submitted
For scenario #3 how can the form submission be prevented and show the validation error message instead?
Note:
1) This Jira issue form field value is being saved in the description field in Jira and not an issue field in Jira. So Jira wont throw an error if no/invalid value is passed, in this case.
2) The documentation states "myfield.exists - returns true or false to verify if the value stored in this field corresponds to Jira issue". It is not clear what it will return if a String or Null value is passed to JiraTicket.exists
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Checking for JiraTicket.exists:false should be sufficient
No other expressions needed
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Validation - JiraTicket.exists:false
Validation error message is not shown when no value (empty) is passed and form can be successfully submitted.
Validation message is shown when String (e.g. XXXX) is passed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
JiraTicket:[empty] OR JiraTicket.exists:false
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.