-
Notifications
You must be signed in to change notification settings - Fork 20
Dataset Page: Hide deaccession button if dataset is deaccessioned or draft #668
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
Dataset Page: Hide deaccession button if dataset is deaccessioned or draft #668
Conversation
ekraffmiller
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I just have a suggestion for simplifying the logic
src/sections/dataset/dataset-action-buttons/edit-dataset-menu/DeaccessionDatasetButton.tsx
Outdated
Show resolved
Hide resolved
…DeaccessionDatasetButton.tsx Co-authored-by: Ellen Kraffmiller <[email protected]>
|
Hi @ChengShi-1 , I'm sorry, I was testing this against JSF and I realized this issue doesn't describe the logic correctly! But this logic needs to updated with the Deaccession Reason PR is merged (#664), because the deaccession info will be an object. So maybe it's best to keep this waiting until that PR is merged. Sorry for the confusion on this! Let me know if you have questions |
Hi Ellen, Thanks for review! Could you please check #669 ? It solved this issue here I think. I didn't notice this before, it was my bad. |
Ok, great! I will review that, and then we can probably close this. Thanks :) |
|
This issue was resolved in #669 |
What this PR does / why we need it:
Which issue(s) this PR closes:
Special notes for your reviewer:
cy.wrap(repository.deaccession).should('be.calledTwice')tocy.wrap(repository.deaccession).should('have.been.called')because the original test is flaky in git environment. with the error messageTimed out retrying after 4000ms: expected deaccession to have been called exactly twice, but it was called onceversion.length == 0, since the logic seems duplicated withisSomeVersionReleaseSuggestions on how to test this:
if the dataset version is draft or is deaccessioned, should not show Deaccession Dataset Bbutton


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: