Error "This form contains a hidden field that does not have a valid default value configured" when raising a new request from the customer portal
Platform Notice: Data Center - This article applies to Atlassian products on the Data Center platform.
Note that this knowledge base article was created for the Data Center version of the product. Data Center knowledge base articles for non-Data Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
In Jira Service Management, when raising a new request from the customer portal, the creation fails and the error below is shown in the UI:
This form contains a hidden field that does not have a valid default value configured
Environment
Any Jira Service Management (JSM) Server/Data Center version from 4.0.0
Diagnosis
- Go to the JSM project Request Type configuration page by navigating to Project Settings > Request Types
- Click on the Edit Fields link next to the request type for which the request creation failed
Check the Hidden fields with preset values section. If you see a date field, click on the Edit value link
If you see the error below in the pop-up, then this KB article is relevant:
Invalid date format. Please enter the date in the format "yyyy-MM-dd". Use the yyyy-MM-dd date format
Cause
The request type is configured with a hidden date picker field, which default value has an invalid format. The format does not match the jira.date.picker.java.format setting from the Jira advanced configuration page (which is accessed via ⚙ > System > General Configuration > Advanced Settings).
Taking the example from the diagnosis steps, the default value for the Date field is using the format dd/MM/yyyy, while it should be using "yyyy-MM-dd":
Solution
Change the default value of the Date Picker field in the Request Type configuration to match the jira.date.picker.java.format setting from the Jira advanced configuration page.