Review main Merged Breaking

75916[!!!][FEATURE] Introduce TCA type "file"

Oli Bartsch CR +2 V +2 Nightmare +5268 −1208 updated 10/03/22, 13:23

Commit message

In the process of using dedicated TCA types,
the new TCA type "file" is introduced and
replaces TCA type "inline" with "foreign_table"
set to "sys_file_reference".

The new type allows to remove a lot of cross
dependencies and special cases for type "inline",
in case the field is used in FAL context. Also
DataHandler and friends benefit from this change,
since dedicated functionality can be used now.

It therefore effectively allows to improve FAL
independently in the future.

Due to the nature of "inline" a lot of code had
to be copied for the new type, while changing the
internal naming was not always easily possible.
This will be done step by step with further patches.

Besides the new TCA type also three new PSR-14 Events
are introduced:

- CustomFileControlsEvent
- ModifyFileReferenceControlsEvent
- ModifyFileReferenceEnabledControlsEvent

While the ModifyFileReferenceControlsEvent and
ModifyFileReferenceEnabledControlsEvent are equal
to their inline counterparts does the CustomFileControlsEvent
replace the "customControls" hook option, which is
therefore only available for type "inline".

Further notable changed:

- Superfluous field "table_local" is removed from "sys_file_reference"
- ExtensionManagementUtility::getFileFieldTCAConfig() is deprecated
- Placeholders are introduced for common image/media/file types
- File extension filtering is now done automatically in FormEngine
  and DataHandler

Executed commands:

    composer u typo3/cms-styleguide

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Jochen Roth +1
  • Verified V +2 Done
    • Benni Mack +2
    • Jochen Roth +1
    • core-ci +1 CI

Issues 1

Files 188

Show 168 more files

Review log 2743

Show 1018 earlier messages
  1. Oli Bartsch uploaded patch set 1 09/29/22, 22:53

  2. core-ci voted on patch set 1 V -1 09/29/22, 23:04 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31721

  3. Oli Bartsch uploaded patch set 2 09/30/22, 10:33

  4. core-ci voted on patch set 2 V -1 09/30/22, 10:39 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31741

  5. Oli Bartsch uploaded patch set 3 09/30/22, 11:23

  6. core-ci voted on patch set 3 V -1 09/30/22, 11:31 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31743

  7. Oli Bartsch uploaded patch set 4 09/30/22, 12:22

  8. core-ci voted on patch set 4 V -1 09/30/22, 12:30 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31747

  9. Oli Bartsch uploaded patch set 5 09/30/22, 23:40

  10. core-ci voted on patch set 5 V -1 09/30/22, 23:54 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31786

  11. Oli Bartsch uploaded patch set 6 09/30/22, 23:56

  12. core-ci voted on patch set 6 V -1 10/01/22, 00:03 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31789

  13. Oli Bartsch uploaded patch set 7 10/01/22, 13:45

  14. core-ci voted on patch set 7 V -1 10/01/22, 13:56 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31819

  15. Benni Mack commented on patch set 7 10/01/22, 14:08

    Feature-98479-NewTCATypeFile.rst:22

    "typr"

    Feature-98479-NewTCATypeFile.rst:70

    does this need to be a string or an array? ['common-image-types']? I could then go with ['common-image-types', 'mp4']
  16. Oli Bartsch uploaded patch set 8 10/01/22, 15:34

  17. core-ci voted on patch set 8 V -1 10/01/22, 15:49 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31833

  18. Oli Bartsch uploaded patch set 9 10/01/22, 16:20

  1. core-ci voted on patch set 9 V -1 10/01/22, 16:28 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31837

  2. Oli Bartsch uploaded patch set 10 10/01/22, 17:13

  3. core-ci voted on patch set 10 V +1 10/01/22, 17:21 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31839

  4. Oli Bartsch uploaded patch set 11 10/02/22, 08:17

  5. Oli Bartsch uploaded patch set 12 10/02/22, 08:22

  6. Oli Bartsch commented on patch set 12 10/02/22, 08:23

    Feature-98479-NewTCATypeFile.rst:22 Reply

    Done

    Feature-98479-NewTCATypeFile.rst:70 Reply

    Both is possible
  7. core-ci voted on patch set 11 V -1 10/02/22, 08:26 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31860

  8. core-ci voted on patch set 12 V -1 10/02/22, 08:32 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31861

  9. Oli Bartsch uploaded patch set 13 10/02/22, 08:43

  10. core-ci voted on patch set 13 V +1 10/02/22, 08:51 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31862

  11. Oli Bartsch uploaded patch set 14 10/02/22, 09:21

  12. core-ci voted on patch set 14 V +1 10/02/22, 09:29 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31863

  13. Oli Bartsch uploaded patch set 15 10/02/22, 09:48

  14. core-ci voted on patch set 15 V +1 10/02/22, 09:57 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31864

  15. Benni Mack voted on patch set 15 V +1 CR +1 10/02/22, 10:08

  16. Oli Bartsch uploaded patch set 16 10/02/22, 10:21

  17. Benni Mack voted on patch set 16 V +1 CR +1 10/02/22, 10:21

  18. core-ci voted on patch set 16 V +1 10/02/22, 10:30 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31866

  19. Jochen Roth voted on patch set 16 V +1 CR +1 10/02/22, 11:53

  20. Benni Mack voted on patch set 16 V +2 CR +2 10/02/22, 12:03

  21. Benni Mack merged patch set 17 10/02/22, 12:03

  22. Lina Wolf commented on patch set 17 10/03/22, 12:56

    I cannot see how it makes sense to have the behaviour "disableMovingChildrenWithParent" as sys_file_references are always stored on pid 0?
  23. Markus Klein commented on patch set 17 10/03/22, 13:04

    Reply

    sys_file_references are stored on the pid the record is on.
  24. Lina Wolf commented on patch set 17 10/03/22, 13:10

    I also cannot see why the behaviour "enableCascadingDelete" should be available. Keeping sys_file_references when the main record is deleted does not make sense
  25. Lina Wolf commented on patch set 17 10/03/22, 13:23

    Reply

    Ok so does it make sense to store them somewhere else then?