[BUGFIX] Fix edit links in Backend Usergroup list 87/38087/2
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Mon, 23 Mar 2015 23:00:13 +0000 (00:00 +0100)
committerWouter Wolters <typo3@wouterwolters.nl>
Mon, 23 Mar 2015 23:29:35 +0000 (00:29 +0100)
Replace T3_THIS_LOCATION with BackendUtility::getModuleUrl() to
fix the broken edit links in "Backend User" > "Backend user groups".

Resolves: #65961
Releases: master
Change-Id: Id5085ad967396e829147325f90d0e4ee037e02f7
Reviewed-on: http://review.typo3.org/38087
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Benjamin Mack <benni@typo3.org>
Tested-by: Benjamin Mack <benni@typo3.org>
typo3/sysext/beuser/Classes/Controller/BackendUserGroupController.php
typo3/sysext/beuser/Resources/Private/Partials/BackendUserGroup/IndexListRow.html

index 9587157..b6024ca 100644 (file)
@@ -53,6 +53,12 @@ class BackendUserGroupController extends \TYPO3\CMS\Extbase\Mvc\Controller\Actio
         * @return void
         */
        public function indexAction() {
+               $this->view->assign('returnUrl', rawurlencode(BackendUtility::getModuleUrl('system_BeuserTxBeuser', array(
+                       'tx_beuser_system_beusertxbeuser' => array(
+                               'action' => 'index',
+                               'controller' => 'BackendUserGroup'
+                       )
+               ))));
                $this->view->assign('backendUserGroups', $this->backendUserGroupRepository->findAll());
        }
 }
index 99a169c..6db26e7 100644 (file)
@@ -8,7 +8,7 @@
                </a>
        </td>
        <td class="col-title">
-               <a href="#" onclick="document.location.href='alt_doc.php?edit[be_groups][{backendUserGroup.uid}]=edit&amp;returnUrl='+T3_THIS_LOCATION">
+               <a href="alt_doc.php?edit[be_groups][{backendUserGroup.uid}]=edit&amp;returnUrl={returnUrl}">
                        <b>{backendUserGroup.title}</b><br />
                        {backendUser.realName}
                </a>
@@ -24,7 +24,7 @@
        <td class="col-control">
                <div class="btn-group" role="group">
                        <a class="btn btn-default" href="#" onclick="top.launchView('be_groups', '{backendUserGroup.uid}'); return false;"><be:spriteManagerIcon iconName="actions-document-info" /></a>
-                       <a class="btn btn-default" href="#" onclick="document.location.href='alt_doc.php?edit[be_groups][{backendUserGroup.uid}]=edit&amp;returnUrl='+T3_THIS_LOCATION"><be:spriteManagerIcon iconName="actions-document-open" /></a>
+                       <a class="btn btn-default" href="alt_doc.php?edit[be_groups][{backendUserGroup.uid}]=edit&amp;returnUrl={returnUrl}"><be:spriteManagerIcon iconName="actions-document-open" /></a>
                        <f:if condition="{backendUserGroup.hidden}">
                                <f:then>
                                        <a class="btn btn-default" href="{bu:issueCommand(parameters: 'data[be_groups][{backendUserGroup.uid}][hidden]=0', redirectUrl: redirectUrl)}"><be:spriteManagerIcon iconName="actions-edit-unhide" options="{title: 'unhide'}" /></a>