Synchronized external repositories of version (tag 4.5.0rc1) and workspaces (tag...
authorTolleiv Nietsch <info@tolleiv.de>
Fri, 21 Jan 2011 18:22:24 +0000 (18:22 +0000)
committerTolleiv Nietsch <info@tolleiv.de>
Fri, 21 Jan 2011 18:22:24 +0000 (18:22 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@10222 709f56b5-9817-0410-a4d7-c38de5d9e867

56 files changed:
ChangeLog
typo3/sysext/version/ChangeLog
typo3/sysext/version/class.tx_version_cm1.php
typo3/sysext/version/class.tx_version_gui.php
typo3/sysext/version/class.tx_version_tcemain.php
typo3/sysext/version/class.tx_version_tcemain_commandmap.php
typo3/sysext/version/cm1/index.php
typo3/sysext/version/ext_emconf.php
typo3/sysext/version/tasks/class.tx_version_tasks_autopublish.php
typo3/sysext/version/ws/class.wslib.php
typo3/sysext/version/ws/class.wslib_gui.php
typo3/sysext/version/ws/index.php
typo3/sysext/version/ws/publish.php
typo3/sysext/version/ws/workspaceforms.php
typo3/sysext/version/ws/wsol_preview.php
typo3/sysext/workspaces/ChangeLog
typo3/sysext/workspaces/Classes/BackendUserInterface/WorkspaceSelectorToolbarItem.php
typo3/sysext/workspaces/Classes/Controller/AbstractController.php
typo3/sysext/workspaces/Classes/Controller/PreviewController.php
typo3/sysext/workspaces/Classes/Controller/ReviewController.php
typo3/sysext/workspaces/Classes/ExtDirect/AbstractHandler.php
typo3/sysext/workspaces/Classes/ExtDirect/ActionHandler.php
typo3/sysext/workspaces/Classes/ExtDirect/MassActionHandler.php
typo3/sysext/workspaces/Classes/ExtDirect/Server.php
typo3/sysext/workspaces/Classes/ExtDirect/ToolbarMenu.php
typo3/sysext/workspaces/Classes/Reports/StatusProvider.php
typo3/sysext/workspaces/Classes/Service/AutoPublish.php
typo3/sysext/workspaces/Classes/Service/AutoPublishTask.php
typo3/sysext/workspaces/Classes/Service/Befunc.php
typo3/sysext/workspaces/Classes/Service/Fehooks.php
typo3/sysext/workspaces/Classes/Service/GridData.php
typo3/sysext/workspaces/Classes/Service/Stages.php
typo3/sysext/workspaces/Classes/Service/Tcemain.php
typo3/sysext/workspaces/Classes/Service/Workspaces.php
typo3/sysext/workspaces/Resources/Private/Language/locallang.xml
typo3/sysext/workspaces/Resources/Private/Language/locallang_mod.xml
typo3/sysext/workspaces/Resources/Private/Layouts/module.html
typo3/sysext/workspaces/Resources/Private/Layouts/popup.html
typo3/sysext/workspaces/Resources/Private/Templates/Preview/Preview.html
typo3/sysext/workspaces/Resources/Private/Templates/Review/Index.html
typo3/sysext/workspaces/Resources/Public/Images/generate-ws-preview-link.png [new file with mode: 0644]
typo3/sysext/workspaces/Resources/Public/JavaScript/actions.js
typo3/sysext/workspaces/Resources/Public/JavaScript/component.js
typo3/sysext/workspaces/Resources/Public/JavaScript/configuration.js
typo3/sysext/workspaces/Resources/Public/JavaScript/grid.js
typo3/sysext/workspaces/Resources/Public/JavaScript/preview.js
typo3/sysext/workspaces/Resources/Public/JavaScript/toolbar.js
typo3/sysext/workspaces/Resources/Public/JavaScript/workspacemenu.js
typo3/sysext/workspaces/Resources/Public/StyleSheet/module.css
typo3/sysext/workspaces/Resources/Public/StyleSheet/preview.css
typo3/sysext/workspaces/Tests/Service/WorkspaceTest.php
typo3/sysext/workspaces/ext_emconf.php
typo3/sysext/workspaces/ext_localconf.php
typo3/sysext/workspaces/ext_tables.php
typo3/sysext/workspaces/ext_tables.sql
typo3/sysext/workspaces/tca.php

index 6f8d0f6..adb9b28 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -9,6 +9,7 @@
 
 2011-01-21  Tolleiv Nietsch  <typo3@tolleiv.de>
 
+       * Synchronized external repositories of version (tag 4.5.0rc1) and workspaces (tag 4.5.0rc1)
        * Fixed bug #16935: tx_coreupdates_installversioning is obsolete
 
 2011-01-21  Ernesto Baschny  <ernst@cron-it.de>
index 87d68df..eb58805 100644 (file)
@@ -1,3 +1,15 @@
+2011-01-21  Tolleiv Nietsch <typo3@tolleiv.de>
+
+       * Raised version to 4.5.0rc1
+
+2011-01-20  Tolleiv Nietsch <typo3@tolleiv.de>
+
+       * Fixed bug #12386: "Publish only content in publish stage" doesn't work anymore
+
+2011-01-20  Susanne Moog <typo3@susanne-moog.de>
+
+       * Fixed bug #12397: CSRF protection for clickmenu and old workspace module (Thanks to Helmut Hummel)
+
 2011-01-12  Oliver Hader  <oliver.hader@typo3.org>
 
        * Follow-up to bug #11832: Label of the anchor is empty
index 42199cc..881b570 100755 (executable)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2004-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 2004-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 6043658..c59737f 100644 (file)
@@ -2,8 +2,8 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
-*  (c) 2010 Benjamin Mack (benni@typo3.org)
+*  (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 2010-2011 Benjamin Mack (benni@typo3.org)
 *
 *  All rights reserved
 *
index 83c04c3..7493492 100644 (file)
@@ -2,9 +2,9 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
-*  (c) 2010 Benjamin Mack (benni@typo3.org)
-* 
+*  (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 2010-2011 Benjamin Mack (benni@typo3.org)
+*
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -77,7 +77,7 @@ class tx_version_tcemain {
 
        /**
         * hook that is called when no prepared command was found
-        * 
+        *
         * @param string $command the command to be executed
         * @param string $table the table of the record
         * @param integer $id the ID of the record
@@ -96,7 +96,7 @@ class tx_version_tcemain {
                        switch ($action) {
 
                                case 'new':
-                                               // check if page / branch versioning is needed, 
+                                               // check if page / branch versioning is needed,
                                                // or if "element" version can be used
                                        $versionizeTree = -1;
                                        if (isset($value['treeLevels'])) {
@@ -137,7 +137,7 @@ class tx_version_tcemain {
        }
 
        /**
-        * hook that is called AFTER all commands of the commandmap was 
+        * hook that is called AFTER all commands of the commandmap was
         * executed
         *
         * @param t3lib_TCEmain $tcemainObj reference to the main tcemain object
@@ -157,7 +157,7 @@ class tx_version_tcemain {
 
 
        /**
-        * hook that is called AFTER all commands of the commandmap was 
+        * hook that is called AFTER all commands of the commandmap was
         * executed
         *
         * @param string $table the table of the record
@@ -169,12 +169,12 @@ class tx_version_tcemain {
         * @return      void
         */
        public function processCmdmap_deleteAction($table, $id, array $record, &$recordWasDeleted, t3lib_TCEmain $tcemainObj) {
-                       // only process the hook if it wasn't processed 
+                       // only process the hook if it wasn't processed
                        // by someone else before
                if (!$recordWasDeleted) {
                        $recordWasDeleted = TRUE;
                        $id = $record['uid'];
-       
+
                                // For Live version, try if there is a workspace version because if so, rather "delete" that instead
                                // Look, if record is an offline version, then delete directly:
                        if ($record['pid'] != -1) {
@@ -283,8 +283,8 @@ class tx_version_tcemain {
 
                                // Workspace destination check:
 
-                               // All records can be inserted if $destRes is greater than zero. 
-                               // Only new versions can be inserted if $destRes is false. 
+                               // All records can be inserted if $destRes is greater than zero.
+                               // Only new versions can be inserted if $destRes is false.
                                // NO RECORDS can be inserted if $destRes is negative which indicates a stage
                                //  not allowed for use. If "versioningWS" is version 2, moving can take place of versions.
                        if (!($destRes > 0 || ($canMoveRecord && !$destRes))) {
@@ -294,7 +294,7 @@ class tx_version_tcemain {
                        }
 
                        if (!count($workspaceAccessBlocked)) {
-                                       // If the move operation is done on a versioned record, which is 
+                                       // If the move operation is done on a versioned record, which is
                                        // NOT new/deleted placeholder and versioningWS is in version 2, then...
                                if ($WSversion['uid'] && !$recIsNewVersion && (int)$TCA[$table]['ctrl']['versioningWS'] >= 2) {
                                        $this->moveRecord_wsPlaceholders($table, $uid, $destPid, $WSversion['uid'], $tcemainObj);
@@ -428,7 +428,7 @@ class tx_version_tcemain {
 
                                // prepare and then send the emails
                        if (count($emails)) {
-                               
+
                                        // Path to record is found:
                                list($elementTable, $elementUid) = explode(':', $elementName);
                                $elementUid = intval($elementUid);
@@ -472,8 +472,8 @@ class tx_version_tcemain {
                                        '###USER_USERNAME###' => $tcemainObj->BE_USER->user['username']
                                );
 
-                                       
-                                       // sending the emails the old way with sprintf(), 
+
+                                       // sending the emails the old way with sprintf(),
                                        // because it was set explicitly in TSconfig
                                if ($emailMessage && $emailSubject) {
                                        t3lib_div::deprecationLog('This TYPO3 installation uses Workspaces staging notification by setting the TSconfig options "TCEMAIN.notificationEmail_subject" / "TCEMAIN.notificationEmail_body". Please use the more flexible marker-based options tx_version.workspaces.stageNotificationEmail.message / tx_version.workspaces.stageNotificationEmail.subject');
@@ -507,7 +507,7 @@ class tx_version_tcemain {
                                                $emailMessage
                                        );
                                } else {
-                                               // send an email to each individual user, to ensure the 
+                                               // send an email to each individual user, to ensure the
                                                // multilanguage version of the email
 
                                        $emailHeaders = $emailConfig['additionalHeaders'];
@@ -529,12 +529,12 @@ class tx_version_tcemain {
                                                $emailMessage = $emailConfig['message'];
                                                $emailRecipients[$recipientData['email']] = $recipientData['email'];
 
-                                                       // check if the email needs to be localized 
+                                                       // check if the email needs to be localized
                                                        // in the users' language
                                                if (t3lib_div::isFirstPartOfStr($emailSubject, 'LLL:') || t3lib_div::isFirstPartOfStr($emailMessage, 'LLL:')) {
                                                        $recipientLanguage = ($recipientData['lang'] ? $recipientData['lang'] : 'default');
                                                        if (!isset($languageObjects[$recipientLanguage])) {
-                                                                       // a LANG object in this language hasn't been 
+                                                                       // a LANG object in this language hasn't been
                                                                        // instantiated yet, so this is done here
                                                                /** @var $languageObject language */
                                                                $languageObject = t3lib_div::makeInstance('language');
@@ -621,8 +621,8 @@ class tx_version_tcemain {
                } elseif ($tcemainObj->checkRecordUpdateAccess($table, $id)) {
                        $record = t3lib_BEfunc::getRecord($table, $id);
                        $stat = $tcemainObj->BE_USER->checkWorkspace($record['t3ver_wsid']);
-
-                       if (t3lib_div::inList('admin,online,offline,reviewer,owner', $stat['_ACCESS']) || ($stageId <= 1 && $stat['_ACCESS'] === 'member')) {
+                               // check if the usere is allowed to the current stage, so it's also allowed to send to next stage
+                       if ($GLOBALS['BE_USER']->workspaceCheckStageForCurrent($record['t3ver_stage'])) {
 
                                        // Set stage of record:
                                $updateData = array(
@@ -646,7 +646,7 @@ class tx_version_tcemain {
                        } else $tcemainObj->newlog('The member user tried to set a stage value "' . $stageId . '" that was not allowed', 1);
                } else $tcemainObj->newlog('Attempt to set stage for record failed because you do not have edit access', 1);
        }
-       
+
 
 
        /*****************************
@@ -743,7 +743,7 @@ class tx_version_tcemain {
                        if (is_array($curVersion) && is_array($swapVersion)) {
                                if ($tcemainObj->BE_USER->workspacePublishAccess($swapVersion['t3ver_wsid'])) {
                                        $wsAccess = $tcemainObj->BE_USER->checkWorkspace($swapVersion['t3ver_wsid']);
-                                       if ($swapVersion['t3ver_wsid'] <= 0 || !($wsAccess['publish_access'] & 1) || (int)$swapVersion['t3ver_stage'] === 10) {
+                                       if ($swapVersion['t3ver_wsid'] <= 0 || !($wsAccess['publish_access'] & 1) || (int)$swapVersion['t3ver_stage'] === -10) {
                                                if ($tcemainObj->doesRecordExist($table,$swapWith,'show') && $tcemainObj->checkRecordUpdateAccess($table,$swapWith)) {
                                                        if (!$swapIntoWS || $tcemainObj->BE_USER->workspaceSwapAccess()) {
 
@@ -768,7 +768,7 @@ class tx_version_tcemain {
                                                                                if ($TCA[$table]['ctrl']['sortby']) {
                                                                                        $keepFields[] = $TCA[$table]['ctrl']['sortby'];
                                                                                }
-                                                                                       // l10n-fields must be kept otherwise the localization 
+                                                                                       // l10n-fields must be kept otherwise the localization
                                                                                        // will be lost during the publishing
                                                                                if (!isset($TCA[$table]['ctrl']['transOrigPointerTable']) && $TCA[$table]['ctrl']['transOrigPointerField']) {
                                                                                        $keepFields[] = $TCA[$table]['ctrl']['transOrigPointerField'];
@@ -936,7 +936,7 @@ class tx_version_tcemain {
 
                                                                                                        // Collect table names that should be copied along with the tables:
                                                                                                foreach ($TCA as $tN => $tCfg)  {
-                                                                                                               // For "Branch" publishing swap ALL, 
+                                                                                                               // For "Branch" publishing swap ALL,
                                                                                                                // otherwise for "page" publishing, swap only "versioning_followPages" tables
                                                                                                        if ($swapVersion['t3ver_swapmode'] > 0 || $TCA[$tN]['ctrl']['versioning_followPages']) {
                                                                                                                $temporaryPid = -($id+1000000);
@@ -1228,7 +1228,7 @@ class tx_version_tcemain {
                                        }
                                        $GLOBALS['TYPO3_DB']->sql_free_result($res);
                                        if (is_array($elementList[$table])) {
-                                               // Yes, it is possible to get non-unique array even with DISTINCT above! 
+                                               // Yes, it is possible to get non-unique array even with DISTINCT above!
                                                // It happens because several UIDs are passed in the array already.
                                                $elementList[$table] = array_unique($elementList[$table]);
                                        }
@@ -1261,7 +1261,7 @@ class tx_version_tcemain {
                        while (FALSE !== ($row = $GLOBALS['TYPO3_DB']->sql_fetch_row($res))) {
                                $pageIdList[] = $row[0];
                                        // Find ws version
-                                       // Note: cannot use t3lib_BEfunc::getRecordWSOL() 
+                                       // Note: cannot use t3lib_BEfunc::getRecordWSOL()
                                        // here because it does not accept workspace id!
                                $rec = t3lib_BEfunc::getRecord('pages', $row[0]);
                                t3lib_BEfunc::workspaceOL('pages', $rec, $workspaceId);
index f485142..8ca1345 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  * Copyright notice
  *
- * (c) 2010 Oliver Hader <oliver@typo3.org>
+ * (c) 2010-2011 Oliver Hader <oliver@typo3.org>
  * All rights reserved
  *
  * This script is part of the TYPO3 project. The TYPO3 project is
index 1cb91cc..3a1a2e7 100755 (executable)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2004-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 2004-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -534,7 +534,7 @@ class tx_version_cm1 extends t3lib_SCbase {
                        <input type="hidden" name="prErr" value="1" />
                        <input type="hidden" name="redirect" value="'.htmlspecialchars($this->REQUEST_URI).'" />
                        <input type="submit" name="_" value="' . $GLOBALS['LANG']->getLL('createNewVersion') . '" />
-
+                       ' . t3lib_TCEforms::getHiddenTokenField('tceAction') . '
                        </form>
 
                ';
@@ -1688,7 +1688,7 @@ class tx_version_cm1 extends t3lib_SCbase {
         * @return      string          HTML content, mainly link tags and images.
         */
        function displayWorkspaceOverview_commandLinks($table,&$rec_on,&$rec_off,$vType)        {
-               if ($this->publishAccess && (!($GLOBALS['BE_USER']->workspaceRec['publish_access']&1) || (int)$rec_off['t3ver_stage']===10))    {
+               if ($this->publishAccess && (!($GLOBALS['BE_USER']->workspaceRec['publish_access']&1) || (int)$rec_off['t3ver_stage']===-10))   {
                        $actionLinks =
                                '<a href="'.htmlspecialchars($this->doc->issueCommand(
                                                '&cmd['.$table.']['.$rec_on['uid'].'][version][action]=swap'.
@@ -1854,4 +1854,6 @@ $SOBE->init();
 $SOBE->main();
 $SOBE->printContent();
 
+t3lib_formprotection_Factory::get('t3lib_formprotection_BackendFormProtection')->persistTokens();
+
 ?>
\ No newline at end of file
index 57bc0c1..5864fb9 100755 (executable)
@@ -3,7 +3,7 @@
 ########################################################################
 # Extension Manager/Repository config file for ext "version".
 #
-# Auto generated 12-01-2011 11:33
+# Auto generated 21-01-2011 19:08
 #
 # Manual updates:
 # Only the data in the array - everything else is removed by next
@@ -30,8 +30,8 @@ $EM_CONF[$_EXTKEY] = array(
        'clearCacheOnLoad' => 0,
        'lockType' => '',
        'author_company' => '',
-       'version' => '4.5.0beta4',
-       '_md5_values_when_last_written' => 'a:31:{s:9:"ChangeLog";s:4:"d57e";s:24:"class.tx_version_cm1.php";s:4:"b4cd";s:24:"class.tx_version_gui.php";s:4:"86d9";s:28:"class.tx_version_tcemain.php";s:4:"27f0";s:39:"class.tx_version_tcemain_commandmap.php";s:4:"3fc3";s:16:"ext_autoload.php";s:4:"3497";s:21:"ext_conf_template.txt";s:4:"84d4";s:12:"ext_icon.gif";s:4:"3ca2";s:17:"ext_localconf.php";s:4:"9812";s:14:"ext_tables.php";s:4:"1196";s:13:"locallang.xml";s:4:"5ec0";s:7:"tca.php";s:4:"15fa";s:47:"Resources/Private/Language/locallang_emails.xml";s:4:"efd1";s:12:"cli/conf.php";s:4:"f8ec";s:13:"cm1/clear.gif";s:4:"cc11";s:15:"cm1/cm_icon.gif";s:4:"3ca2";s:12:"cm1/conf.php";s:4:"6ed8";s:13:"cm1/index.php";s:4:"d53f";s:44:"tasks/class.tx_version_tasks_autopublish.php";s:4:"ace9";s:18:"ws/class.wslib.php";s:4:"549f";s:22:"ws/class.wslib_gui.php";s:4:"e367";s:12:"ws/clear.gif";s:4:"cc11";s:11:"ws/conf.php";s:4:"b2a8";s:12:"ws/index.php";s:4:"e9df";s:15:"ws/progress.gif";s:4:"35af";s:14:"ws/publish.php";s:4:"5761";s:20:"ws/sys_workspace.gif";s:4:"55bc";s:20:"ws/sys_workspace.png";s:4:"db4b";s:21:"ws/workspaceforms.php";s:4:"46bd";s:19:"ws/wsol_preview.php";s:4:"fbab";s:15:"ws/cli/conf.php";s:4:"328d";}',
+       'version' => '4.5.0rc1',
+       '_md5_values_when_last_written' => 'a:31:{s:9:"ChangeLog";s:4:"f4a8";s:24:"class.tx_version_cm1.php";s:4:"d808";s:24:"class.tx_version_gui.php";s:4:"deea";s:28:"class.tx_version_tcemain.php";s:4:"113b";s:39:"class.tx_version_tcemain_commandmap.php";s:4:"2246";s:16:"ext_autoload.php";s:4:"3497";s:21:"ext_conf_template.txt";s:4:"84d4";s:12:"ext_icon.gif";s:4:"3ca2";s:17:"ext_localconf.php";s:4:"9812";s:14:"ext_tables.php";s:4:"1196";s:13:"locallang.xml";s:4:"5ec0";s:7:"tca.php";s:4:"15fa";s:47:"Resources/Private/Language/locallang_emails.xml";s:4:"efd1";s:12:"cli/conf.php";s:4:"f8ec";s:13:"cm1/clear.gif";s:4:"cc11";s:15:"cm1/cm_icon.gif";s:4:"3ca2";s:12:"cm1/conf.php";s:4:"6ed8";s:13:"cm1/index.php";s:4:"5fa3";s:44:"tasks/class.tx_version_tasks_autopublish.php";s:4:"5b4c";s:18:"ws/class.wslib.php";s:4:"2700";s:22:"ws/class.wslib_gui.php";s:4:"34f3";s:12:"ws/clear.gif";s:4:"cc11";s:11:"ws/conf.php";s:4:"b2a8";s:12:"ws/index.php";s:4:"5f7e";s:15:"ws/progress.gif";s:4:"35af";s:14:"ws/publish.php";s:4:"e20c";s:20:"ws/sys_workspace.gif";s:4:"55bc";s:20:"ws/sys_workspace.png";s:4:"db4b";s:21:"ws/workspaceforms.php";s:4:"154c";s:19:"ws/wsol_preview.php";s:4:"2050";s:15:"ws/cli/conf.php";s:4:"328d";}',
        'constraints' => array(
                'depends' => array(
                        'typo3' => '4.5.0-0.0.0',
index da3f1e3..f05c929 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2010 François Suter <francois@typo3.org>
+*  (c) 2010-2011 François Suter <francois@typo3.org>
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index cedd548..bc31b6f 100755 (executable)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2005-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 2005-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 77a5a43..eed58b3 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2005-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+ *  (c) 2005-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -866,7 +866,7 @@ class wslib_gui {
        function displayWorkspaceOverview_commandLinks($table,&$rec_on,&$rec_off,$vType)        {
                global  $LANG;
 
-               if ($this->publishAccess && (!($GLOBALS['BE_USER']->workspaceRec['publish_access']&1) || (int)$rec_off['t3ver_stage']===10))    {
+               if ($this->publishAccess && (!($GLOBALS['BE_USER']->workspaceRec['publish_access']&1) || (int)$rec_off['t3ver_stage']===-10))   {
                        $actionLinks =
                                '<a href="'.htmlspecialchars($this->doc->issueCommand(
                                '&cmd['.$table.']['.$rec_on['uid'].'][version][action]=swap'.
index 3adc0d4..6b87fb1 100755 (executable)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -1091,4 +1091,6 @@ $SOBE->init();
 $SOBE->main();
 $SOBE->printContent();
 
+t3lib_formprotection_Factory::get('t3lib_formprotection_BackendFormProtection')->persistTokens();
+
 ?>
\ No newline at end of file
index 111abbe..6547401 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 23ede5b..51f225a 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 32c6ba4..4d540cf 100755 (executable)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2004-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
+*  (c) 2004-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 0210713..6158d31 100644 (file)
@@ -1,3 +1,70 @@
+2011-01-21  Tolleiv Nietsch <typo3@tolleiv.de>
+       
+       * Raised version to 4.5.0rc1
+       * Fixed bug #12415: Respect change #17167: Cache ExtDirect::getAPI calls
+       * Fixed bug #12308: Workspace non-admin not workspace owner sees icon to swap updated version with Live site
+       * Fixed bug #12384: Mount points are not taken into account in element-list
+       * Fixed bug #12325: Hide icons that don't work in the current context
+       * Fixed bug #11539: Split view
+
+2011-01-20  Susanne Moog <typo3@susanne-moog.de>
+
+       * Fixed bug #12055: Publishing a page does not update the new page tree
+       * Fixed bug #12413: Rename extension "list" to "recordlist"
+       * Fixed bug #12000: Cache and Favorites submenus shifts when in Workspaces
+       * Fixed bug #11574: Workspaces grid: stages should "sit" on one line
+       * Fixed bug #12446: Fixed instantiation of UriBuilder (broken since extbase merge)
+
+2011-01-20  Tolleiv Nietsch <typo3@tolleiv.de>
+
+       * Fixed bug #12077: Tooltips for slider
+       * Fxied bug #12334:"Allow members to edit records in "Review" stage" should be removed
+       * Fixed bug #12286: Wrong icon for "Generate workspace preview link" - use eye icon instead
+
+2011-01-18  Susanne Moog <typo3@susanne-moog.de>
+
+       * Fixed bug #11972: Switching workspaces with tabs causes module menu to loose its selection
+       * Fixed bug #12405: The workspaces module does not work in Internet Explorer
+
+2011-01-18  Sonja Scholz <ss@cabag.ch>
+
+       * Fixed bug #11481: Naming of "Release" mass action is unclear
+       * Fixed bug #12350: Wrong backpath for thumbnail generation in diff view
+
+2011-01-18  Marco Bresch <typo3@starfinanz.de>
+
+       * Fixed bug #10439: Data array used in ws-grid should be cached
+
+2011-01-18  Tolleiv Nietsch <typo3@tolleiv.de>
+
+       * Fixed bug #12347: Incorrect registration of status report
+       * Fixed bug #12333: "Un-Publish:" should be hidden
+       * Fixed bug #12322: "null" is shown in diff view if original fields are empty in Firefox
+       * Fixed bug #11587: Trash icon should "discard" too
+       * Fixed bug #11529: Infinite not infinite / moved pages not always visible in element list
+
+2011-01-16  Sonja Scholz <ss@cabag.ch>
+
+       * Fixed bug #11825: non-admin editors can't see non-page records within the review module
+       * Fixed bug #12272: Topbar isn't highlighted if there's only on workspace
+       * Fixed bug #12273: "Go to workspace module" link appears even if user has no access to it
+
+2011-01-16  Tolleiv Nietsch <typo3@tolleiv.de>
+
+       * Followup to #16630: migrateWorkspaces in Install-Tool does not work, if extbase is not intalled
+       * Fixed bug #12076: Remove "help" tab
+       * Fixed bug #12192: Description of workspace module for "about modules" missing
+       * Fixed bug #12194: Legend too wide
+
+2011-01-16  Sonja Scholz <ss@cabag.ch>
+
+       * Fixed bug #12291: Icon "Open version of page" does not go the the page of the clicked element
+
+2011-01-15  Marco Bresch  <typo3@starfinanz.de>
+
+       * Fixed bug: include htmlspecialchars for labels to display html-tags
+       * Bug #11585: Hide difference column for default
+
 2011-01-12  Oliver Hader  <oliver.hader@typo3.org>
 
        * Fixed bug: migrateWorkspaces in Install-Tool does not work, if extbase is not intalled
index d1cc06b..e4b1a15 100644 (file)
@@ -2,8 +2,8 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2007-2010 Ingo Renner <ingo@typo3.org>
-*  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+*  (c) 2007-2011 Ingo Renner <ingo@typo3.org>
+*  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -75,7 +75,7 @@ class WorkspaceSelectorToolbarItem implements backend_toolbarItem {
                if (t3lib_extMgm::isLoaded('workspaces')) {
                        if ($this->checkAccess == NULL) {
                                        $availableWorkspaces = tx_Workspaces_Service_Workspaces::getAvailableWorkspaces();
-                                       if (count($availableWorkspaces) > 1) {
+                                       if (count($availableWorkspaces) > 0) {
                                                $this->checkAccess = TRUE;
                                        } else {
                                                $this->checkAccess = FALSE;
@@ -128,10 +128,12 @@ class WorkspaceSelectorToolbarItem implements backend_toolbarItem {
                                '</li>';
                }
 
-                       // go to workspace module link
-               $workspaceMenu[] = '<li class="divider">' . $stateUncheckedIcon . ' ' .
-                       '<a href="javascript:top.goToModule(\'web_WorkspacesWorkspaces\');" target="content" id="goToWsModule">' .
-                       ' '. $GLOBALS['LANG']->getLL('bookmark_workspace', true) . '</a></li>';
+               if ($GLOBALS['BE_USER']->check('modules', 'web_WorkspacesWorkspaces')) {
+                               // go to workspace module link
+                       $workspaceMenu[] = '<li class="divider">' . $stateUncheckedIcon . ' ' .
+                               '<a href="javascript:top.goToModule(\'web_WorkspacesWorkspaces\');" target="content" id="goToWsModule">' .
+                               ' '. $GLOBALS['LANG']->getLL('bookmark_workspace', true) . '</a></li>';
+               }
 
                $workspaceMenu[] = '</ul>';
 
@@ -166,4 +168,4 @@ if(!(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_AJAX)) {
 if (defined('TYPO3_MODE') && isset($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/BackendUserInterface/WorkspaceSelectorToolbarItem.php'])) {
        include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/BackendUserInterface/WorkspaceSelectorToolbarItem.php']);
 }
-?>
\ No newline at end of file
+?>
index 874d535..feeccf2 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
index a773a8f..12cb3db 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -51,7 +51,7 @@ class Tx_Workspaces_Controller_PreviewController extends Tx_Workspaces_Controlle
                        // Load  JavaScript:
                $this->pageRenderer->addExtDirectCode();
                $this->pageRenderer->addJsFile(
-                       $this->backPath . 'ajax.php?ajaxID=ExtDirect::getAPI&namespace=TYPO3.Workspaces',
+                       $this->backPath . 'ajax.php?ajaxID=ExtDirect::getAPI&namespace=TYPO3.Workspaces&' . TYPO3_version,
                        NULL,
                        FALSE
                );
@@ -79,24 +79,21 @@ class Tx_Workspaces_Controller_PreviewController extends Tx_Workspaces_Controlle
                $language = intval(t3lib_div::_GP('L'));
 
                $controller = t3lib_div::makeInstance('Tx_Workspaces_Controller_ReviewController', TRUE);
-               $uriBuilder = t3lib_div::makeInstance('Tx_Extbase_MVC_Web_Routing_UriBuilder');
+               /** @var $uriBuilder Tx_Extbase_MVC_Web_Routing_UriBuilder */
+               $uriBuilder = $this->objectManager->create('Tx_Extbase_MVC_Web_Routing_UriBuilder');
 
                $wsSettingsPath = t3lib_div::getIndpEnv('TYPO3_SITE_URL') . 'typo3/';
-               $wsSettingsUri = $uriBuilder->uriFor('singleIndex', array(), $controller, 'workspaces', 'web_workspacesworkspaces');
+               $wsSettingsUri = $uriBuilder->uriFor('singleIndex', array(), 'Tx_Workspaces_Controller_ReviewController', 'workspaces', 'web_workspacesworkspaces');
                $wsSettingsParams = '&tx_workspaces_web_workspacesworkspaces[controller]=Review';
                $wsSettingsUrl = $wsSettingsPath . $wsSettingsUri . $wsSettingsParams;
 
-               $wsHelpUri = $uriBuilder->uriFor('help', array(), $this, 'workspaces', 'web_workspacesworkspaces');
-               $wsHelpParams = '&tx_workspaces_web_workspacesworkspaces[controller]=Preview';
-               $wsHelpUrl = $wsSettingsPath . $wsHelpUri . $wsHelpParams;
-
                $viewDomain = t3lib_BEfunc::getViewDomain($this->pageId);
                $wsBaseUrl =  $viewDomain . '/index.php?id=' . $this->pageId . '&L=' . $language;
 
                // @todo - handle new pages here
                // branchpoints are not handled anymore because this feature is not supposed anymore
                if (tx_Workspaces_Service_Workspaces::isNewPage($this->pageId)) {
-                       $wsNewPageUri = $uriBuilder->uriFor('newPage', array(), $this, 'workspaces', 'web_workspacesworkspaces');
+                       $wsNewPageUri = $uriBuilder->uriFor('newPage', array(), 'Tx_Workspaces_Controller_PreviewController', 'workspaces', 'web_workspacesworkspaces');
                        $wsNewPageParams = '&tx_workspaces_web_workspacesworkspaces[controller]=Preview';
                        $this->view->assign('liveUrl', $wsSettingsPath . $wsNewPageUri . $wsNewPageParams);
                } else {
@@ -104,28 +101,24 @@ class Tx_Workspaces_Controller_PreviewController extends Tx_Workspaces_Controlle
                }
                $this->view->assign('wsUrl', $wsBaseUrl . '&ADMCMD_view=1&ADMCMD_editIcons=1&ADMCMD_previewWS=' . $GLOBALS['BE_USER']->workspace);
                $this->view->assign('wsSettingsUrl', $wsSettingsUrl);
-               $this->view->assign('wsHelpUrl', $wsHelpUrl);
                $this->view->assign('backendDomain', t3lib_div::getIndpEnv('TYPO3_HOST_ONLY'));
                $GLOBALS['BE_USER']->setAndSaveSessionData('workspaces.backend_domain', t3lib_div::getIndpEnv('TYPO3_HOST_ONLY'));
                $this->pageRenderer->addJsInlineCode("workspaces.preview.lll" , "TYPO3.LLL.Workspaces = {
                        visualPreview: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.visualPreview', true) . "',
                        listView: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.listView', true) . "',
-                       helpView: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.helpView', true) . "',
                        livePreview: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.livePreview', true) . "',
-                       workspacePreview: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.workspacePreview', true) . "'
+                       livePreviewDetail: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.livePreviewDetail', true) . "',
+                       workspacePreview: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.workspacePreview', true) . "',
+                       workspacePreviewDetail: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.workspacePreviewDetail', true) . "',
+                       modeSlider: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.modeSlider', true) . "',
+                       modeVbox: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.modeVbox', true) . "',
+                       modeHbox: '" . $GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:preview.modeHbox', true) . "'
                };\n");
        }
 
        /**
         * @return void
         */
-       public function helpAction() {
-               // @todo Implement this action
-       }
-
-       /**
-        * @return void
-        */
        public function newPageAction() {
                $message = t3lib_div::makeInstance(
                        't3lib_FlashMessage',
index 7281498..8351697 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Steffen Ritter (steffen@typo3.org)
+ *  (c) 2010-2011 Steffen Ritter (steffen@typo3.org)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -139,7 +139,7 @@ class Tx_Workspaces_Controller_ReviewController extends Tx_Workspaces_Controller
 
                        // Load  JavaScript:
                $this->pageRenderer->addExtDirectCode();
-               $this->pageRenderer->addJsFile($this->backPath . 'ajax.php?ajaxID=ExtDirect::getAPI&namespace=TYPO3.Workspaces', NULL, FALSE);
+               $this->pageRenderer->addJsFile($this->backPath . 'ajax.php?ajaxID=ExtDirect::getAPI&namespace=TYPO3.Workspaces&' . TYPO3_version, NULL, FALSE);
 
                $this->pageRenderer->addJsFile($this->backPath . '../t3lib/js/extjs/ux/flashmessages.js');
                $this->pageRenderer->addJsFile($this->backPath . '../t3lib/js/extjs/ux/Ext.grid.RowExpander.js');
index e8b532a..a631db9 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+*  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 3172536..e348d0c 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+*  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -103,11 +103,12 @@ class tx_Workspaces_ExtDirect_ActionHandler extends tx_Workspaces_ExtDirect_Abst
        /**
         * Generates a view link for a page.
         *
-        * @param string $pid
+        * @param string $table
+        * @param string $uid
         * @return void
         */
-       public function viewSingleRecord($pid) {
-               return t3lib_BEfunc::viewOnClick($pid);
+       public function viewSingleRecord($table, $uid) {
+               return tx_Workspaces_Service_Workspaces::viewSingleRecord($table, $uid);
        }
 
 
@@ -140,12 +141,12 @@ class tx_Workspaces_ExtDirect_ActionHandler extends tx_Workspaces_ExtDirect_Abst
        /**
         * Gets the dialog window to be displayed before a record can be sent to the next stage.
         *
+        *      @param integer $uid
         * @param string $table
-        * @param integer $uid
         * @param integer $t3ver_oid
         * @return array
         */
-       public function sendToNextStageWindow($table, $uid, $t3ver_oid) {
+       public function sendToNextStageWindow($uid, $table, $t3ver_oid) {
                $elementRecord = t3lib_BEfunc::getRecord($table, $uid);
 
                if(is_array($elementRecord)) {
@@ -173,11 +174,11 @@ class tx_Workspaces_ExtDirect_ActionHandler extends tx_Workspaces_ExtDirect_Abst
        /**
         * Gets the dialog window to be displayed before a record can be sent to the previous stage.
         *
-        * @param string $table
         * @param integer $uid
+        * @param string $table
         * @return array
         */
-       public function sendToPrevStageWindow($table, $uid) {
+       public function sendToPrevStageWindow($uid, $table) {
                $elementRecord = t3lib_BEfunc::getRecord($table, $uid);
 
                if(is_array($elementRecord)) {
@@ -371,7 +372,6 @@ class tx_Workspaces_ExtDirect_ActionHandler extends tx_Workspaces_ExtDirect_Abst
         */
        public function sendToSpecificStageExecute(stdClass $parameters) {
                $cmdArray = array();
-               $recipients = array();
 
                $setStageId = $parameters->affects->nextStage;
                $comments = $parameters->comments;
index af47eb7..f78a977 100644 (file)
@@ -2,8 +2,8 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 1999-2010 Kasper Skårhøj (kasperYYYY@typo3.com)
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 1999-2011 Kasper Skårhøj (kasperYYYY@typo3.com)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -38,6 +38,12 @@ class tx_Workspaces_ExtDirect_MassActionHandler extends tx_Workspaces_ExtDirect_
        const MAX_RECORDS_TO_PROCESS = 30;
 
        /**
+        * Path to the locallang file
+        * @var string
+        */
+       private $pathToLocallang = 'LLL:EXT:workspaces/Resources/Private/Language/locallang.xml';
+
+       /**
         * Get list of available mass workspace actions.
         *
         * @param object $parameter
@@ -51,16 +57,16 @@ class tx_Workspaces_ExtDirect_MassActionHandler extends tx_Workspaces_ExtDirect_
                if ($currentWorkspace != tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES) {
                        $publishAccess = $GLOBALS['BE_USER']->workspacePublishAccess($currentWorkspace);
                        if ($publishAccess && !($GLOBALS['BE_USER']->workspaceRec['publish_access'] & 1)) {
-                               $actions[] = array('action' => 'publish', 'title' => 'Publish' //$GLOBALS['LANG']->getLL('label_doaction_publish'));
+                               $actions[] = array('action' => 'publish', 'title' => $GLOBALS['LANG']->sL($this->pathToLocallang . ':label_doaction_publish')
                                );
                                if ($GLOBALS['BE_USER']->workspaceSwapAccess()) {
-                                       $actions[] = array('action' => 'swap', 'title' => 'Swap' //$GLOBALS['LANG']->getLL('label_doaction_swap')
+                                       $actions[] = array('action' => 'swap', 'title' => $GLOBALS['LANG']->sL($this->pathToLocallang . ':label_doaction_swap')
                                        );
                                }
                        }
 
                        if ($currentWorkspace !== tx_Workspaces_Service_Workspaces::LIVE_WORKSPACE_ID) {
-                               $actions[] = array('action' => 'release', 'title' => 'Release' // $GLOBALS['LANG']->getLL('label_doaction_release'));
+                               $actions[] = array('action' => 'discard', 'title' => $GLOBALS['LANG']->sL($this->pathToLocallang . ':label_doaction_discard')
                                );
                        }
                }
@@ -233,4 +239,4 @@ class tx_Workspaces_ExtDirect_MassActionHandler extends tx_Workspaces_ExtDirect_
 if (defined('TYPO3_MODE') && isset($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/ExtDirect/MassActionHandler.php'])) {
        include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/ExtDirect/MassActionHandler.php']);
 }
-?>
\ No newline at end of file
+?>
index 30b3079..f6b4607 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+*  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -45,7 +45,7 @@ class tx_Workspaces_ExtDirect_Server extends tx_Workspaces_ExtDirect_AbstractHan
                $versions = $wslibObj->selectVersionsInWorkspace($this->getCurrentWorkspace(), 0, -99, $pageId, $parameter->depth);
 
                $workspacesService = t3lib_div::makeInstance('tx_Workspaces_Service_GridData');
-               $data = $workspacesService->generateGridListFromVersions($versions, $parameter);
+               $data = $workspacesService->generateGridListFromVersions($versions, $parameter, $this->getCurrentWorkspace());
                return $data;
        }
 
@@ -80,10 +80,6 @@ class tx_Workspaces_ExtDirect_Server extends tx_Workspaces_ExtDirect_AbstractHan
                global $TCA,$BE_USER;
                $diffReturnArray = array();
                $liveReturnArray = array();
-               /**
-                * @todo  make sure this would work in local extension installation too
-                */
-               $backPath = isset($GLOBALS['BACK_PATH']) ? $GLOBALS['BACK_PATH'] : '../../../' . TYPO3_mainDir;
 
                $t3lib_diff = t3lib_div::makeInstance('t3lib_diff');
                $stagesService = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
@@ -116,8 +112,8 @@ class tx_Workspaces_ExtDirect_Server extends tx_Workspaces_ExtDirect_AbstractHan
                                        $fieldTitle = $GLOBALS['LANG']->sL(t3lib_BEfunc::getItemLabel($parameter->table, $fieldName));
 
                                        if ($TCA[$parameter->table]['columns'][$fieldName]['config']['type'] == 'group' && $TCA[$parameter->table]['columns'][$fieldName]['config']['internal_type'] == 'file') {
-                                               $versionThumb = t3lib_BEfunc::thumbCode($versionRecord, $parameter->table, $fieldName, $backPath);
-                                               $liveThumb = t3lib_BEfunc::thumbCode($liveRecord, $parameter->table, $fieldName, $backPath);
+                                               $versionThumb = t3lib_BEfunc::thumbCode($versionRecord, $parameter->table, $fieldName, '');
+                                               $liveThumb = t3lib_BEfunc::thumbCode($liveRecord, $parameter->table, $fieldName, '');
 
                                                $diffReturnArray[] = array(
                                                        'label' => $fieldTitle,
@@ -203,4 +199,4 @@ class tx_Workspaces_ExtDirect_Server extends tx_Workspaces_ExtDirect_AbstractHan
 if (defined('TYPO3_MODE') && isset($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/ExtDirect/Server.php'])) {
        include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/ExtDirect/Server.php']);
 }
-?>
\ No newline at end of file
+?>
index b4c2893..5d3d721 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+*  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index 92b40f6..4784f23 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
index dd6d5ce..1f411a5 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
index 33d98e0..0472814 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
index a828788..ce0995e 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -56,7 +56,9 @@ class tx_Workspaces_Service_Befunc {
 
                if ($GLOBALS['BE_USER']->workspace !== 0) {
                        $ctrl = t3lib_div::makeInstance('Tx_Workspaces_Controller_PreviewController', FALSE);
-                       $uriBuilder = t3lib_div::makeInstance('Tx_Extbase_MVC_Web_Routing_UriBuilder');
+                       $objectManager = t3lib_div::makeInstance('Tx_Extbase_Object_ObjectManager');
+                       /** @var $uriBuilder Tx_Extbase_MVC_Web_Routing_UriBuilder */
+                       $uriBuilder = $objectManager->create('Tx_Extbase_MVC_Web_Routing_UriBuilder');
                        /**
                         *  This seems to be very harsh to set this directly to "/typo3 but the viewOnClick also
                         *  has /index.php as fixed value here and dealing with the backPath is very error-prone
@@ -66,7 +68,7 @@ class tx_Workspaces_Service_Befunc {
                        $backPath = '/' . TYPO3_mainDir;
                                // @todo why do we need these additional params? the URIBuilder should add the controller, but he doesn't :(
                        $additionalParams = '&tx_workspaces_web_workspacesworkspaces%5Bcontroller%5D=Preview&M=web_WorkspacesWorkspaces&id=';
-                       $viewScript = $backPath . $uriBuilder->uriFor('index', array(), $ctrl, 'workspaces', 'web_workspacesworkspaces') . $additionalParams;
+                       $viewScript = $backPath . $uriBuilder->uriFor('index', array(), 'Tx_Workspaces_Controller_PreviewController', 'workspaces', 'web_workspacesworkspaces') . $additionalParams;
                }
        }
 
index c1b855c..74f8719 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
index c04dc34..557de62 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
  * @subpackage Service
  */
 class tx_Workspaces_Service_GridData {
+       protected $currentWorkspace = NULL;
        protected $dataArray = array();
        protected $sort = '';
        protected $sortDir = '';
+       protected $workspacesCache = NULL;
 
        /**
         * Generates grid list array from given versions.
@@ -41,8 +43,9 @@ class tx_Workspaces_Service_GridData {
         * @param array $versions All records uids etc. First key is table name, second key incremental integer. Records are associative arrays with uid, t3ver_oid and t3ver_swapmode fields. The pid of the online record is found as "livepid" the pid of the offline record is found in "wspid"
         * @param object $parameter
         * @return array
+        * @throws InvalidArgumentException
         */
-       public function generateGridListFromVersions($versions, $parameter) {
+       public function generateGridListFromVersions($versions, $parameter, $currentWorkspace) {
 
                        // Read the given parameters from grid. If the parameter is not set use default values.
                $filterTxt = isset($parameter->filterTxt) ? $parameter->filterTxt : '';
@@ -51,6 +54,12 @@ class tx_Workspaces_Service_GridData {
                $this->sort = isset($parameter->sort) ? $parameter->sort : 't3ver_oid';
                $this->sortDir = isset($parameter->dir) ? $parameter->dir : 'ASC';
 
+               if (is_int($currentWorkspace)) {
+                       $this->currentWorkspace = $currentWorkspace;
+               } else {
+                       throw new InvalidArgumentException('No such workspace defined');
+               }
+
                $data = array();
                $data['data'] = array();
 
@@ -72,39 +81,48 @@ class tx_Workspaces_Service_GridData {
        protected function generateDataArray(array $versions, $filterTxt) {
                /** @var $stagesObj Tx_Workspaces_Service_Stages */
                $stagesObj = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
-               
+
                /** @var $workspacesObj Tx_Workspaces_Service_Workspaces */
                $workspacesObj = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
                $availableWorkspaces = $workspacesObj->getAvailableWorkspaces();
 
-               foreach ($versions as $table => $records) {
-                       $versionArray = array('table' => $table);
+               $workspaceAccess = $GLOBALS['BE_USER']->checkWorkspace($GLOBALS['BE_USER']->workspace);
+               $swapStage = ($workspaceAccess['publish_access'] & 1) ? Tx_Workspaces_Service_Stages::STAGE_PUBLISH_ID : 0;
+               $swapAccess =  $GLOBALS['BE_USER']->workspacePublishAccess($GLOBALS['BE_USER']->workspace) &&
+                                          $GLOBALS['BE_USER']->workspaceSwapAccess();
+
+               $this->initializeWorkspacesCachingFramework();
 
-                       foreach ($records as $record) {
+               // check for dataArray in cache
+               if ($this->getDataArrayFromCache($versions, $filterTxt) == FALSE) {
+                       $stagesObj = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
 
-                               $origRecord = t3lib_BEFunc::getRecord($table, $record['t3ver_oid']);
-                               $versionRecord = t3lib_BEFunc::getRecord($table, $record['uid']);
+                       foreach ($versions as $table => $records) {
+                               $versionArray = array('table' => $table);
+
+                               foreach ($records as $record) {
+
+                                       $origRecord = t3lib_BEFunc::getRecord($table, $record['t3ver_oid']);
+                                       $versionRecord = t3lib_BEFunc::getRecord($table, $record['uid']);
 
-                               // check the given version is from an available workspace
-                               if (array_key_exists($versionRecord['t3ver_wsid'], $availableWorkspaces)) {
-                                       
                                        if (isset($GLOBALS['TCA'][$table]['columns']['hidden'])) {
                                                $recordState = $this->workspaceState($versionRecord['t3ver_state'], $origRecord['hidden'], $versionRecord['hidden']);
                                        } else {
                                                $recordState = $this->workspaceState($versionRecord['t3ver_state']);
                                        }
                                        $isDeletedPage = ($table == 'pages' && $recordState == 'deleted');
+                                       $viewUrl =  tx_Workspaces_Service_Workspaces::viewSingleRecord($table, $record['t3ver_oid'], $origRecord);
 
                                        $pctChange = $this->calculateChangePercentage($table, $origRecord, $versionRecord);
                                        $versionArray['uid'] = $record['uid'];
                                        $versionArray['workspace'] = $versionRecord['t3ver_id'];
-                                       $versionArray['label_Workspace'] = $versionRecord[$GLOBALS['TCA'][$table]['ctrl']['label']];
-                                       $versionArray['label_Live'] = $origRecord[$GLOBALS['TCA'][$table]['ctrl']['label']];
-                                       $versionArray['label_Stage'] = $stagesObj->getStageTitle($versionRecord['t3ver_stage']);
+                                       $versionArray['label_Workspace'] = htmlspecialchars($versionRecord[$GLOBALS['TCA'][$table]['ctrl']['label']]);
+                                       $versionArray['label_Live'] = htmlspecialchars($origRecord[$GLOBALS['TCA'][$table]['ctrl']['label']]);
+                                       $versionArray['label_Stage'] = htmlspecialchars($stagesObj->getStageTitle($versionRecord['t3ver_stage']));
                                        $versionArray['change'] = $pctChange;
-                                       $versionArray['path_Live'] = t3lib_BEfunc::getRecordPath($record['livepid'], '', 999);
-                                       $versionArray['path_Workspace'] = t3lib_BEfunc::getRecordPath($record['wspid'], '', 999);
-                                       $versionArray['workspace_Title'] = tx_Workspaces_Service_Workspaces::getWorkspaceTitle($versionRecord['t3ver_wsid']);
+                                       $versionArray['path_Live'] = htmlspecialchars(t3lib_BEfunc::getRecordPath($record['livepid'], '', 999));
+                                       $versionArray['path_Workspace'] = htmlspecialchars(t3lib_BEfunc::getRecordPath($record['wspid'], '', 999));
+                                       $versionArray['workspace_Title'] = htmlspecialchars(tx_Workspaces_Service_Workspaces::getWorkspaceTitle($versionRecord['t3ver_wsid']));
 
                                        $versionArray['workspace_Tstamp'] = $versionRecord['tstamp'];
                                        $versionArray['workspace_Formated_Tstamp'] = t3lib_BEfunc::datetime($versionRecord['tstamp']);
@@ -116,11 +134,17 @@ class tx_Workspaces_Service_GridData {
 
                                        $versionArray['allowedAction_nextStage'] = $stagesObj->isNextStageAllowedForUser($versionRecord['t3ver_stage']);
                                        $versionArray['allowedAction_prevStage'] = $stagesObj->isPrevStageAllowedForUser($versionRecord['t3ver_stage']);
-                                               // @todo hide the actions if the user is not allowed to edit the current stage
-                                       $versionArray['allowedAction_swap'] = $GLOBALS['BE_USER']->workspaceSwapAccess();
+
+                                       if ($swapAccess && $swapStage != 0 && $versionRecord['t3ver_stage'] == $swapStage) {
+                                               $versionArray['allowedAction_swap'] = $stagesObj->isNextStageAllowedForUser($swapStage);
+                                       } else if ($swapAccess && $swapStage == 0) {
+                                               $versionArray['allowedAction_swap'] = TRUE;
+                                       } else {
+                                               $versionArray['allowedAction_swap'] = FALSE;
+                                       }
                                        $versionArray['allowedAction_delete'] = TRUE;
                                                // preview and editing of a deleted page won't work ;)
-                                       $versionArray['allowedAction_view'] = !$isDeletedPage;
+                                       $versionArray['allowedAction_view'] = !$isDeletedPage && $viewUrl;
                                        $versionArray['allowedAction_edit'] = !$isDeletedPage;
                                        $versionArray['allowedAction_editVersionedPage'] = !$isDeletedPage;
 
@@ -131,6 +155,9 @@ class tx_Workspaces_Service_GridData {
                                        }
                                }
                        }
+                       $this->sortDataArray();
+
+                       $this->setDataArrayIntoCache($versions, $filterTxt);
                }
                $this->sortDataArray();
        }
@@ -153,6 +180,89 @@ class tx_Workspaces_Service_GridData {
                return $dataArrayPart;
        }
 
+
+       /**
+        * Initialize the workspace cache
+        *
+        * @return void
+        */
+       protected function initializeWorkspacesCachingFramework() {
+               if (TYPO3_UseCachingFramework === TRUE) {
+                       try {
+                               $GLOBALS['typo3CacheFactory']->create(
+                                       'workspaces_cache',
+                                       't3lib_cache_frontend_StringFrontend',
+                                       $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['sys_workspace_cache']['backend'],
+                                       $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['sys_workspace_cache']['options']);
+                       } catch (t3lib_cache_exception_DuplicateIdentifier $e) {
+                               // do nothing, a workspace cache already exists
+                       }
+
+                       $this->workspacesCache = $GLOBALS['typo3CacheManager']->getCache('workspaces_cache');
+               }
+       }
+
+
+       /**
+        * Put the generated dataArray into the workspace cache.
+        *
+        * @param array $versions All records uids etc. First key is table name, second key incremental integer. Records are associative arrays with uid, t3ver_oid and t3ver_swapmode fields. The pid of the online record is found as "livepid" the pid of the offline record is found in "wspid"
+        * @param string $filterTxt The given filter text from the grid.
+        */
+       protected function setDataArrayIntoCache (array $versions, $filterTxt) {
+               if (TYPO3_UseCachingFramework === TRUE) {
+                       $hash = $this->calculateHash($versions, $filterTxt);
+                       $content = serialize($this->dataArray);
+
+                       $this->workspacesCache->set($hash, $content, array($this->currentWorkspace));
+               }
+       }
+
+
+       /**
+        * Checks if a cache entry is given for given versions and filter text and tries to load the data array from cache.
+        *
+        * @param array $versions All records uids etc. First key is table name, second key incremental integer. Records are associative arrays with uid, t3ver_oid and t3ver_swapmode fields. The pid of the online record is found as "livepid" the pid of the offline record is found in "wspid"
+        * @param string $filterTxt The given filter text from the grid.
+        */
+       protected function getDataArrayFromCache (array $versions, $filterTxt) {
+               $cacheEntry = FALSE;
+
+               if (TYPO3_UseCachingFramework === TRUE) {
+                       $hash = $this->calculateHash($versions, $filterTxt);
+
+                       $content = $this->workspacesCache->get($hash);
+
+                       if ($content != FALSE) {
+                               $this->dataArray = unserialize($content);
+                               $cacheEntry = TRUE;
+                       }
+               }
+
+               return $cacheEntry;
+       }
+
+       /**
+        * Calculate the hash value of the used workspace, the user id, the versions array, the filter text, the sorting attribute, the workspace selected in grid and the sorting direction.
+        *
+        * @param array $versions All records uids etc. First key is table name, second key incremental integer. Records are associative arrays with uid, t3ver_oid and t3ver_swapmode fields. The pid of the online record is found as "livepid" the pid of the offline record is found in "wspid"
+        * @param string $filterTxt The given filter text from the grid.
+        */
+       protected function calculateHash (array $versions, $filterTxt) {
+               $hashArray = array(
+                       $GLOBALS['BE_USER']->workspace,
+                       $GLOBALS['BE_USER']->user['uid'],
+                       $versions,
+                       $filterTxt,
+                       $this->sort,
+                       $this->sortDir,
+                       $this->currentWorkspace);
+               $hash = md5(serialize($hashArray));
+
+               return $hash;
+       }
+
+
        /**
         * Performs sorting on the data array accordant to the
         * selected column in the grid view to be used for sorting.
index d4a5996..30ffe1d 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -157,29 +157,39 @@ class Tx_Workspaces_Service_Stages {
         */
        public function getStagesForWSUser() {
 
-                       // initiate return array of stages with edit stage
                $stagesForWSUserData = array();
+               $allowedStages = array();
+               $orderedAllowedStages = array();
 
-                       // get all stages for the current workspace
                $workspaceStageRecs = $this->getStagesForWS();
                if (is_array($workspaceStageRecs) && !empty($workspaceStageRecs)) {
-                               // go through custom stages records
-                       foreach ($workspaceStageRecs as $workspaceStageRec) {
-                                       // check if the user has permissions to the custom stage
-                               if ($GLOBALS['BE_USER']->workspaceCheckStageForCurrent($workspaceStageRec['uid'])) {
-                                               // yes, so add to return array
-                                       $stagesForWSUserData[] = array(
-                                               'uid' => $workspaceStageRec['uid'],
-                                               'title' => $workspaceStageRec['title']
-                                       );
-                               } else if ($workspaceStageRec['uid'] == self::STAGE_PUBLISH_EXECUTE_ID) {
-                                               if ($GLOBALS['BE_USER']->workspacePublishAccess($this->getWorkspaceId())) {
-                                                       $stagesForWSUserData[] = $workspaceStageRec;
-                                               }
+                       if ($GLOBALS['BE_USER']->isAdmin()) {
+                               $orderedAllowedStages = $workspaceStageRecs;
+                       } else {
+                               foreach ($workspaceStageRecs as $workspaceStageRec) {
+                                       if ($this->isStageAllowedForUser($workspaceStageRec['uid'])) {
+                                               $stagesForWSUserData[$workspaceStageRec['uid']] = $workspaceStageRec;
+                                       } else if ($workspaceStageRec['uid'] == self::STAGE_PUBLISH_EXECUTE_ID && $GLOBALS['BE_USER']->workspacePublishAccess($this->getWorkspaceId())) {
+                                               $allowedStages[] = $workspaceStageRec;
+                                               $stagesForWSUserData[$workspaceStageRec['uid']] = $workspaceStageRec;
+                                       }
                                }
+
+                               foreach ($stagesForWSUserData as $allowedStage) {
+                                       $nextStage = $this->getNextStage($allowedStage['uid']);
+                                       $prevStage = $this->getPrevStage($allowedStage['uid']);
+                                       if (isset($nextStage['uid'])) {
+                                               $allowedStages[$nextStage['uid']] = $nextStage;
+                                       }
+                                       if (isset($prevStage['uid'])) {
+                                               $allowedStages[$prevStage['uid']] = $prevStage;
+                                       }
+                               }
+
+                               $orderedAllowedStages = array_values($allowedStages);
                        }
                }
-               return $stagesForWSUserData;
+               return $orderedAllowedStages;
        }
 
        /**
@@ -591,7 +601,8 @@ class Tx_Workspaces_Service_Stages {
                                // if there's no prev-stage the stageIds match,
                                // otherwise we've to check if the user is permitted to use the stage
                        if (!empty($prevStage) && $prevStage['uid'] != $stageId) {
-                               $isAllowed = $this->isStageAllowedForUser($prevStage['uid']);
+                                       // if the current stage is allowed for the user, the user is also allowed to send to prev
+                               $isAllowed = $this->isStageAllowedForUser($stageId);
                        }
                } catch (Exception $e) {
                        // Exception raised - we're not allowed to go this way
@@ -613,7 +624,8 @@ class Tx_Workspaces_Service_Stages {
                                // if there's no next-stage the stageIds match,
                                // otherwise we've to check if the user is permitted to use the stage
                        if (!empty($nextStage) && $nextStage['uid'] != $stageId) {
-                               $isAllowed = $this->isStageAllowedForUser($nextStage['uid']);
+                                       // if the current stage is allowed for the user, the user is also allowed to send to next
+                               $isAllowed = $this->isStageAllowedForUser($stageId);
                        }
                } catch (Exception $e) {
                        // Exception raised - we're not allowed to go this way
@@ -630,10 +642,10 @@ class Tx_Workspaces_Service_Stages {
                $cacheKey = $this->getWorkspaceId() . '_' . $stageId;
                $isAllowed = FALSE;
                if (isset($this->workspaceStageAllowedCache[$cacheKey])) {
-                        $isAllowed = $this->workspaceStageAllowedCache[$cacheKey];
+                       $isAllowed = $this->workspaceStageAllowedCache[$cacheKey];
                 } else {
-                        $isAllowed = $GLOBALS['BE_USER']->workspaceCheckStageForCurrent($stageId);
-                        $this->workspaceStageAllowedCache[$cacheKey] = $isAllowed;
+                       $isAllowed = $GLOBALS['BE_USER']->workspaceCheckStageForCurrent($stageId);
+                       $this->workspaceStageAllowedCache[$cacheKey] = $isAllowed;
                 }
                return $isAllowed;
        }
index 3c75e44..553cb08 100644 (file)
@@ -3,7 +3,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -56,6 +56,19 @@ class tx_Workspaces_Service_Tcemain {
        }
 
        /**
+        * hook that is called AFTER all commands of the commandmap was 
+        * executed
+        *
+        * @param t3lib_TCEmain $tcemainObj reference to the main tcemain object
+        * @return      void
+        */
+       public function processCmdmap_afterFinish(t3lib_TCEmain $tcemainObj) {
+               if (TYPO3_UseCachingFramework) {
+                       $this->flushWorkspaceCacheEntriesByWorkspaceId($tcemainObj->BE_USER->workspace);
+               }
+       }
+
+       /**
         * In case a sys_workspace_stage record is deleted we do a hard reset
         * for all existing records in that stage to avoid that any of these end up
         * as orphan records.
@@ -129,6 +142,30 @@ class tx_Workspaces_Service_Tcemain {
                return $tceMain;
        }
 
+       /**
+        * Flushes the workspace cache for current workspace and for the virtual "all workspaces" too.
+        * 
+        * @param integer $workspaceId The workspace to be flushed in cache
+        * @return void
+        */
+       protected function flushWorkspaceCacheEntriesByWorkspaceId($workspaceId) {
+               if (TYPO3_UseCachingFramework === TRUE) {
+                       try {
+                               $GLOBALS['typo3CacheFactory']->create(
+                                       'workspaces_cache',
+                                       't3lib_cache_frontend_StringFrontend',
+                                       $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['sys_workspace_cache']['backend'],
+                                       $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['sys_workspace_cache']['options']);
+                       } catch (t3lib_cache_exception_DuplicateIdentifier $e) {
+                               // do nothing, a workspace cache already exists
+                       }
+       
+                       $workspacesCache = $GLOBALS['typo3CacheManager']->getCache('workspaces_cache');
+       
+                       $workspacesCache->flushByTag($workspaceId);
+                       $workspacesCache->flushByTag(tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
+               }
+       }
 }
 
 
index 89c32e1..37d843b 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
  *  Copyright notice
  *
- *  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+ *  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
  *  All rights reserved
  *
  *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -346,23 +346,42 @@ class tx_Workspaces_Service_Workspaces {
                 **/
                $perms_clause = $GLOBALS['BE_USER']->getPagePermsClause(1);
                $searchObj = t3lib_div::makeInstance('t3lib_fullsearch');
-               $pageList = $searchObj->getTreeList($pageId, $recursionLevel, 0, $perms_clause);
-
+               $pageList = FALSE;
+               if ($pageId > 0) {
+                       $pageList = $searchObj->getTreeList($pageId, $recursionLevel, 0, $perms_clause);
+               } else {
+                       $mountPoints = $GLOBALS['BE_USER']->uc['pageTree_temporaryMountPoint'];
+                       if (!is_array($mountPoints) || empty($mountPoints)) {
+                               $mountPoints = array_map('intval', $GLOBALS['BE_USER']->returnWebmounts());
+                               $mountPoints = array_unique($mountPoints);
+                       }
+                       $newList = array();
+                       foreach($mountPoints as $mountPoint) {
+                               $newList[] = $searchObj->getTreeList($mountPoint, $recursionLevel, 0, $perms_clause);
+                       }
+                       $pageList = implode(',', $newList);
+               }
                unset($searchObj);
-
                if (intval($GLOBALS['TCA']['pages']['ctrl']['versioningWS']) === 2 && $pageList) {
                        if ($pageList) {
                                        // Remove the "subbranch" if a page was moved away
                                $movedAwayPages = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows('uid, pid, t3ver_move_id', 'pages', 't3ver_move_id IN (' . $pageList . ') AND t3ver_wsid=' . $wsid . t3lib_BEfunc::deleteClause($table), '', 'uid', '', 't3ver_move_id');
-                               $newList = array();
                                $pageIds = t3lib_div::intExplode(',', $pageList, TRUE);
 
-                               foreach ($pageIds as $tmpId) {
-                                       if (isset($movedAwayPages[$tmpId]) && !empty($newList) && !in_array($movedAwayPages[$tmpId]['pid'], intval($newList))) {
-                                               break;
+                                       // move all pages away
+                               $newList = array_diff($pageIds, array_keys($movedAwayPages));
+
+                                       // move back in if still connected to the "remaining" pages
+                               do {
+                                       $changed = FALSE;
+                                       foreach ($movedAwayPages as $uid => $rec) {
+                                               if (in_array($rec['pid'], $newList) && !in_array($uid, $newList)) {
+                                                       $newList[] = $uid;
+                                                       $changed = TRUE;
+                                               }
                                        }
-                                       $newList[] = $tmpId;
-                               }
+                               } while ($changed);
+
                                $pageList = implode(',', $newList);
                        }
                                // In case moving pages is enabled we need to replace all move-to pointer with their origin
@@ -370,6 +389,9 @@ class tx_Workspaces_Service_Workspaces {
 
                        $newList = array();
                        $pageIds = t3lib_div::intExplode(',', $pageList, TRUE);
+                       if (!in_array($pageId, $pageIds)) {
+                               $pageIds[] = $pageId;
+                       }
                        foreach ($pageIds as $pageId) {
                                if (intval($pages[$pageId]['t3ver_move_id']) > 0) {
                                        $newList[] = intval($pages[$pageId]['t3ver_move_id']);
@@ -390,7 +412,7 @@ class tx_Workspaces_Service_Workspaces {
         * @return array
         */
        protected function filterPermittedElements($recs, $table) {
-               $checkField = ($table == 'pages') ? 'uid' : 'pid';
+               $checkField = ($table == 'pages') ? 'uid' : 'wspid';
                $permittedElements = array();
                if (is_array($recs)) {
                        foreach ($recs as $rec) {
@@ -455,10 +477,36 @@ class tx_Workspaces_Service_Workspaces {
                }
                return $isNewPage;
        }
+
+       /**
+        * Generates a view link for a page.
+        *
+        * @static
+        * @param  $table
+        * @param  $uid
+        * @param  $record
+        * @return string
+        */
+       public static function viewSingleRecord($table, $uid, $record=null) {
+               $viewUrl = '';
+               if ($table == 'pages') {
+                       $viewUrl = t3lib_BEfunc::viewOnClick($uid);
+               } elseif ($table == 'pages_language_oderlay' || $table == 'tt_content') {
+                       $elementRecord = is_array($record) ? $record : t3lib_BEfunc::getRecord($table, $uid);
+                       $viewUrl = t3lib_BEfunc::viewOnClick($elementRecord['pid']);
+               } else {
+                       if (isset($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['workspaces']['viewSingleRecord'])) {
+                               $_params = array('table' => $table, 'uid' => $uid, 'record' => $record);
+                               $_funcRef = $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['workspaces']['viewSingleRecord'];
+                               $viewUrl = t3lib_div::callUserFunction($_funcRef, $_params, null);
+                       }
+               }
+               return $viewUrl;
+       }
 }
 
 
 if (defined('TYPO3_MODE') && isset($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/Service/Workspaces.php'])) {
        include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/Service/Workspaces.php']);
 }
-?>
\ No newline at end of file
+?>
index 2fb5603..818b087 100644 (file)
@@ -7,11 +7,11 @@
        <data type="array">
                <languageKey index="default" type="array">
                        <label index="legend.label">Legend:</label>
-                       <label index="legend.edited">Record edited</label>
-                       <label index="legend.moved">Record moved</label>
-                       <label index="legend.deleted">Record deleted</label>
-                       <label index="legend.new">Record created</label>
-                       <label index="legend.hidden">Record hidden</label>
+                       <label index="legend.edited">edited</label>
+                       <label index="legend.moved">moved</label>
+                       <label index="legend.deleted">deleted</label>
+                       <label index="legend.new">created</label>
+                       <label index="legend.hidden">hidden</label>
                        <label index="title">Workspaces</label>
                        <label index="ok">ok</label>
                        <label index="cancel">cancel</label>
@@ -30,7 +30,7 @@
                        <label index="runMassAction.init">init</label>
                        <label index="tooltip.publishAll">Really publish entire workspace?</label>
                        <label index="tooltip.swapAll">Really swap entire workspace?</label>
-                       <label index="tooltip.releaseAll">Really release entire workspace?</label>
+                       <label index="tooltip.discardAll">Do you really want to discard changes from the whole workspace?</label>
                        <label index="tooltip.affectWholeWorkspace">Please note that this will affect all changes in the current workspace, which may be more than you are currently seeing on your screen.</label>
                        <label index="previewLink">Preview Link</label>
                        <label index="error.noResponse">The server did not send any response whether the action was successful.</label>
                        <label index="tooltip.openPage">Open version of page</label>
                        <label index="tooltip.sendToPrevStage">Send record to previous Stage</label>
                        <label index="tooltip.sendToNextStage">Send record to next Stage</label>
-                       <label index="tooltip.removeVersion">Remove version document</label>
+                       <label index="tooltip.discardVersion">Discard workspace version of record.</label>
                        <label index="tooltip.swap">Swap live and workspace versions of record</label>
-                       <label index="window.remove.title">Remove version from workspace</label>
-                       <label index="window.remove.message">Do you really want to remove this version from workspace?</label>
+                       <label index="window.discard.title">Discard workspace version of record.</label>
+                       <label index="window.discard.message">Do you really want to discard this version from workspace?</label>
                        <label index="window.swap.title">Swap version</label>
                        <label index="window.swap.message">Do you really want to swap this version?</label>
                        <label index="window.massAction.title">Prepare to start mass action</label>
                        <label index="info.newpage.detail">The previewed page has been created in a workspace and has no live counterpart.</label>
                        <label index="preview.visualPreview">Visual preview</label>
                        <label index="preview.listView">List view</label>
-                       <label index="preview.helpView">Help</label>
                        <label index="preview.livePreview">Live</label>
+                       <label index="preview.livePreviewDetail">Click this element to hide the workspace version and see the live version of the page.</label>
                        <label index="preview.workspacePreview">Workspace</label>
+                       <label index="preview.workspacePreviewDetail">Click this element to hide the live version and see the workspace version of the page.</label>
+                       <label index="preview.modeSlider">Slider</label>
+                       <label index="preview.modeVbox">Vertical</label>
+                       <label index="preview.modeHbox">Horizontal</label>
+                       <label index="label_doaction_publish">Publish</label>
+                       <label index="label_doaction_swap">Swap</label>
+                       <label index="label_doaction_discard">Discard</label>
                </languageKey>
        </data>
 </T3locallang>
index 8c611d7..1073ce4 100644 (file)
@@ -7,6 +7,8 @@
        <data type="array">
                <languageKey index="default" type="array">
                        <label index="mlang_tabs_tab">Workspaces</label>
+                       <label index="mlang_labels_tabdescr">This module contains the overview of all elements within the current workspace and it enables to continue the review and publishing workflow for them.</label>
+                       <label index="mlang_labels_tablabel">Create and handle versioning workflows</label>
                        <label index="autopublishTask.name">Workspaces auto-publication</label>
                        <label index="autopublishTask.description">This tasks checks any workspace that has a publication date set in the past and automatically publishes it.</label>
                        <label index="stage_ready_to_publish">Ready to publish</label>
index f3aa8d3..a096d75 100644 (file)
@@ -5,7 +5,7 @@
 <div id="typo3-docheader-row1">
 <div class="buttonsleft">
        <f:if condition="{pageUid} > 0">
-               <a href="#" onclick="TYPO3.Workspaces.Actions.generateWorkspacePreviewLink();return false;" title="Generate page preview" id="goPreviewLinkButton"><span class="t3-icon t3-icon-actions t3-icon-actions-move t3-icon-move-right">&nbsp;</span>Generate Workspace Preview Link</a>
+               <a href="#" onclick="TYPO3.Workspaces.Actions.generateWorkspacePreviewLink();return false;" title="Generate page preview" id="goPreviewLinkButton"><span class="t3-icon t3-icon-extensions t3-icon-extensions-workspaces t3-icon-workspaces-generatepreviewlink">&nbsp;</span>Generate Workspace Preview Link</a>
        </f:if>
 </div>
 <div class="buttonsright"><f:be.buttons.shortcut /></div>
index ddd83a1..3559e16 100644 (file)
@@ -4,13 +4,14 @@
        var liveUrl = '{liveUrl}';
        var wsUrl = '{wsUrl}';
        var wsSettingsUrl = '{wsSettingsUrl}';
-       var wsHelpUrl = '{wsHelpUrl}';
        document.domain = '{backendDomain}';
 
        function resize(height) {
-                       // poor way to avoid that we require any scrollbars within the frames 
+                       // poor way to avoid that we require any scrollbars within the frames
                var finalHeight = height * 1.1;
                Ext.getCmp('visualPanel').setHeight(finalHeight);
+               Ext.getCmp('liveContainer').setHeight((100-Ext.getCmp('sizeSlider').getValue()/100) * finalHeight);
+               Ext.getCmp('wsContainer').setHeight(finalHeight);
                Ext.getCmp('wsPanel').setHeight(finalHeight);
                Ext.getCmp('livePanel').setHeight(finalHeight);
        }
index 42623f8..5bfeb22 100644 (file)
@@ -1,19 +1,45 @@
 <script type="text/javascript">
-       document.domain =  '{backendDomain}';
 
                // @todo redirect to split module if this is opened standalone
 
-               // make sure we're in the workspace preview module 
-       if (typeof parent.resize == 'function') {
-               parent.resize(
-                       Math.max(
-                               Math.max(document.body.scrollHeight, document.documentElement.scrollHeight),
-                               Math.max(document.body.offsetHeight, document.documentElement.offsetHeight),
-                               Math.max(document.body.clientHeight, document.documentElement.clientHeight)
-                       )
-               );
+               // having this is very important, otherwise the parent.resize call will fail
+       document.domain = '{backendDomain}';
 
-               var element = document.getElementById('typo3-previewInfo');
-               element.parentNode.removeChild(element);
+       var asNumber = function(val) {
+               return isNaN(val) ? 0 : parseInt(val, 10);
+       };
+       var TYPO3 = {};
+       TYPO3.ready = function () {
+               // make sure we're in the workspace preview module
+               if (typeof parent.resize == 'function') {
+                               // try to find the height of the document
+                       var docHeight = Math.max(
+                               asNumber(window.innerHeight),
+                               asNumber(document.height),
+                               asNumber(document.body.scrollHeight),
+                               asNumber(document.body.offsetHeight),
+                               asNumber(document.body.clientHeight),
+                               asNumber(document.documentElement.scrollHeight),
+                               asNumber(document.documentElement.offsetHeight),
+                               asNumber(document.documentElement.clientHeight)
+                       );
+                       parent.resize(docHeight);
+                               // remove the ugly red box if we're in the ws-repview frames
+                       var element = document.getElementById('typo3-previewInfo');
+                       element.parentNode.removeChild(element);
+               }
+       };
+               // trigger this after content is loaded, inspired by jQuery
+       if (document.addEventListener && !/opera/.test(navigator.userAgent.toLowerCase())) {
+               document.addEventListener("DOMContentLoaded", TYPO3.ready, false);
+       } else {
+               (function() {
+                       if (document.readyState != "loaded" && document.readyState != "complete") {
+                               setTimeout(arguments.callee, 10);
+                       } else {
+                               TYPO3.ready();
+                       }
+               })();
        }
+
 </script>
index c3faa4e..629e560 100644 (file)
@@ -4,7 +4,7 @@
 
 <f:if condition="{performWorkspaceSwitch}">
 <script type="text/javascript">
-       top.TYPO3.ModuleMenu.Store.load();
+       top.TYPO3ModuleMenu.refreshMenu();
        top.TYPO3BackendWorkspaceMenu.performWorkspaceSwitch({activeWorkspaceUid}, "{activeWorkspaceTitle}");
 </script>
 </f:if>
diff --git a/typo3/sysext/workspaces/Resources/Public/Images/generate-ws-preview-link.png b/typo3/sysext/workspaces/Resources/Public/Images/generate-ws-preview-link.png
new file mode 100644 (file)
index 0000000..14348ab
Binary files /dev/null and b/typo3/sysext/workspaces/Resources/Public/Images/generate-ws-preview-link.png differ
index 57200bc..b68b6c6 100644 (file)
@@ -30,6 +30,7 @@ Ext.ns('TYPO3.Workspaces');
 TYPO3.Workspaces.Actions = {
 
        runningMassAction: null,
+       currentSendToMode: 'next',
        triggerMassAction: function(action) {
 
                switch (action) {
@@ -37,7 +38,7 @@ TYPO3.Workspaces.Actions = {
                        case 'swap':
                                this.runningMassAction = TYPO3.Workspaces.ExtDirectMassActions.publishWorkspace;
                                break;
-                       case 'release':
+                       case 'discard':
                                this.runningMassAction = TYPO3.Workspaces.ExtDirectMassActions.flushWorkspace;
                                break;
                }
@@ -80,6 +81,7 @@ TYPO3.Workspaces.Actions = {
                                top.Ext.getCmp('executeMassActionCancleButton').setText(TYPO3.lang.close);
                                top.Ext.getCmp('executeMassActionForm').show();
                                top.Ext.getCmp('executeMassActionForm').update(TYPO3.lang["runMassAction.done"].replace('%d', response.total));
+                               top.TYPO3.Backend.NavigationContainer.PageTree.refreshTree();
                        }
                }
        },
@@ -101,100 +103,70 @@ TYPO3.Workspaces.Actions = {
                        TYPO3.Workspaces.MainStore.load();
                });
        },
-       viewSingleRecord: function(pid) {
-               TYPO3.Workspaces.ExtDirectActions.viewSingleRecord(pid, function(response) {
+       viewSingleRecord: function(table, uid) {
+               TYPO3.Workspaces.ExtDirectActions.viewSingleRecord(table, uid, function(response) {
                        eval(response);
                });
        },
+       sendToStageWindow: function(response, selection) {
+               if (Ext.isObject(response.error)) {
+                       TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction(response);
+               } else {
+                       var dialog = TYPO3.Workspaces.Helpers.getSendToStageWindow({
+                               title: response.title,
+                               items: response.items,
+                               executeHandler: function(event) {
+                                       var values = top.Ext.getCmp('sendToStageForm').getForm().getValues();
+                                       affects = response.affects;
+                                       affects.elements = TYPO3.Workspaces.Helpers.getElementsArrayOfSelection(selection);
+                                       var parameters = {
+                                               affects: affects,
+                                               receipients: TYPO3.Workspaces.Helpers.getElementIdsFromFormValues(values, 'receipients'),
+                                               additional: values.additional,
+                                               comments: values.comments
+                                       };
+
+
+
+                                       TYPO3.Workspaces.Actions.sendToStageExecute(parameters);
+                                       top.TYPO3.Windows.close('sendToStageWindow');
+                                       TYPO3.Workspaces.MainStore.reload();
+                                       top.TYPO3.Backend.NavigationContainer.PageTree.refreshTree();
+                               }
+                       });
+               }
+       },
        sendToNextStageWindow: function(table, uid, t3ver_oid) {
-               TYPO3.Workspaces.ExtDirectActions.sendToNextStageWindow(table, uid, t3ver_oid, function(response) {
-                       if (Ext.isObject(response.error)) {
-                               TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction(response);
-                       } else {
-                               var dialog = TYPO3.Workspaces.Helpers.getSendToStageWindow({
-                                       title: response.title,
-                                       items: response.items,
-                                       executeHandler: function(event) {
-                                               var values = top.Ext.getCmp('sendToStageForm').getForm().getValues();
-
-                                               var parameters = {
-                                                       affects: response.affects,
-                                                       receipients: TYPO3.Workspaces.Helpers.getElementIdsFromFormValues(values, 'receipients'),
-                                                       additional: values.additional,
-                                                       comments: values.comments
-                                               };
-
-                                               TYPO3.Workspaces.Actions.sendToNextStageExecute(parameters);
-                                               top.TYPO3.Windows.close('sendToStageWindow');
-                                               TYPO3.Workspaces.MainStore.reload();
-                                       }
-                               });
-                       }
+               TYPO3.Workspaces.ExtDirectActions.sendToNextStageWindow(uid, table, t3ver_oid, function(response) {
+                       TYPO3.Workspaces.Actions.currentSendToMode = 'next';
+                       TYPO3.Workspaces.Actions.sendToStageWindow(response);
                });
        },
-       sendToPrevStageWindow: function(table, uid, t3ver_oid) {
-               TYPO3.Workspaces.ExtDirectActions.sendToPrevStageWindow(table, uid, function(response) {
-                       if (Ext.isObject(response.error)) {
-                               TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction(response);
-                       } else {
-                               var dialog = TYPO3.Workspaces.Helpers.getSendToStageWindow({
-                                       title: response.title,
-                                       items: response.items,
-                                       executeHandler: function(event) {
-                                               var values = top.Ext.getCmp('sendToStageForm').getForm().getValues();
-
-                                               var parameters = {
-                                                       affects: response.affects,
-                                                       receipients: TYPO3.Workspaces.Helpers.getElementIdsFromFormValues(values, 'receipients'),
-                                                       additional: values.additional,
-                                                       comments: values.comments
-                                               };
-
-                                               TYPO3.Workspaces.Actions.sendToPrevStageExecute(parameters);
-                                               top.TYPO3.Windows.close('sendToStageWindow');
-                                               TYPO3.Workspaces.MainStore.reload();
-                                       }
-                               });
-                       }
+       sendToPrevStageWindow: function(table, uid) {
+               TYPO3.Workspaces.ExtDirectActions.sendToPrevStageWindow(uid, table, function(response) {
+                       TYPO3.Workspaces.Actions.currentSendToMode = 'prev';
+                       TYPO3.Workspaces.Actions.sendToStageWindow(response);
                });
        },
        sendToSpecificStageWindow: function(selection, nextStage) {
                TYPO3.Workspaces.ExtDirectActions.sendToSpecificStageWindow(nextStage, function(response) {
-                       if (Ext.isObject(response.error)) {
-                               TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction(response);
-                       } else {
-                               var dialog = TYPO3.Workspaces.Helpers.getSendToStageWindow({
-                                       title: response.title,
-                                       items: response.items,
-                                       executeHandler: function(event) {
-                                               var values = top.Ext.getCmp('sendToStageForm').getForm().getValues();
-
-                                               var parameters = {
-                                                       affects: {
-                                                               nextStage: response.affects.nextStage,
-                                                               elements: TYPO3.Workspaces.Helpers.getElementsArrayOfSelection(selection)
-                                                       },
-                                                       receipients: TYPO3.Workspaces.Helpers.getElementIdsFromFormValues(values, 'receipients'),
-                                                       additional: values.additional,
-                                                       comments: values.comments
-                                               };
-
-                                               TYPO3.Workspaces.Actions.sendToSpecificStageExecute(parameters);
-                                               top.TYPO3.Windows.close('sendToStageWindow');
-                                               TYPO3.Workspaces.MainStore.reload();
-                                       }
-                               });
-                       }
+                       TYPO3.Workspaces.Actions.currentSendToMode = 'specific';
+                       TYPO3.Workspaces.Actions.sendToStageWindow(response, selection);
                });
        },
-       sendToNextStageExecute: function (parameters) {
-               TYPO3.Workspaces.ExtDirectActions.sendToNextStageExecute(parameters, TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction);
-       },
-       sendToPrevStageExecute: function (parameters) {
-               TYPO3.Workspaces.ExtDirectActions.sendToPrevStageExecute(parameters, TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction);
-       },
-       sendToSpecificStageExecute: function (parameters) {
-               TYPO3.Workspaces.ExtDirectActions.sendToSpecificStageExecute(parameters, TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction);
+       sendToStageExecute: function (parameters) {
+               switch (TYPO3.Workspaces.Actions.currentSendToMode) {
+                       case 'next':
+                               TYPO3.Workspaces.ExtDirectActions.sendToNextStageExecute(parameters, TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction);
+                       break;
+                       case 'prev':
+                               TYPO3.Workspaces.ExtDirectActions.sendToPrevStageExecute(parameters, TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction);
+                       break;
+                       case 'specific':
+                               TYPO3.Workspaces.ExtDirectActions.sendToSpecificStageExecute(parameters, TYPO3.Workspaces.Actions.handlerResponseOnExecuteAction);
+                       break;
+               }
+
        },
        updateColModel: function(colModel) {
                var dataArray = [];
@@ -233,4 +205,4 @@ TYPO3.Workspaces.Actions = {
                        top.TYPO3.Dialog.ErrorDialog({ title: 'Error' + code, msg: error.message });
                }
        }
-};
\ No newline at end of file
+};
index 4e8f06a..34522bf 100644 (file)
@@ -51,6 +51,13 @@ TYPO3.Workspaces.RowDetail.rowDataStore = new Ext.data.DirectStore({
                {name : 'icon_Workspace'}
        ]
 });
+
+Ext.override(Ext.XTemplate, {
+       exists: function(o, name) {
+               return typeof o != 'undefined' && o != null && o!='';
+       }
+});
+
 TYPO3.Workspaces.RowDetail.rowDetailTemplate = new Ext.XTemplate(
        '<div class="t3-workspaces-foldoutWrapper">',
        '<tpl for=".">',
@@ -78,7 +85,11 @@ TYPO3.Workspaces.RowDetail.rowDetailTemplate = new Ext.XTemplate(
                                                        '<table class="t3-workspaces-foldout-contentDiff">',
                                                                '<tr><th><span class="{icon_Workspace}">&nbsp;</span></th><td>{type_Workspace}</td></tr>',
                                                                '<tpl for="diff">',
-                                                                       '<tr><th>{label}</th><td>{content}</td></tr>',
+                                                                       '<tr><th>{label}</th><td>',
+                                                                               '<tpl if="this.exists(content)">',
+                                                                                       '{content}',
+                                                                               '</tpl>',
+                                                                       '</td></tr>',
                                                                '</tpl>',
                                                        '</table>',
                                                '</div>',
@@ -88,7 +99,11 @@ TYPO3.Workspaces.RowDetail.rowDetailTemplate = new Ext.XTemplate(
                                                        '<table class="t3-workspaces-foldout-contentDiff">',
                                                                '<tr><th><span class="{icon_Live}"></span></th><td>{type_Live}</td></tr>',
                                                                '<tpl for="live_record">',
-                                                                       '<tr><th>{label}</th><td>{content}</td></tr>',
+                                                                       '<tr><th>{label}</th><td>',
+                                                                               '<tpl if="this.exists(content)">',
+                                                                                       '{content}',
+                                                                               '</tpl>',
+                                                                       '</td></tr>',
                                                                '</tpl>',
                                                        '</table>',
                                                '</div>',
@@ -153,6 +168,18 @@ Ext.ux.TYPO3.Workspace.RowPanel = Ext.extend(Ext.Panel, {
 TYPO3.Workspaces.RowExpander = new Ext.grid.RowExpander({
        menuDisabled: true,
        hideable: false,
+       getRowClass : function(record, rowIndex, p, ds) {
+               cssClass = '';
+               if (!record.json.allowedAction_nextStage && !record.json.allowedAction_prevStage) {
+                       cssClass = 'typo3-workspaces-row-disabled ';
+               }
+               if(this.state[record.id]) {
+                       cssClass += 'x-grid3-row-expanded';
+               } else {
+                       cssClass += 'x-grid3-row-collapsed';
+               }
+               return cssClass;
+       },
        remoteDataMethod : function (record, index) {
                TYPO3.Workspaces.RowDetail.rowDataStore.baseParams = {
                        uid: record.json.uid,
@@ -263,4 +290,4 @@ TYPO3.Workspaces.MainStore = new Ext.data.GroupingStore({
                },
                scope : this
        }
-});
+});
\ No newline at end of file
index f546063..d9a1194 100644 (file)
@@ -153,6 +153,7 @@ TYPO3.Workspaces.Configuration.ChangeState = {
        dataIndex : 'change',
        width: 80,
        sortable: true,
+       hidden: true,
        header : TYPO3.lang["column.difference"],
        renderer: function(value, metaData) {
                return value + "%";
@@ -259,11 +260,7 @@ TYPO3.Workspaces.Configuration.RowButtons = {
                        ,tooltip: TYPO3.lang["tooltip.viewElementAction"]
                        ,handler: function(grid, rowIndex, colIndex) {
                                var record = TYPO3.Workspaces.MainStore.getAt(rowIndex);
-                               if (record.json.table == 'pages') {
-                                       TYPO3.Workspaces.Actions.viewSingleRecord(record.json.t3ver_oid);
-                               } else {
-                                       TYPO3.Workspaces.Actions.viewSingleRecord(record.json.livepid);
-                               }
+                               TYPO3.Workspaces.Actions.viewSingleRecord(record.json.table, record.json.livepid);
                        },
                        getClass: function(v, meta, rec) {
                                if(!rec.json.allowedAction_view) {
@@ -297,11 +294,11 @@ TYPO3.Workspaces.Configuration.RowButtons = {
                                if (record.json.table == 'pages') {
                                        top.loadEditId(record.json.t3ver_oid);
                                } else {
-                                       top.loadEditId(record.json.realpid);
+                                       top.loadEditId(record.json.livepid);
                                }
                        },
                        getClass: function(v, meta, rec) {
-                               if(!rec.json.allowedAction_editVersionedPage) {
+                               if(!rec.json.allowedAction_editVersionedPage || !top.TYPO3.configuration.pageModule) {
                                        return 'icon-hidden';
                                } else {
                                        return '';
@@ -310,12 +307,12 @@ TYPO3.Workspaces.Configuration.RowButtons = {
                },
                {
                        iconCls:'t3-icon t3-icon-actions t3-icon-actions-version t3-icon-version-document-remove',
-                       tooltip: TYPO3.lang["tooltip.removeVersion"],
+                       tooltip: TYPO3.lang["tooltip.discardVersion"],
                        handler: function(grid, rowIndex, colIndex) {
                                var record = TYPO3.Workspaces.MainStore.getAt(rowIndex);
                                var configuration = {
-                                       title: TYPO3.lang["window.remove.title"],
-                                       msg: TYPO3.lang["window.remove.message"],
+                                       title: TYPO3.lang["window.discard.title"],
+                                       msg: TYPO3.lang["window.discard.message"],
                                        fn: function(result) {
                                                if (result == 'yes') {
                                                        TYPO3.Workspaces.Actions.deleteSingleRecord(record.json.table, record.json.uid);
index 0628923..5472182 100644 (file)
@@ -70,6 +70,13 @@ TYPO3.Workspaces.SelectionModel = new Ext.grid.CheckboxSelectionModel({
        singleSelect: false,
        hidden: true,
        listeners: {
+               beforerowselect : function (selection, rowIndex, keep, rec) {
+                       if (rec.json.allowedAction_nextStage || rec.json.allowedAction_prevStage) {
+                               return true;
+                       } else {
+                               return false;
+                       }
+               },
                selectionchange: function (selection) {
                        var record = selection.grid.getSelectionModel().getSelections();
                        if (record.length > 0) {
@@ -130,4 +137,4 @@ TYPO3.Workspaces.WorkspaceGrid = new Ext.grid.GridPanel({
        }),
        bbar : TYPO3.Workspaces.Toolbar.FullBottomBar,
        tbar : TYPO3.Workspaces.Toolbar.FullTopToolbar
-});
+});
\ No newline at end of file
index 1703760..5f71dd2 100644 (file)
@@ -25,6 +25,8 @@
  ***************************************************************/
 
 Ext.onReady(function() {
+       var iconClsChecked = 't3-icon t3-icon-status t3-icon-status-status t3-icon-status-checked';
+       var iconClsEmpty = 't3-icon t3-icon-empty t3-icon-empty-empty t3-icon-empty';
        var viewport = new Ext.Viewport({
                layout: 'border',
                items: [{
@@ -35,96 +37,222 @@ Ext.onReady(function() {
                        plugins : [{
                                ptype : 'Ext.ux.plugins.TabStripContainer',
                                id: 'controls',
-                               width: 400,
-                               items: [{
-                                       xtype: 'button',
-                                       id: 'sizeSliderButtonLive',
-                                       cls: 'sliderButton',
-                                       text: TYPO3.LLL.Workspaces.livePreview,
-                                       width: 100,
-                                       listeners: {
-                                               click: {
-                                                       fn: function () {
-                                                               Ext.getCmp('sizeSlider').setValue(0);
-                                                       }
-                                               }
-                                       }
-                               },
-                               {
-                                       xtype: 'slider',
-                                       id: 'sizeSlider',
-                                       margins: '0 10 0 10',
-                                       maxValue: 100,
-                                       minValue: 0,
-                                       value: 100,
-                                       flex: 1,
-                                       listeners: {
-                                               change: {
-                                                       fn: function resizeFromValue(slider, newValue, thumb) {
-                                                               var height = Ext.getCmp('wsPanel').getHeight();
-                                                               Ext.getCmp('liveContainer').setHeight(height * (100 - newValue) / 100);
-                                                               Ext.getCmp('visualPanel').setHeight(height);
-                                                       }
-                                               }
-                                       }
-                               },
-                               {
-                                       xtype: 'button',
-                                       id: 'sizeSliderButtonWorkspace',
-                                       cls: 'sliderButton',
-                                       text: TYPO3.LLL.Workspaces.workspacePreview,
-                                       width: 100,
-                                       listeners: {
-                                               click: {
-                                                       fn: function () {
-                                                               Ext.getCmp('sizeSlider').setValue(100);
-                                                       }
-                                               }
-                                       }
-                               }]
+                               width: 600,
+                               items: [
+                                               {
+                                                       xtype: 'panel',
+                                                       id: 'slider',
+                                                       width: 460,
+                                                       layout: 'hbox',
+                                                       items: [
+                                                               {
+                                                                       xtype: 'button',
+                                                                       id: 'sizeSliderButtonLive',
+                                                                       cls: 'sliderButton',
+                                                                       text: TYPO3.LLL.Workspaces.livePreview,
+                                                                       tooltip: TYPO3.LLL.Workspaces.livePreviewDetail,
+                                                                       width: 100,
+                                                                       listeners: {
+                                                                               click: {
+                                                                                       fn: function () {
+                                                                                               Ext.getCmp('sizeSlider').setValue(0);
+                                                                                       }
+                                                                               }
+                                                                       }
+                                                               },
+                                                               {
+                                                                       xtype: 'slider',
+                                                                       id: 'sizeSlider',
+                                                                       margins: '0 10 0 10',
+                                                                       maxValue: 100,
+                                                                       minValue: 0,
+                                                                       value: 100,
+                                                                       width: 200,
+                                                                       flex: 1,
+                                                                       listeners: {
+                                                                               change: {
+                                                                                       fn: function resizeFromValue(slider, newValue, thumb) {
+                                                                                               var height = Ext.getCmp('wsPanel').getHeight();
+                                                                                               Ext.getCmp('liveContainer').setHeight(height * (100 - newValue) / 100);
+                                                                                               //Ext.getCmp('visualPanel').setHeight(height);
+                                                                                       }
+                                                                               }
+                                                                       }
+                                                               },
+                                                               {
+                                                                       xtype: 'button',
+                                                                       id: 'sizeSliderButtonWorkspace',
+                                                                       cls: 'sliderButton',
+                                                                       text: TYPO3.LLL.Workspaces.workspacePreview,
+                                                                       tooltip: TYPO3.LLL.Workspaces.workspacePreviewDetail,
+                                                                       width: 100,
+                                                                       listeners: {
+                                                                               click: {
+                                                                                       fn: function () {
+                                                                                               Ext.getCmp('sizeSlider').setValue(100);
+                                                                                       }
+                                                                               }
+                                                                       }
+                                                               }
+                                                       ]
+                                               },
+                                               {
+                                                       xtype: 'toolbar',
+                                                       id: 'visual-mode-toolbar',
+                                                       items: [{
+                                                               iconCls: 'x-btn-icon t3-icon t3-icon-actions t3-icon-actions-system t3-icon-system-options-view',
+                                                               id: 'visual-mode-options',
+                                                               menu: {
+                                                                       id: 'visual-mode-selector',
+                                                                       items: [{
+                                                                               text: TYPO3.LLL.Workspaces.modeSlider,
+                                                                               id: 'visual-mode-selector-slider',
+                                                                               iconCls: iconClsChecked,
+                                                                               handler: function(){
+                                                                                       Ext.getCmp('visualPanel-hbox').hide();
+                                                                                       Ext.getCmp('visualPanel-vbox').hide();
+                                                                                       Ext.getCmp('visualPanel').show();
+                                                                                       Ext.getCmp('slider').show();
+                                                                                       Ext.select('#visual-mode-selector ul li a img.t3-icon-status-checked').removeClass(iconClsChecked.split(" "))
+                                                                                       Ext.getCmp('visual-mode-selector-slider').setIconClass(iconClsChecked);
+                                                                                       Ext.getCmp('visual-mode-selector-hbox').setIconClass(iconClsEmpty);
+                                                                                       Ext.getCmp('visual-mode-selector-vbox').setIconClass(iconClsEmpty);
+                                                                               }
+                                                                       },{
+                                                                               text: TYPO3.LLL.Workspaces.modeVbox,
+                                                                               id: 'visual-mode-selector-vbox',
+                                                                               iconCls: iconClsEmpty,
+                                                                               handler: function() {
+                                                                                       Ext.getCmp('visualPanel-hbox').hide();
+                                                                                       Ext.getCmp('visualPanel-vbox').show();
+                                                                                       Ext.getCmp('visualPanel').hide();
+                                                                                       Ext.getCmp('slider').hide();
+                                                                                       Ext.select('#visual-mode-selector ul li a img.t3-icon-status-checked').removeClass(iconClsChecked.split(" "))
+                                                                                       Ext.getCmp('visual-mode-selector-slider').setIconClass(iconClsEmpty);
+                                                                                       Ext.getCmp('visual-mode-selector-vbox').setIconClass(iconClsChecked)
+                                                                                       Ext.getCmp('visual-mode-selector-hbox').setIconClass(iconClsEmpty);
+                                                                               }
+                                                                       },{
+                                                                               text: TYPO3.LLL.Workspaces.modeHbox,
+                                                                               id: 'visual-mode-selector-hbox',
+                                                                               iconCls: iconClsEmpty,
+                                                                               handler: function(){
+                                                                                       Ext.getCmp('visualPanel-hbox').show();
+                                                                                       Ext.getCmp('visualPanel-vbox').hide();
+                                                                                       Ext.getCmp('visualPanel').hide();
+                                                                                       Ext.getCmp('slider').hide();
+                                                                                       Ext.select('#visual-mode-selector ul li a img.t3-icon-status-checked').removeClass(iconClsChecked.split(" "))
+                                                                                       Ext.getCmp('visual-mode-selector-slider').setIconClass(iconClsEmpty);
+                                                                                       Ext.getCmp('visual-mode-selector-vbox').setIconClass(iconClsEmpty);
+                                                                                       Ext.getCmp('visual-mode-selector-hbox').setIconClass(iconClsChecked);
+                                                                               }
+                                                                       }]
+                                                               }
+                                                       }]
+                                               }]
                        }],
                        items: [{
                                title: TYPO3.LLL.Workspaces.visualPreview,
                                id: 'wsVisual',
                                layout: 'fit',
+                               anchor: '100% 100%',
                                items: [{
-                                       layout: 'fit',
-                                       x: 0, y:0,
+                                       layout: 'absolute',
                                        anchor: '100% 100%',
-                                       autoScroll: true,
+                                       x: 0, y:0,
                                        items: [{
-                                               layout: 'absolute',
-                                               id: 'visualPanel',
-                                               items: [{
+                                                       layout: 'fit',
+                                                       x: 0, y:0,
+                                                       anchor: '100% 100%',
+                                                       autoScroll: true,
+                                                       items: [{
+                                                               layout: 'absolute',
+                                                               id: 'visualPanel',
+                                                               items: [{
+                                                                       x: 0, y:0,
+                                                                       anchor: '100% 100%',
+                                                                       id: 'wsContainer',
+                                                                       layout: 'absolute',
+                                                                       autoScroll: false,
+                                                                       items:[{
+                                                                               xtype: 'iframePanel',
+                                                                               x: 0, y:0,
+                                                                               id: 'wsPanel',
+                                                                               doMask: false,
+                                                                               src: wsUrl,
+                                                                               autoScroll: false
+                                                                       }]
+                                                               },{
+                                                                       x: 0, y:0,
+                                                                       anchor: '100% 0%',
+                                                                       id: 'liveContainer',
+                                                                       layout: 'absolute',
+                                                                       bodyStyle: 'height:0px;border-bottom: 2px solid red;',
+                                                                       autoScroll: false,
+                                                                       items:[{
+                                                                               xtype: 'iframePanel',
+                                                                               x: 0, y:0,
+                                                                               id: 'livePanel',
+                                                                               doMask: false,
+                                                                               src: liveUrl,
+                                                                               autoScroll: false
+                                                                       }]
+                                                               }]
+                                                       }]
+                                               },{
+                                                       layout: 'hbox',
+                                                       hidden: true,
                                                        x: 0, y:0,
                                                        anchor: '100% 100%',
-                                                       id: 'wsContainer',
-                                                       layout: 'absolute',
-                                                       autoScroll: false,
-                                                       items:[{
+                                                       layoutConfig: {
+                                                               align : 'stretch',
+                                                               pack  : 'start'
+                                                       },
+                                                       id: 'visualPanel-hbox',
+                                                       items: [{
                                                                xtype: 'iframePanel',
                                                                x: 0, y:0,
-                                                               id: 'wsPanel',
+                                                               id: 'wsPanel-hbox',
                                                                doMask: false,
                                                                src: wsUrl,
-                                                               autoScroll: false
+                                                               autoScroll: false,
+                                                               flex: 1
+                                                       },{
+                                                               xtype: 'iframePanel',
+                                                               x: 0, y:0,
+                                                               id: 'livePanel-hbox',
+                                                               doMask: false,
+                                                               src: liveUrl,
+                                                               autoScroll: false,
+                                                               flex: 1
                                                        }]
-                                               },{
+                                       },{
+                                                       layout: 'vbox',
+                                                       hidden: true,
                                                        x: 0, y:0,
-                                                       anchor: '100% 0%',
-                                                       id: 'liveContainer',
-                                                       layout: 'absolute',
-                                                       bodyStyle: 'height:0px;border-bottom: 2px solid red;',
-                                                       autoScroll: false,
-                                                       items:[{
+                                                       anchor: '100% 100%',
+                                                       layoutConfig: {
+                                                               align : 'stretch',
+                                                               pack  : 'start'
+                                                       },
+                                                       id: 'visualPanel-vbox',
+                                                       items: [{
                                                                xtype: 'iframePanel',
                                                                x: 0, y:0,
-                                                               id: 'livePanel',
+                                                               id: 'wsPanel-vbox',
+                                                               doMask: false,
+                                                               src: wsUrl,
+                                                               autoScroll: false,
+                                                               flex: 1
+                                                       },{
+                                                               xtype: 'iframePanel',
+                                                               x: 0, y:0,
+                                                               id: 'livePanel-vbox',
                                                                doMask: false,
                                                                src: liveUrl,
-                                                               autoScroll: false
+                                                               autoScroll: false,
+                                                               flex: 1
                                                        }]
-                                               }]
                                        }]
                                }]
                        },{
@@ -137,16 +265,6 @@ Ext.onReady(function() {
                                        doMask: false,
                                        src: wsSettingsUrl
                                }]
-                       },{
-                               title: TYPO3.LLL.Workspaces.helpView,
-                               id: 'wsHelp',
-                               layout: 'fit',
-                               items:  [{
-                                       xtype: 'iframePanel',
-                                       id: 'settingsPanel',
-                                       doMask: false,
-                                       src: wsHelpUrl
-                               }]
                        }]
                }]
        });
index a3e852c..946f906 100644 (file)
@@ -123,8 +123,8 @@ TYPO3.Workspaces.Toolbar.selectStateMassActionCombo = new Ext.form.ComboBox({
                                case 'swap':
                                        label = TYPO3.lang["tooltip.swapAll"];
                                        break;
-                               case 'release':
-                                       label = TYPO3.lang["tooltip.releaseAll"];
+                               case 'discard':
+                                       label = TYPO3.lang["tooltip.discardAll"];
                                        break;
                        }
                        top.TYPO3.Windows.close('executeMassActionWindow');
index e8d82d7..5856c84 100644 (file)
@@ -37,16 +37,16 @@ var WorkspaceMenu = Class.create({
         * registers for resize event listener and executes on DOM ready
         */
        initialize: function() {
-               Event.observe(window, 'resize', this.positionMenu);
 
                Ext.onReady(function() {
+                       Event.observe(window, 'resize', TYPO3BackendToolbarManager.positionMenu('workspace-selector-menu'));
                        if (top.TYPO3.configuration.inWorkspace == 1) {
                                Ext.getBody().addClass('typo3-in-workspace');
                                Ext.select('#username a').insertHtml('beforeEnd', '<span id="typo3-topbar-workspaces-title">@' + top.TYPO3.Workspaces.workspaceTitle + '</span>');
                        } else {
                                Ext.getBody().removeClass('typo3-in-workspace');
                        }
-                       this.positionMenu();
+                       TYPO3BackendToolbarManager.refreshAll();
                        Event.observe('workspace-selector-menu', 'click', this.toggleMenu);
                        Event.observe('goToWsModule', 'click', this.goToWorkspaceModule.bind(this));
 
@@ -57,36 +57,6 @@ var WorkspaceMenu = Class.create({
 
                }, this);
        },
-       /**
-        * positions the menu below the toolbar icon, let's do some math!
-        */
-       positionMenu: function() {
-               var calculatedOffset = 0;
-               var parentWidth = $('workspace-selector-menu').getWidth();
-               var currentToolbarItemLayer = $$('#workspace-selector-menu ul')[0];
-               var ownWidth = currentToolbarItemLayer.getWidth();
-               var parentSiblings = $('workspace-selector-menu').previousSiblings();
-
-               parentSiblings.each(function(toolbarItem) {
-                       calculatedOffset += toolbarItem.getWidth() - 1;
-                       // -1 to compensate for the margin-right -1px of the list items,
-                       // which itself is necessary for overlaying the separator with the active state background
-
-                       if (toolbarItem.down().hasClassName('no-separator')) {
-                               calculatedOffset -= 1;
-                       }
-               });
-               calculatedOffset = calculatedOffset - ownWidth + parentWidth;
-
-               // border correction
-               if (currentToolbarItemLayer.getStyle('display') !== 'none') {
-                       calculatedOffset += 2;
-               }
-
-               $$('#workspace-selector-menu ul')[0].setStyle({
-                       left: calculatedOffset + 'px'
-               });
-       },
 
        /**
         * toggles the visibility of the menu and places it under the toolbar icon
@@ -183,7 +153,7 @@ var WorkspaceMenu = Class.create({
                        Ext.select('#typo3-topbar-workspaces-title').remove();
                }
 
-               TYPO3BackendWorkspaceMenu.positionMenu();
+               TYPO3BackendToolbarManager.refreshAll();
 
                // first remove all checks, then set the check in front of the selected workspace
                var stateActiveClass = 't3-icon t3-icon-status t3-icon-status-status t3-icon-status-checked';
index 3bed5ff..d492886 100644 (file)
@@ -187,4 +187,26 @@ div .t3-workspaces-comments-singleComment-content {
 div .t3-workspaces-comments-singleComment-content-title {
        padding: 8px 0 8px 0;
        font-weight: bold;
+}
+
+.typo3-workspaces-row-disabled .x-grid3-td-checker {
+       visibility: hidden;
+}
+
+div.x-grid3-row img.t3-icon-extensions-workspaces {
+       display: inline-block !important;
+       width: 17px;
+       visibility: hidden;
+}
+
+div.x-grid3-row-over img.t3-icon-extensions-workspaces {
+       visibility: visible;
+}
+
+img.t3-icon-workspaces-sendtonextstage {
+       background-position: 0 4px !important;
+}
+
+img.t3-icon-workspaces-sendtoprevstage {
+       background-position: 0 4px !important;
 }
\ No newline at end of file
index e9fdb1a..52b773d 100644 (file)
@@ -103,7 +103,10 @@ ul.x-tab-strip-top {
  * Slider
  */
 #controls {
-       padding-top: 10px;
+       padding-top: 5px;
+}
+#slider {
+       padding-top: 5px;
 }
 
 /* remove default ExtJS border */
@@ -143,6 +146,48 @@ ul.x-tab-strip-top {
        text-align: left;
 }
 
+#visual-mode-selector {
+       list-style: none;
+       background-color: #f9f9f9;
+       border: 1px solid #abb2bc;
+       border-top: none;
+}
+
+#visual-mode-selector td {
+       text-align: left;
+}
+
+#visual-mode-selector td button {
+       font-size: 11px;
+       line-height: 12px;
+       text-decoration: none;
+}
+
+#visual-mode-options {
+       display: block;
+       height: 20px;
+       margin: 5px 0 0 0;
+}
+#visual-mode-options.x-btn-menu-active {
+       background-color: #f9f9f9;
+       border: 1px solid #abb2bc;
+       border-bottom: none;
+}
+#visual-mode-options .x-btn-arrow {
+       padding-right: 2px;
+}
+
+#visual-mode-options .x-btn-text {
+       font-size: 11px;
+}
+#visual-mode-options.x-btn-menu-active .x-btn-text {
+       color: black;
+}
+
+#visual-mode-toolbar {
+       border:none;
+}
+
 /**
  * Preview panel
  */
index 5973895..193c4ac 100644 (file)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 2010 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
+*  (c) 2010-2011 Workspaces Team (http://forge.typo3.org/projects/show/typo3v4-workspaces)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
index e9e7c0c..54e9704 100644 (file)
@@ -3,7 +3,7 @@
 ########################################################################
 # Extension Manager/Repository config file for ext "workspaces".
 #
-# Auto generated 12-01-2011 11:33
+# Auto generated 21-01-2011 19:08
 #
 # Manual updates:
 # Only the data in the array - everything else is removed by next
@@ -26,10 +26,10 @@ $EM_CONF[$_EXTKEY] = array(
        'uploadfolder' => 0,
        'createDirs' => '',
        'modify_tables' => '',
-       'clearCacheOnLoad' => 0,
+       'clearCacheOnLoad' => 1,
        'lockType' => '',
        'author_company' => '',
-       'version' => '4.5.0beta4',
+       'version' => '4.5.0rc1',
        'constraints' => array(
                'depends' => array(
                        'typo3' => '4.5.0-0.0.0',
@@ -42,7 +42,7 @@ $EM_CONF[$_EXTKEY] = array(
                'suggests' => array(
                ),
        ),
-       '_md5_values_when_last_written' => 'a:83:{s:9:"ChangeLog";s:4:"278b";s:16:"ext_autoload.php";s:4:"678b";s:12:"ext_icon.gif";s:4:"55bc";s:17:"ext_localconf.php";s:4:"ef02";s:14:"ext_tables.php";s:4:"e640";s:14:"ext_tables.sql";s:4:"d4ef";s:7:"tca.php";s:4:"6a88";s:61:"Classes/BackendUserInterface/WorkspaceSelectorToolbarItem.php";s:4:"4e87";s:41:"Classes/Controller/AbstractController.php";s:4:"c53f";s:40:"Classes/Controller/PreviewController.php";s:4:"21ff";s:39:"Classes/Controller/ReviewController.php";s:4:"2722";s:37:"Classes/ExtDirect/AbstractHandler.php";s:4:"0d8b";s:35:"Classes/ExtDirect/ActionHandler.php";s:4:"3353";s:39:"Classes/ExtDirect/MassActionHandler.php";s:4:"2722";s:28:"Classes/ExtDirect/Server.php";s:4:"3cf0";s:33:"Classes/ExtDirect/ToolbarMenu.php";s:4:"3b94";s:34:"Classes/Reports/StatusProvider.php";s:4:"5708";s:31:"Classes/Service/AutoPublish.php";s:4:"08fb";s:35:"Classes/Service/AutoPublishTask.php";s:4:"b0a9";s:26:"Classes/Service/Befunc.php";s:4:"de67";s:27:"Classes/Service/Fehooks.php";s:4:"92bd";s:28:"Classes/Service/GridData.php";s:4:"41f7";s:26:"Classes/Service/Stages.php";s:4:"d119";s:27:"Classes/Service/Tcemain.php";s:4:"2b7a";s:30:"Classes/Service/Workspaces.php";s:4:"6ca1";s:40:"Resources/Private/Language/locallang.xml";s:4:"505c";s:56:"Resources/Private/Language/locallang_csh_sysws_stage.xml";s:4:"d2f3";s:43:"Resources/Private/Language/locallang_db.xml";s:4:"57f7";s:44:"Resources/Private/Language/locallang_mod.xml";s:4:"9fc7";s:37:"Resources/Private/Layouts/module.html";s:4:"bbcf";s:36:"Resources/Private/Layouts/nodoc.html";s:4:"a3ce";s:36:"Resources/Private/Layouts/popup.html";s:4:"d53b";s:38:"Resources/Private/Partials/legend.html";s:4:"246f";s:42:"Resources/Private/Partials/navigation.html";s:4:"b186";s:45:"Resources/Private/Templates/Preview/Help.html";s:4:"a77a";s:46:"Resources/Private/Templates/Preview/Index.html";s:4:"ff3a";s:48:"Resources/Private/Templates/Preview/NewPage.html";s:4:"6cbc";s:48:"Resources/Private/Templates/Preview/Preview.html";s:4:"1921";s:49:"Resources/Private/Templates/Review/FullIndex.html";s:4:"478e";s:45:"Resources/Private/Templates/Review/Index.html";s:4:"e64a";s:51:"Resources/Private/Templates/Review/SingleIndex.html";s:4:"7b9d";s:30:"Resources/Public/Images/bg.gif";s:4:"916d";s:38:"Resources/Public/Images/moduleicon.gif";s:4:"55bc";s:37:"Resources/Public/Images/slider-bg.png";s:4:"f5e8";s:40:"Resources/Public/Images/slider-thumb.png";s:4:"86d8";s:38:"Resources/Public/Images/typo3-logo.png";s:4:"284a";s:61:"Resources/Public/Images/version-workspace-sendtonextstage.png";s:4:"46fa";s:61:"Resources/Public/Images/version-workspace-sendtoprevstage.png";s:4:"851d";s:53:"Resources/Public/Images/workspaces-comments-arrow.gif";s:4:"2423";s:63:"Resources/Public/JavaScript/Ext.ux.plugins.TabStripContainer.js";s:4:"d8f2";s:38:"Resources/Public/JavaScript/actions.js";s:4:"274f";s:40:"Resources/Public/JavaScript/component.js";s:4:"62ac";s:44:"Resources/Public/JavaScript/configuration.js";s:4:"2950";s:35:"Resources/Public/JavaScript/grid.js";s:4:"cbce";s:38:"Resources/Public/JavaScript/helpers.js";s:4:"a391";s:38:"Resources/Public/JavaScript/preview.js";s:4:"0583";s:38:"Resources/Public/JavaScript/toolbar.js";s:4:"a1b7";s:44:"Resources/Public/JavaScript/workspacegrid.js";s:4:"0bb3";s:44:"Resources/Public/JavaScript/workspacemenu.js";s:4:"d47b";s:41:"Resources/Public/JavaScript/workspaces.js";s:4:"4fef";s:54:"Resources/Public/JavaScript/gridfilters/GridFilters.js";s:4:"4b22";s:59:"Resources/Public/JavaScript/gridfilters/css/GridFilters.css";s:4:"84a8";s:57:"Resources/Public/JavaScript/gridfilters/css/RangeMenu.css";s:4:"745a";s:63:"Resources/Public/JavaScript/gridfilters/filter/BooleanFilter.js";s:4:"3c02";s:60:"Resources/Public/JavaScript/gridfilters/filter/DateFilter.js";s:4:"c80d";s:56:"Resources/Public/JavaScript/gridfilters/filter/Filter.js";s:4:"583f";s:60:"Resources/Public/JavaScript/gridfilters/filter/ListFilter.js";s:4:"9554";s:63:"Resources/Public/JavaScript/gridfilters/filter/NumericFilter.js";s:4:"91a2";s:62:"Resources/Public/JavaScript/gridfilters/filter/StringFilter.js";s:4:"acc8";s:57:"Resources/Public/JavaScript/gridfilters/images/equals.png";s:4:"87b7";s:55:"Resources/Public/JavaScript/gridfilters/images/find.png";s:4:"9f1c";s:63:"Resources/Public/JavaScript/gridfilters/images/greater_than.png";s:4:"746c";s:60:"Resources/Public/JavaScript/gridfilters/images/less_than.png";s:4:"2fb7";s:68:"Resources/Public/JavaScript/gridfilters/images/sort_filtered_asc.gif";s:4:"9e7a";s:69:"Resources/Public/JavaScript/gridfilters/images/sort_filtered_desc.gif";s:4:"6d59";s:56:"Resources/Public/JavaScript/gridfilters/menu/ListMenu.js";s:4:"d14b";s:57:"Resources/Public/JavaScript/gridfilters/menu/RangeMenu.js";s:4:"0bbd";s:38:"Resources/Public/StyleSheet/module.css";s:4:"ed43";s:39:"Resources/Public/StyleSheet/preview.css";s:4:"be3b";s:31:"Tests/Service/WorkspaceTest.php";s:4:"edc8";s:41:"Tests/Service/fixtures/dbDefaultPages.xml";s:4:"a86b";s:46:"Tests/Service/fixtures/dbDefaultWorkspaces.xml";s:4:"32a7";s:41:"Tests/Service/fixtures/dbMovedContent.xml";s:4:"dd73";}',
+       '_md5_values_when_last_written' => 'a:84:{s:9:"ChangeLog";s:4:"5dad";s:16:"ext_autoload.php";s:4:"678b";s:12:"ext_icon.gif";s:4:"55bc";s:17:"ext_localconf.php";s:4:"bac0";s:14:"ext_tables.php";s:4:"8e56";s:14:"ext_tables.sql";s:4:"6ecf";s:7:"tca.php";s:4:"1741";s:61:"Classes/BackendUserInterface/WorkspaceSelectorToolbarItem.php";s:4:"d60e";s:41:"Classes/Controller/AbstractController.php";s:4:"5014";s:40:"Classes/Controller/PreviewController.php";s:4:"d2a2";s:39:"Classes/Controller/ReviewController.php";s:4:"8c58";s:37:"Classes/ExtDirect/AbstractHandler.php";s:4:"26ef";s:35:"Classes/ExtDirect/ActionHandler.php";s:4:"77ff";s:39:"Classes/ExtDirect/MassActionHandler.php";s:4:"a5f7";s:28:"Classes/ExtDirect/Server.php";s:4:"3a1d";s:33:"Classes/ExtDirect/ToolbarMenu.php";s:4:"9ca4";s:34:"Classes/Reports/StatusProvider.php";s:4:"8add";s:31:"Classes/Service/AutoPublish.php";s:4:"ff76";s:35:"Classes/Service/AutoPublishTask.php";s:4:"f886";s:26:"Classes/Service/Befunc.php";s:4:"c838";s:27:"Classes/Service/Fehooks.php";s:4:"81bb";s:28:"Classes/Service/GridData.php";s:4:"aaf0";s:26:"Classes/Service/Stages.php";s:4:"5777";s:27:"Classes/Service/Tcemain.php";s:4:"6f0e";s:30:"Classes/Service/Workspaces.php";s:4:"2130";s:40:"Resources/Private/Language/locallang.xml";s:4:"9b96";s:56:"Resources/Private/Language/locallang_csh_sysws_stage.xml";s:4:"d2f3";s:43:"Resources/Private/Language/locallang_db.xml";s:4:"57f7";s:44:"Resources/Private/Language/locallang_mod.xml";s:4:"8b66";s:37:"Resources/Private/Layouts/module.html";s:4:"290c";s:36:"Resources/Private/Layouts/nodoc.html";s:4:"a3ce";s:36:"Resources/Private/Layouts/popup.html";s:4:"2e46";s:38:"Resources/Private/Partials/legend.html";s:4:"246f";s:42:"Resources/Private/Partials/navigation.html";s:4:"b186";s:45:"Resources/Private/Templates/Preview/Help.html";s:4:"a77a";s:46:"Resources/Private/Templates/Preview/Index.html";s:4:"ff3a";s:48:"Resources/Private/Templates/Preview/NewPage.html";s:4:"6cbc";s:48:"Resources/Private/Templates/Preview/Preview.html";s:4:"fa67";s:49:"Resources/Private/Templates/Review/FullIndex.html";s:4:"478e";s:45:"Resources/Private/Templates/Review/Index.html";s:4:"159f";s:51:"Resources/Private/Templates/Review/SingleIndex.html";s:4:"7b9d";s:30:"Resources/Public/Images/bg.gif";s:4:"916d";s:52:"Resources/Public/Images/generate-ws-preview-link.png";s:4:"e107";s:38:"Resources/Public/Images/moduleicon.gif";s:4:"55bc";s:37:"Resources/Public/Images/slider-bg.png";s:4:"f5e8";s:40:"Resources/Public/Images/slider-thumb.png";s:4:"86d8";s:38:"Resources/Public/Images/typo3-logo.png";s:4:"284a";s:61:"Resources/Public/Images/version-workspace-sendtonextstage.png";s:4:"46fa";s:61:"Resources/Public/Images/version-workspace-sendtoprevstage.png";s:4:"851d";s:53:"Resources/Public/Images/workspaces-comments-arrow.gif";s:4:"2423";s:63:"Resources/Public/JavaScript/Ext.ux.plugins.TabStripContainer.js";s:4:"d8f2";s:38:"Resources/Public/JavaScript/actions.js";s:4:"7607";s:40:"Resources/Public/JavaScript/component.js";s:4:"a376";s:44:"Resources/Public/JavaScript/configuration.js";s:4:"16a9";s:35:"Resources/Public/JavaScript/grid.js";s:4:"e1b5";s:38:"Resources/Public/JavaScript/helpers.js";s:4:"a391";s:38:"Resources/Public/JavaScript/preview.js";s:4:"c557";s:38:"Resources/Public/JavaScript/toolbar.js";s:4:"3c79";s:44:"Resources/Public/JavaScript/workspacegrid.js";s:4:"0bb3";s:44:"Resources/Public/JavaScript/workspacemenu.js";s:4:"4a9e";s:41:"Resources/Public/JavaScript/workspaces.js";s:4:"4fef";s:54:"Resources/Public/JavaScript/gridfilters/GridFilters.js";s:4:"4b22";s:59:"Resources/Public/JavaScript/gridfilters/css/GridFilters.css";s:4:"84a8";s:57:"Resources/Public/JavaScript/gridfilters/css/RangeMenu.css";s:4:"745a";s:63:"Resources/Public/JavaScript/gridfilters/filter/BooleanFilter.js";s:4:"3c02";s:60:"Resources/Public/JavaScript/gridfilters/filter/DateFilter.js";s:4:"c80d";s:56:"Resources/Public/JavaScript/gridfilters/filter/Filter.js";s:4:"583f";s:60:"Resources/Public/JavaScript/gridfilters/filter/ListFilter.js";s:4:"9554";s:63:"Resources/Public/JavaScript/gridfilters/filter/NumericFilter.js";s:4:"91a2";s:62:"Resources/Public/JavaScript/gridfilters/filter/StringFilter.js";s:4:"acc8";s:57:"Resources/Public/JavaScript/gridfilters/images/equals.png";s:4:"87b7";s:55:"Resources/Public/JavaScript/gridfilters/images/find.png";s:4:"9f1c";s:63:"Resources/Public/JavaScript/gridfilters/images/greater_than.png";s:4:"746c";s:60:"Resources/Public/JavaScript/gridfilters/images/less_than.png";s:4:"2fb7";s:68:"Resources/Public/JavaScript/gridfilters/images/sort_filtered_asc.gif";s:4:"9e7a";s:69:"Resources/Public/JavaScript/gridfilters/images/sort_filtered_desc.gif";s:4:"6d59";s:56:"Resources/Public/JavaScript/gridfilters/menu/ListMenu.js";s:4:"d14b";s:57:"Resources/Public/JavaScript/gridfilters/menu/RangeMenu.js";s:4:"0bbd";s:38:"Resources/Public/StyleSheet/module.css";s:4:"1dfd";s:39:"Resources/Public/StyleSheet/preview.css";s:4:"b66e";s:31:"Tests/Service/WorkspaceTest.php";s:4:"2b56";s:41:"Tests/Service/fixtures/dbDefaultPages.xml";s:4:"a86b";s:46:"Tests/Service/fixtures/dbDefaultWorkspaces.xml";s:4:"32a7";s:41:"Tests/Service/fixtures/dbMovedContent.xml";s:4:"dd73";}',
        'suggests' => array(
        ),
 );
index 805d63d..88b1207 100644 (file)
@@ -20,4 +20,15 @@ $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['proc
 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_befunc.php']['viewOnClickClass']['workspaces'] = 'EXT:workspaces/Classes/Service/Tcemain.php:tx_Workspaces_Service_Befunc';
 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_fe.php']['hook_eofe']['workspaces'] = 'EXT:workspaces/Classes/Service/Fehooks.php:tx_Workspaces_Service_Fehooks->hook_eofe';
 
+if ($GLOBALS['TYPO3_CONF_VARS']['SYS']['useCachingFramework']) {
+               // Initialize the caching framework. The caching framework is asking it self if it is initialized already before initializing.
+       t3lib_cache::initializeCachingFramework();
+       
+       $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['sys_workspace_cache']['backend'] = 't3lib_cache_backend_DbBackend';
+       $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['sys_workspace_cache']['options'] = array(
+               'cacheTable' => 'sys_workspace_cache',
+               'tagsTable' => 'sys_workspace_cache_tags'
+       );
+}
+
 ?>
\ No newline at end of file
index 201c798..f5fe7e8 100644 (file)
@@ -2,8 +2,8 @@
 if (!defined ('TYPO3_MODE')) {
        die ('Access denied.');
 }
-       // avoid that this block is loaded in the frontend or within the upgrade-wizards 
-if (TYPO3_MODE == 'BE' && PATH_typo3_mod != 'install/') {
+       // avoid that this block is loaded in the frontend or within the upgrade-wizards
+if (TYPO3_MODE == 'BE' && !(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_INSTALL)) { 
        /**
        * Registers a Backend Module
        */
@@ -15,7 +15,7 @@ if (TYPO3_MODE == 'BE' && PATH_typo3_mod != 'install/') {
                array(
                                // An array holding the controller-action-combinations that are accessible
                        'Review'                => 'index,fullIndex,singleIndex',
-                       'Preview'               => 'index,help,newPage'
+                       'Preview'               => 'index,newPage'
                ),
                array(
                        'access' => 'user,group',
@@ -32,7 +32,7 @@ if (TYPO3_MODE == 'BE' && PATH_typo3_mod != 'install/') {
        $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ExtDirect']['TYPO3.Ajax.ExtDirect.ToolbarMenu'] = t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/ToolbarMenu.php:tx_Workspaces_ExtDirect_ToolbarMenu';
 
                // register the reports statusprovider
-       $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['Configuration'][] = 'Tx_Workspaces_Reports_StatusProvider';
+       $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['configuration'][] = 'Tx_Workspaces_Reports_StatusProvider';
 
 
 }
@@ -84,6 +84,7 @@ $TCA['sys_workspace_stage'] = array(
 $icons = array(
        'sendtonextstage' => t3lib_extMgm::extRelPath($_EXTKEY) . 'Resources/Public/Images/version-workspace-sendtonextstage.png',
        'sendtoprevstage' => t3lib_extMgm::extRelPath($_EXTKEY) . 'Resources/Public/Images/version-workspace-sendtoprevstage.png',
+       'generatepreviewlink' => t3lib_extMgm::extRelPath($_EXTKEY) . 'Resources/Public/Images/generate-ws-preview-link.png',
 );
 t3lib_SpriteManager::addSingleIcons($icons, $_EXTKEY);
 t3lib_extMgm::addLLrefForTCAdescr('sys_workspace_stage','EXT:workspaces/Resources/Private/Language/locallang_csh_sysws_stage.xml');
index 60be2f6..3a0f570 100644 (file)
@@ -17,7 +17,6 @@ CREATE TABLE sys_workspace (
   unpublish_time int(11) DEFAULT '0' NOT NULL,
   freeze tinyint(3) DEFAULT '0' NOT NULL,
   live_edit tinyint(3) DEFAULT '0' NOT NULL,
-  review_stage_edit tinyint(3) DEFAULT '0' NOT NULL,
   vtypes tinyint(3) DEFAULT '0' NOT NULL,
   disable_autocreate tinyint(1) DEFAULT '0' NOT NULL,
   swap_modes tinyint(3) DEFAULT '0' NOT NULL,
@@ -48,3 +47,30 @@ CREATE TABLE sys_workspace_stage (
        PRIMARY KEY (uid),
        KEY parent (pid)
 );
+
+
+#
+# Table structure for table 'sys_workspace_cache'
+#
+CREATE TABLE sys_workspace_cache (
+    id int(11) unsigned NOT NULL auto_increment,
+    identifier varchar(32) DEFAULT '' NOT NULL,
+    content mediumblob NOT NULL,
+    crdate int(11) DEFAULT '0' NOT NULL,
+    lifetime int(11) DEFAULT '0' NOT NULL,    
+      PRIMARY KEY (id),
+      KEY cache_id (identifier)
+) ENGINE=InnoDB;
+
+
+#
+# Table structure for table 'sys_workspace_cache_tags'
+#
+CREATE TABLE sys_workspace_cache_tags (
+  id int(11) unsigned NOT NULL auto_increment,
+  identifier varchar(128) DEFAULT '' NOT NULL,
+  tag varchar(128) DEFAULT '' NOT NULL,
+  PRIMARY KEY (id),
+  KEY cache_id (identifier),
+  KEY cache_tag (tag)
+) ENGINE=InnoDB;
index 268805e..6038073 100644 (file)
@@ -111,7 +111,8 @@ $TCA['sys_workspace'] = array(
                                'range' => array(
                                        'upper' => mktime(0,0,0,12,31,2020),
                                )
-                       )
+                       ),
+                       'displayCond' => 'FALSE'                        // this feature doesn't work yet therefore it's not shown by default
                ),
                'freeze' => array(
                        'label' => 'LLL:EXT:lang/locallang_tca.xml:sys_workspace.freeze',
@@ -127,13 +128,6 @@ $TCA['sys_workspace'] = array(
                                'default' => '0'
                        )
                ),
-               'review_stage_edit' => array(
-                       'label' => 'LLL:EXT:lang/locallang_tca.xml:sys_workspace.review_stage_edit',
-                       'config' => array(
-                               'type' => 'check',
-                               'default' => '0'
-                       )
-               ),
                'disable_autocreate' => array(
                        'label' => 'LLL:EXT:lang/locallang_tca.xml:sys_workspace.disable_autocreate',
                        'config' => array(
@@ -193,7 +187,7 @@ $TCA['sys_workspace'] = array(
                        --div--;LLL:EXT:lang/locallang_tca.xml:sys_filemounts.tabs.mountpoints,db_mountpoints,file_mountpoints,
                        --div--;LLL:EXT:lang/locallang_tca.xml:sys_filemounts.tabs.publishing,publish_time,unpublish_time,
                        --div--;LLL:EXT:workspaces/Resources/Private/Language/locallang_db.xml:sys_filemounts.tabs.staging,custom_stages,
-                       --div--;LLL:EXT:lang/locallang_tca.xml:sys_filemounts.tabs.other,freeze,live_edit,review_stage_edit,disable_autocreate,swap_modes,publish_access'
+                       --div--;LLL:EXT:lang/locallang_tca.xml:sys_filemounts.tabs.other,freeze,live_edit,disable_autocreate,swap_modes,publish_access'
                )
        )
 );