Update file usage number when delete node

Created on 17 December 2021, about 3 years ago
Updated 13 March 2024, 10 months ago

Problem/Motivation

When delete node's translation, the 'Status' and 'USED IN' of Files List will be constant.

Steps to reproduce

situation1:
1. Create a node without the file
2. Translate the node, and the file used by the translation (Upload a new image in CK-editor)
3. Save the node
4. Delete the node and translation
5. Access '/admin/content/files', found status of the file is 'Permanent', 'USED IN' of the file is not 0.
Expectation: the image status is 'Temporary', 'USED IN' of the file is 0.

situation2:
1. Create a node and upload the file in the ckeditor of its paragraph
2. Save the node
3. Delete the node
4. Access '/admin/content/files', found status of the file is 'Permanent', 'USED IN' of the file is not 0.
Expectation: the image status is 'Temporary', 'USED IN' of the file is 0.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

🐛 Bug report
Status

Needs work

Version

11.0 🔥

Component
Editor 

Last updated 1 day ago

Created by

🇨🇳China Omega_yang

Live updates comments and jobs are added and updated live.
  • Needs reroll

    The patch will have to be re-rolled with new suggestions/changes described in the comments in the issue.

Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024