Module Description
Core does not support a delete_ui (see #2949017: There is no way to delete file entities of other users)

This module adds the capability to delete files from the file admin view (UI). It assumes that the admin knows what they are doing and trusts that when they want to delete a file (even one with a non zero usage count) that they really want to remove the file. When removing files that are referenced by other entities, core takes care of removing the reference.

This capability was previously provided by file_entity but when media went into core in Drupal 8.4, file_entity was no longer recommended (read the project page). We can delete media entities but we can't actually delete files.

The general philosophy seems to be that files are not first class entities, that they are always attached to something, and that they only get deleted when that something is deleted. However, because of various bugs in core (see #2821423: Dealing with unexpected file deletion due to incorrect file usage, automatic file deletion was removed (see [#2891902]). So we no longer delete files that are in use. But we also have no way for an admin to remove files that they know are not in use.

This modules recreates the minimal parts from file_entity module to provide delete access and an admin UI by doing the following:


* adds an admin permission to 'delete any file'
* ensures that the file entity supports delete by adding the core entity delete template; this allows core to add an entity operations field
* adds the entity operations field to the file admin view; this is done as configuration, so it can easily change it to the 'delete' link if you prefer.

There are several contrib solutions, none do exactly what this module does:


* file_delete
* delete_files
* fancy_file_delete
* force_file_delte

Project Usage
2529
Creation Date
Changed Date
Security Covered
Covered By Security Advisory
Version Available
Production
Module Summary
This module adds the capability to delete files from the file admin view (UI) in Drupal, allowing admins to remove files even with non zero usage count.
Data Name
file_delete_ui

OPENAI CHATBOT

OPENAI CHATBOT

14:25:56
Generic Chatbot
Hi, I'm a Drupal module expert powered by OpenAI, answering your questions about the Drupal module ecosystem. How can I be helpful today? Please note that we will log your question.