[TASK] Offer "exit" button in logout modal 85/44385/2
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Fri, 30 Oct 2015 10:07:09 +0000 (11:07 +0100)
committerAndreas Fernandez <typo3@scripting-base.de>
Fri, 30 Oct 2015 11:09:57 +0000 (12:09 +0100)
Add an "exit" button in the logout modal that appears if a backend session
timed out. That button leads to the backend login form.

Resolves: #70249
Releases: master
Change-Id: If9ec5ed72e12da4a59133e0447319e713c95c91a
Reviewed-on: https://review.typo3.org/44385
Reviewed-by: Thomas Maroschik <tmaroschik@dfau.de>
Reviewed-by: Michael Oehlhof <typo3@oehlhof.de>
Tested-by: Michael Oehlhof <typo3@oehlhof.de>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Thomas Maroschik <tmaroschik@dfau.de>
Reviewed-by: Andreas Fernandez <typo3@scripting-base.de>
Tested-by: Andreas Fernandez <typo3@scripting-base.de>
typo3/sysext/backend/Classes/Controller/BackendController.php
typo3/sysext/backend/Resources/Public/JavaScript/LoginRefresh.js
typo3/sysext/lang/locallang_core.xlf
typo3/sysext/workspaces/Classes/Controller/PreviewController.php

index e98d37c..fd4c1ba 100644 (file)
@@ -488,6 +488,7 @@ class BackendController
             'refresh_login_emptyPassword' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_login_emptyPassword'),
             'refresh_login_button' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_login_button'),
             'refresh_logout_button' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_logout_button'),
+            'refresh_exit_button' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_exit_button'),
             'please_wait' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:mess.please_wait'),
             'loadingIndicator' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:loadingIndicator'),
             'be_locked' => $lang->sL('LLL:EXT:lang/locallang_core.xlf:mess.be_locked'),
index 086470b..1c04cf6 100644 (file)
@@ -216,6 +216,7 @@ define(['jquery', 'bootstrap'], function($) {
                        )
                );
                LoginRefresh.$loginForm.find('.modal-footer').append(
+                       $('<a />', {href: LoginRefresh.logoutUrl, class: 'btn btn-default'}).text(TYPO3.LLL.core.refresh_exit_button),
                        $('<button />', {type: 'submit', form: 'beLoginRefresh', class: 'btn btn-primary', 'data-action': 'refreshSession'}).text(TYPO3.LLL.core.refresh_login_button)
                );
 
index f9707eb..836121a 100644 (file)
@@ -707,6 +707,9 @@ Do you want to refresh it now?</source>
                        <trans-unit id="mess.refresh_login_button">
                                <source>Login</source>
                        </trans-unit>
+                       <trans-unit id="mess.refresh_exit_button">
+                               <source>Exit</source>
+                       </trans-unit>
                        <trans-unit id="mess.refresh_login_emptyPassword">
                                <source>Empty password is not allowed!</source>
                        </trans-unit>
index ea51552..5081485 100644 (file)
@@ -245,6 +245,7 @@ class PreviewController extends AbstractController
             'refresh_login_emptyPassword' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_login_emptyPassword'),
             'refresh_login_button' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_login_button'),
             'refresh_logout_button' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_logout_button'),
+            'refresh_exit_button' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:mess.refresh_exit_button'),
             'please_wait' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:mess.please_wait'),
             'loadingIndicator' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:loadingIndicator'),
             'be_locked' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:mess.be_locked'),