Skip to content

11391 display on create with template #11411

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: develop
Choose a base branch
from

Conversation

sekmiller
Copy link
Contributor

What this PR does / why we need it: Makes fields set "display on Create" at the Dataverse level visible on dataset create in the presence of a default template for that dataset (especially if the template does not have default values for that Metadata block)

Which issue(s) this PR closes:

Special notes for your reviewer: Not sure why the "isDisplayOnCreate" in the Metadata block doesn't work. I added a transient boolean that is updated in the DatasetVersionUI when the metadata blocks are added.

Suggestions on how to test this:
Set dataset field types outside of the citation block to "displayOnCreate" for a given Dataverse -

curl -X PUT -H "X-Dataverse-key:27987dd2-8ae1-4b6d-b3f8-78a2ccfcad4d" -H "Content-Type:application/json" "http://localhost:8080/api/dataverses/temp-doc/inputLevels" -d '[{"datasetFieldTypeName":"geographicCoverage", "required":false, "include":true,  "displayOnCreate":true}, {"datasetFieldTypeName":"country", "required":false, "include":true, "displayOnCreate":true}]'

Add a template to the dataset, but don't set default values in the metadata block where you set "displayOnCreate". Make that template the default.

Add a dataset - the dataset fields set as display on create should be available for edit.

Also, you can try it with no default template but select one after "add dataset" - as above, the dataset fields set as display on create should be available for edit.

Does this PR introduce a user interface change? If mockups are available, please link/include them here:

Is there a release notes update needed for this change?:

Additional documentation:

@github-actions github-actions bot added FY25 Sprint 20 FY25 Sprint 20 (2025-03-26 - 2025-04-09) Size: 20 A percentage of a sprint. 14 hours. Type: Bug a defect labels Apr 8, 2025
@sekmiller sekmiller moved this to Ready for Review ⏩ in IQSS Dataverse Project Apr 8, 2025
@sekmiller sekmiller added this to the 6.7 milestone Apr 8, 2025

This comment has been minimized.

@cmbz cmbz added Size: 10 A percentage of a sprint. 7 hours. FY25 Sprint 21 FY25 Sprint 21 (2025-04-09 - 2025-04-23) and removed Size: 20 A percentage of a sprint. 14 hours. labels Apr 9, 2025
@sekmiller sekmiller moved this from Ready for Review ⏩ to In Progress 💻 in IQSS Dataverse Project Apr 10, 2025
@sekmiller sekmiller self-assigned this Apr 10, 2025
@coveralls
Copy link

coveralls commented Apr 10, 2025

Coverage Status

coverage: 23.112% (+0.001%) from 23.111%
when pulling ce1f019 on 11391-displayOnCreate-with-template
into 8599993 on develop.

This comment has been minimized.

Copy link

📦 Pushed preview images as

ghcr.io/gdcc/dataverse:11391-displayOnCreate-with-template
ghcr.io/gdcc/configbaker:11391-displayOnCreate-with-template

🚢 See on GHCR. Use by referencing with full name as printed above, mind the registry name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FY25 Sprint 20 FY25 Sprint 20 (2025-03-26 - 2025-04-09) FY25 Sprint 21 FY25 Sprint 21 (2025-04-09 - 2025-04-23) Size: 10 A percentage of a sprint. 7 hours. Type: Bug a defect
Projects
Status: In Progress 💻
Development

Successfully merging this pull request may close these issues.

Fields with displayOnCreate setting not visible if collection has a default template
3 participants