FluidTYPO3 / flux

TYPO3 extension Flux: Dynamic Fluid FlexForms
https://fluidtypo3.org
145 stars 214 forks source link

Images are deleted when publishing workspaces #1171

Closed dr2okevin closed 8 years ago

dr2okevin commented 8 years ago

I have the problem that Images get removed from the Server when i publish a new Content Element. The error occurs under the following conditions

The error occurs not when

CptCompiler commented 8 years ago

Is there any solution for this bug yet?

CptCompiler commented 8 years ago

In typo3/cms/typo3/sysext/core/Classes/DataHandling/DataHandler.php is a function called "deleteRecord_flexFormCallBack" that traverses files of a flex form and deletes them if the field is a regular file field (and not a file_reference field).

In flux/Classes/Form/Field/File.php line 59 the internal_type is set to "file". If I change it to "file_reference" the file will not be deleted when the content element is published.

I don't really know what all that means but thats what I've found out. Perhaps @NamelessCoder could take a look at it ?!

NamelessCoder commented 8 years ago

@CptCompiler A patch to change file to file_reference looks appropriate. Standard file behavior is pretty much deprecated across the board.

dr2okevin commented 8 years ago

Are there any updates? Goes the patch form CptCompiler in the next release?

dr2okevin commented 7 years ago

The Bug still exist in the current master (Commit 374c9ac). Tested with TYPO3 7.6.14