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

Adds checkin action on asset delete via View UI #15589

Merged
merged 2 commits into from
Oct 1, 2024

Conversation

snipe
Copy link
Owner

@snipe snipe commented Oct 1, 2024

Previously, we would let you delete an asset that was checked out, and while we correctly logged the deletion, we didn't fire a checkin event.

Screenshot 2024-10-01 at 2 28 02 PM Screenshot 2024-10-01 at 2 28 13 PM Screenshot 2024-10-01 at 2 28 39 PM

@snipe snipe merged commit d274fb6 into develop Oct 1, 2024
8 of 9 checks passed
Copy link

what-the-diff bot commented Oct 1, 2024

PR Summary

  • Improvements to AssetsController.php (in both Api and Assets namespaces)

    • An enhancement has been made that triggers an event when an asset is deleted, but only if it was assigned to someone. Essentially, this event makes a note of who the asset was last with before it is removed from their name. This information could be helpful for record-keeping or auditing purposes.
    • The way the "destroy" function (which is responsible for deleting assets) works has been updated. Now it requires an additional piece of information (a "Request" parameter) to operate.
  • Additions to general.php

    • A new text string 'checkin_and_delete' has been added to the system's language configurations. This new text represents an action where an asset is unassigned from a user before being deleted.
  • Update in view.blade.php

    • The label on the delete button is now smarter. If the asset is assigned to someone, it will now display 'Checkin and Delete,' expressing the additional step needed before deletion. If the asset isn't assigned, it shows the usual 'Delete' label.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant