Review main Merged

28689[TASK] Return to "Admin Tools > User Admin" when exiting simulated BE User

Pascal Dürsteler CR +2 V +2 Easy +6 −3 updated 04/05/14, 11:59

Commit message

When exiting a simulated BE user, you return to the backend user module
instead of the default startup page.

Review

  • Code review CR +2
    • Stefan Neufeind +2
    • Markus Klein +1
    • Philipp Gampe +1
  • Verified V +2
    • Stefan Neufeind +2
    • Philipp Gampe +1

Issues 1

Files 2

Review log 13

  1. Pascal Dürsteler commented on patch set 1 03/24/14, 08:12

    Although this is reported as "feature" I see this more as a task since it does not bring anything new with it. The only minor thing which disturbs a bit is that the GET param will stay in the browser's address bar after the switchback. Maybe this change needs some JS as well to remove that part?
  2. Mr. Jenkins commented on patch set 1 03/24/14, 08:22

  3. Markus Klein commented on patch set 1 CR -1 03/24/14, 11:09

    SwitchBackUserHook.php:55

    That does not work. We have a new API for retrieving urls to modules.
  4. Helmut Hummel commented on patch set 1 03/24/14, 11:11

    SwitchBackUserHook.php:55

    This will not work in current master! BackendUtility::getModuleUrl must be used.

    SwitchBackUserHook.php:57

    $GLOBALS['BACK_PATH'] is empty in case of the beuser module and thus can be removed completely
  5. Pascal Dürsteler commented on patch set 1 03/24/14, 11:13

    Thanks for the comments, will improve it!
  6. Pascal Dürsteler commented on patch set 1 CR -1 03/24/14, 11:59

    As far as I understood this, BackendUtility::getModuleUrl is designated to create urls from inside the backend, which is why mod.php?M= is used. However, this won't work as the switchback calls index.php/backend.php to load the full TYPO3, not just the main "frame", which requires the "Module" GET parameter instead. A possibility would be to adapt BackendUtility::getModuleUrl to override the main php file and the GET parameter. Or calling the FormProtectionFactory inside the hook and generate a token there. However, one problem still persists: As the switchback calls backend.php?Module=...&moduleToken=..., the address bar is cluttered afterwards. This could be cleaned up with JS after the switchback.
  7. Philipp Gampe commented on patch set 1 03/25/14, 13:03

    You might want to take a look into https://review.typo3.org/#/c/27866/ Maybe you can go a similar way by saving the last module in the UC array and going back to it on switch-back.
  8. Pascal Dürsteler uploaded patch set 2 04/02/14, 12:15

  9. Mr. Jenkins commented on patch set 2 04/02/14, 12:29

  10. Markus Klein voted on patch set 2 CR +1 04/02/14, 12:33

  11. Philipp Gampe voted on patch set 2 V +1 CR +1 04/04/14, 23:09

  12. Stefan Neufeind voted on patch set 2 V +2 CR +2 04/05/14, 11:58

  13. Stefan Neufeind merged patch set 3 04/05/14, 11:59