Skip to content
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

Remove Bitstreams on edit-item-page doesn't work #3116

Closed
EikLoe opened this issue Jun 14, 2024 · 5 comments · Fixed by #3121 or #3127
Closed

Remove Bitstreams on edit-item-page doesn't work #3116

EikLoe opened this issue Jun 14, 2024 · 5 comments · Fixed by #3121 or #3127
Assignees
Labels
bug component: Item (Archived) Item display or editing high priority
Milestone

Comments

@EikLoe
Copy link
Member

EikLoe commented Jun 14, 2024

Describe the bug
A new issue appeared, where you can't remove the bitstreams of an item using the edit-item-page. After selecting bitstreams for deletion, the Save-button stays deactivated. Only if you select bitstreams of all existing bundles, the button is clickable.

To Reproduce
Steps to reproduce the behavior:

  1. Login as an site-administrator
  2. Open the edit-item-page of an item with attached bitstreams
  3. Navigate to the Bitstreams-tab.
  4. Click on the tiny garbage-can of one bitstream for deleting it.
  5. Try to click Save in order to apply the changes (you can also try to Discard the changes, it won't work either)

Expected behavior

The Save or Discard buttons should be clickable.

@EikLoe EikLoe added bug needs triage New issue needs triage and/or scheduling labels Jun 14, 2024
@github-project-automation github-project-automation bot moved this to 🆕 Triage in DSpace Backlog Jun 14, 2024
@tdonohue tdonohue added high priority component: Item (Archived) Item display or editing and removed needs triage New issue needs triage and/or scheduling labels Jun 14, 2024
@tdonohue
Copy link
Member

This is reproducible on Sandbox and Demo. Not sure why/how this is occurring or when it began.

@artlowel or @atarix83 : Do either of your teams have time to look into this quickly early next week?

@EikLoe
Copy link
Member Author

EikLoe commented Jun 14, 2024

So, I looked a bit into this and it seems to be a problem, that the hasChanges() is not longer called directly in the async pipe, but via the variable hasChanges$ in the item-bitstreams.component.html:

    <button class="btn btn-primary" [disabled]="(hasChanges$ | async) !== true || submitting"
            [attr.aria-label]="'item.edit.bitstreams.save-button' | translate"
            (click)="submit()">

If I change it back in calling hasChanges() directly it works. It has been changed during another bugfix in here: #3060

@alexandrevryghem: Do you remember, why you changed this?

@alexandrevryghem
Copy link
Member

@Leano1998 : It's because it causes performance issues, I can take a look at this

@EikLoe
Copy link
Member Author

EikLoe commented Jun 14, 2024

Ah, I thought so, Thank you @alexandrevryghem

@tdonohue
Copy link
Member

Thanks @alexandrevryghem ! I'll assign this to you then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment