Review main Merged

44065[TASK] Add new property displayName to ShortcutButton

Michael Oehlhof CR +2 V +2 Normal +48 −11 updated 10/25/15, 11:53

Commit message

Actually the ShortcutButton shows the module name as label for a shortcut.
For modules with different actions inside the module this results with
the same label for all actions of a module.

This patch add a new property displayName to the ShortcutButton.

With this patch the label in the bookmark list can be set when creating
the ShortcutButton using the new property displayName.
If displayName is set it is used as label for the bookmark,
if displayName is not set (empty) the ShortcutButton works as before.

Review

  • Code review CR +2
    • Stefan Neufeind +2
    • Daniel Goerz +1
  • Verified V +2
    • Stefan Neufeind +2
    • Daniel Goerz +1

Issues 1

Files 4

Review log 31

Show 6 earlier messages
  1. Michael Oehlhof uploaded patch set 1 10/14/15, 19:54

  2. Michael Oehlhof updated the commit message in patch set 2 10/14/15, 20:07

  3. Michael Oehlhof updated the commit message in patch set 3 10/14/15, 20:23

  4. Helmut Hummel commented on patch set 3 CR -1 10/14/15, 20:33

    Ihmo this should be split into several commits (enhance the API, use the API)

    ShortcutButton.php:228

    why using the getter here?

    DocumentTemplate.php:658

    I wouldn't change the old API
  5. Michael Oehlhof commented on patch set 3 10/14/15, 21:27

    I will split it and make a new task for the API enhancement and this bugfix then relates on it.

    ShortcutButton.php:228 Reply

    Don't know. I change it to use the local variable.

    DocumentTemplate.php:658 Reply

    The ShortcutButton uses the old API. ShortcutButton.php 221-222
  6. Michael Oehlhof uploaded patch set 4 10/18/15, 21:52

  1. Michael Oehlhof updated the commit message in patch set 5 10/18/15, 21:53

  2. Stefan Neufeind voted on patch set 5 CR +1 V +1 10/21/15, 21:19

  3. Wouter Wolters commented on patch set 5 CR -1 10/22/15, 08:21

    ShortcutButton.php:221

    We should use the ModuleTemplate here. We want to get rid of DocumentTemplate.

    ShortcutButton.php:228

    use $this->displayName here

    DocumentTemplate.php:658

    do not change this here.
  4. Michael Oehlhof commented on patch set 5 10/22/15, 08:47

    DocumentTemplate.php:658 Reply

    We must change it here because in ShortcutButton.php line 221 the DocumentTemplate is used.
  5. Michael Oehlhof commented on patch set 5 10/22/15, 08:50

    ShortcutButton.php:221 Reply

    That was not in the scope of this patch, but it make sense. Will change it this evening.
  6. Michael Oehlhof uploaded patch set 6 10/22/15, 16:53

  7. Daniel Goerz commented on patch set 6 V -1 10/23/15, 08:08

    The Shortcut-Icons are no buttons anymore.

    ModuleTemplate.php:546

    The @param annotation for $displayName is missing
  8. Daniel Goerz commented on patch set 6 V 0 10/23/15, 08:11

    Actually not the fault of this patch.
  9. Daniel Goerz commented on patch set 6 V -1 10/23/15, 08:16

    Turns out I am not able to properly use git and that this patch indeed removes the button classes from the shortcut icons.
  10. Michael Oehlhof commented on patch set 6 10/23/15, 08:30

    Ah, OK. That is the result of changing from DocumentTemplate to ModuleTeemplate as mentioned by Wouter. I have to investigate later this day.
  11. Daniel Goerz commented on patch set 6 10/23/15, 08:32

    It also moves the shortcut icon to the rightmost position.
  12. Michael Oehlhof commented on patch set 6 10/23/15, 08:46

    I will also change the position, thanks for having a look.
  13. Michael Oehlhof uploaded patch set 7 10/23/15, 10:31

  14. Daniel Goerz commented on patch set 7 CR -1 10/23/15, 10:59

    ShortcutButton.php:227

    $this->displayName

    ModuleTemplate.php:546

    The @param annotation for $displayName and $classes are missing

    PageLayoutView.php:1150

    Is this supposed to be here?
  15. Michael Oehlhof uploaded patch set 8 10/23/15, 11:38

  16. Frank Nägler voted on patch set 8 CR +1 10/23/15, 13:49

  17. Frank Nägler voted on patch set 8 V +1 10/23/15, 13:59

  18. Stefan Neufeind commented on patch set 8 CR +1 10/23/15, 14:07

    I tried it with https://review.typo3.org/44144 but that patch over there doesn't seem to work for me currently. By reading this patch here seems okay though. @Frank: With what module did you test?
  19. Daniel Goerz commented on patch set 8 CR -1 10/23/15, 14:16

    If you go to a bookmarked page again the 2active star is shown, but that markup is broken. Additionally previosly created shortcuts are no longer recognized as "active" and can be created again.
  20. Michael Oehlhof uploaded patch set 9 10/24/15, 02:09

  21. Daniel Goerz commented on patch set 9 CR +1 V +1 10/25/15, 11:27

    Just another thing (but not for this patch as it already does more than it states): The Shortcut-List is not scrollable. So your maximum of usable shprtcuts is determined by your screen resolution.
  22. Stefan Neufeind commented on patch set 9 10/25/15, 11:43

    @Daniel: I've filed a separate issue for that, so we don't forget. https://forge.typo3.org/issues/71004
  23. Daniel Goerz commented on patch set 9 10/25/15, 11:46

    me too :)
  24. Stefan Neufeind commented on patch set 9 CR +2 V +2 10/25/15, 11:53

    Tested with https://review.typo3.org/44144. The new functionality works as advertised. And if not set the title is as before.
  25. Stefan Neufeind merged patch set 9 10/25/15, 11:53