Review main Merged

85987[FEATURE] Introduce LatestChangedPages dashboard widget

Ulrich Mathes CR +2 V +2 Hard +401 −0 updated 09/11/24, 20:35

Commit message

This patch adds a new widget for EXT:dashboard, which shows a list of the latest changed pages inside the TYPO3 system.

Review

  • Code review CR +2 Done
    • Georg Ringer +2
    • Frank Nägler +1
  • Verified V +2 Done
    • Georg Ringer +2
    • Frank Nägler +1
    • core-ci +1 CI

Issues 1

Files 6

Review log 2326

Show 1 earlier messages
  1. Ulrich Mathes uploaded patch set 1 09/10/24, 17:04

  1. core-ci voted on patch set 1 V +1 09/10/24, 17:10 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/65293

  2. Chris Müller commented on patch set 1 CR -1 09/10/24, 17:13

  3. Frank Nägler commented on patch set 1 CR -1 09/10/24, 18:13

    on it, will push an update
  4. Frank Nägler uploaded patch set 2 CR -1 V +1 09/10/24, 19:02

  5. Frank Nägler commented on patch set 2 CR +1 V +1 09/10/24, 19:04

    looks good, I added the missing rst file and fixed some minor issues in template and code. Great patch, thank you!
  6. core-ci voted on patch set 2 V +1 09/10/24, 19:07 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/65321

  7. Stefan Bürk commented on patch set 2 CR -1 09/10/24, 19:18

    LatestChangedPagesWidget.php:54

    No QueryBuilder reuse. Don't create it and store it in a property. Create new each time you need to execute something.
  8. Stefan Bürk commented on patch set 2 09/10/24, 19:21

    LatestChangedPagesWidget.php:54 Reply

    https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/Database/QueryBuilder/Index.html#instantiation > Never instantiate and initialize the query builder manually using dependency injection or GeneralUtility::makeInstance(), otherwise you will miss essential dependencies and runtime setup. > The QueryBuilder holds internal state and must not be reused for different queries. In addition, a reuse comes with a significant performance penalty and memory consumption. Use one query builder per query. Get a fresh one by calling $connection->createQueryBuilder() if the same table is involved, or use $connectionPool->getQueryBuilderForTable() for a query to a different table. Do not worry, creating those object instances is quite fast.
  9. Frank Nägler commented on patch set 2 CR -1 09/10/24, 19:41

    LatestChangedPagesWidget.php:54 Reply

    Ack, will take care
  10. Frank Nägler uploaded patch set 3 CR -1 V +1 09/10/24, 19:44

  11. Frank Nägler commented on patch set 2 CR -1 V +1 09/10/24, 19:45

    LatestChangedPagesWidget.php:54 Reply

    Done
  12. Frank Nägler voted on patch set 3 CR +1 V +1 09/10/24, 19:45

  13. core-ci voted on patch set 3 V +1 09/10/24, 19:50 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/65327

  14. Georg Ringer voted on patch set 3 CR +2 V +2 09/10/24, 19:50

  15. Georg Ringer merged patch set 4 09/10/24, 19:50

  16. Oli Bartsch commented on patch set 4 09/10/24, 21:23

    LatestChangedPagesWidget.php:104

    Should be a strict check

    LatestChangedPagesWidget.php:110

    Let's check strict "$pageRecord === false || $pageRecord === []"

    LatestChangedPagesWidget.php:130

    Should be getRootLine

    LatestChangedPagesWidget.php:160

    could be static and even shorthanded

    LatestChangedPagesWidget.html:24

    page.pageRecord.tstamp represents the time the page was edited. in case a content element has been changed, which leads to the widget showing this page, the date is wrong as it shows when the page properties itself were last changed.

    LatestChangedPagesWidget.html:52

    There should be an icon for the pages language
  17. Oli Bartsch commented on patch set 4 09/10/24, 21:25

    Services.yaml:205

    For the default limit of 10 items, this height is not sufficient and cut's off the items. I actually did not get that I can scroll on the first sight.
  18. Oli Bartsch commented on patch set 4 09/10/24, 21:28

    LatestChangedPagesWidget.html:75

    This does not select the page in the page tree. It's furthermore not working for localized pages since they are treated as default => showing translation options etc.
  19. Oli Bartsch commented on patch set 4 09/10/24, 21:28

    Unresolved

    Post -1
  20. Simon Schaufelberger commented on patch set 4 09/10/24, 22:27

    LatestChangedPagesWidget.html:24 Reply

    it should be using the `SYS_LASTCHANGED` column
  21. Oli Bartsch commented on patch set 4 09/11/24, 06:58

    Services.yaml:204

    We might want to add a dedicated icon
  22. Oli Bartsch wrote 09/11/24, 07:07

    Created a revert of this change as I436b630e88920e6d6dbe8061b38d1905d7511229
  23. Frank Nägler commented on patch set 4 09/11/24, 08:34

    Working on a patch to fix your points

    LatestChangedPagesWidget.php:104 Reply

    Acknowledged

    LatestChangedPagesWidget.php:110 Reply

    Acknowledged

    LatestChangedPagesWidget.php:130 Reply

    Acknowledged

    LatestChangedPagesWidget.php:160 Reply

    Acknowledged

    Services.yaml:204 Reply Unresolved

    can be done later if we have an icon

    Services.yaml:205 Reply Unresolved

    the container/table is scrollable

    LatestChangedPagesWidget.html:24 Reply

    Acknowledged

    LatestChangedPagesWidget.html:75 Reply

    How can this be fixed?
  24. Ulrich Mathes commented on patch set 4 09/11/24, 09:05

    LatestChangedPagesWidget.html:75 Reply

    By providing `language: page.pageRecord.sys_language_uid` parameter, the correct translation is shown. If we can't find a way to select the page in page tree, maybe we have to get rid of this link.
  25. Frank Nägler commented on patch set 4 09/11/24, 20:35

    LatestChangedPagesWidget.html:52 Reply

    Acknowledged

    LatestChangedPagesWidget.html:75 Reply

    Acknowledged