Conversation
ekraffmiller
left a comment
There was a problem hiding this comment.
Hi @ChengShi-1 , great work on a big UI feature! I added some comments below.
| {tDataset('datasetActionButtons.editDataset.terms')} | ||
| </DropdownButtonItem> | ||
| </DropdownButton> | ||
| <Tooltip placement="top" overlay={t('actions.delete')}> |
There was a problem hiding this comment.
There is a problem with deleting Templates that have been used in creating a dataset, so for now, the delete button should be disabled in that case.
There was a problem hiding this comment.
I used template's usage count to determine whether a template is in use, but I just realize it's incorrect.
When a dataset is deleted, the template’s usage count does not decrease accordingly—it reflects total historical usage rather than current usage. I think we may need a new field to check if the template is used.
There was a problem hiding this comment.
Also, I found another issue about create dataset with a template IQSS/dataverse#12132
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 85 out of 86 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
ekraffmiller
left a comment
There was a problem hiding this comment.
Test coverage passed, approved!


What this PR does / why we need it
We have api and use cases for get/create/delete template, we are able to integrate things related to these use cases.
Collection page -> Edit button -> Dataset Templates
Which issue(s) this PR closes:
Special notes for your reviewer:
Suggestions on how to test this:
Does this PR introduce a user interface change? If mockups are available, please link/include them here:
Empty State

Create Dataset Template

After creating it successfully, it's supposed to jump to

Edit Termspage, but because of a lack of API now, we cannot edit terms here, but I have a mock page here.Manage Templates ( you could sort the list by name, date and usage, if you click the table's headers)

PS, make a default, edit templates are not implemented
When you click the "eye"(view) icon, there is a modal of Dataset Template Preview

When you click the Delete icon, there is a modal of Delete Template

When you click copy, it should give you a copy template and refresh the table automatically so you could see it soon.
Create a nested collection inside Root collection, you will have a Edit permission to current collection, and only view permission to root collection's templates.

Is there a release notes or changelog update needed for this change?:
Yes
Additional documentation: