+++ /dev/null
-<?php
-/***************************************************************
-* Copyright notice
-*
-* (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
-* free software; you can redistribute it and/or modify
-* it under the terms of the GNU General Public License as published by
-* the Free Software Foundation; either version 2 of the License, or
-* (at your option) any later version.
-*
-* The GNU General Public License can be found at
-* http://www.gnu.org/copyleft/gpl.html.
-* A copy is found in the textfile GPL.txt and important notices to the license
-* from the author is found in LICENSE.txt distributed with these scripts.
-*
-*
-* This script is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-* GNU General Public License for more details.
-*
-* This copyright notice MUST APPEAR in all copies of the script!
-***************************************************************/
-
-if(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_AJAX) {
- require_once(PATH_typo3 . 'interfaces/interface.backend_toolbaritem.php');
-}
-
-/**
- * class to render the workspace selector
- *
- * @author Ingo Renner <ingo@typo3.org>
- * @package Workspaces
- * @subpackage BackendUserInterface
- */
-class WorkspaceSelectorToolbarItem implements backend_toolbarItem {
-
- protected $changeWorkspace;
- protected $changeWorkspacePreview;
-
- /**
- * reference back to the backend object
- *
- * @var TYPO3backend
- */
- protected $backendReference;
-
- protected $checkAccess = NULL;
-
- /**
- * constructor
- *
- * @param TYPO3backend TYPO3 backend object reference
- */
- public function __construct(TYPO3backend &$backendReference = NULL) {
- $this->backendReference = $backendReference;
- $this->changeWorkspace = t3lib_div::_GP('changeWorkspace');
- $this->changeWorkspacePreview = t3lib_div::_GP('changeWorkspacePreview');
-
- $pageRenderer = t3lib_div::makeInstance('t3lib_pageRenderer');
- $this->backendReference->addJavaScript("TYPO3.Workspaces = { workspaceTitle : '" . htmlspecialchars(tx_Workspaces_Service_Workspaces::getWorkspaceTitle($GLOBALS['BE_USER']->workspace)) . "'};\n");
- }
-
- /**
- * checks whether the user has access to this toolbar item
- *
- * @see typo3/alt_shortcut.php
- * @return boolean TRUE if user has access, FALSE if not
- */
- public function checkAccess() {
- if (t3lib_extMgm::isLoaded('workspaces')) {
- if ($this->checkAccess == NULL) {
- $availableWorkspaces = tx_Workspaces_Service_Workspaces::getAvailableWorkspaces();
- if (count($availableWorkspaces) > 0) {
- $this->checkAccess = TRUE;
- } else {
- $this->checkAccess = FALSE;
- }
- }
- return $this->checkAccess;
- }
- return FALSE;
- }
-
- /**
- * Creates the selector for workspaces
- *
- * @return string workspace selector as HTML select
- */
- public function render() {
- $title = $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:toolbarItems.workspace', TRUE);
- $this->addJavascriptToBackend();
- $availableWorkspaces = tx_Workspaces_Service_Workspaces::getAvailableWorkspaces();
- $workspaceMenu = array();
-
- $stateCheckedIcon = t3lib_iconWorks::getSpriteIcon('status-status-checked');
-
- $stateUncheckedIcon = t3lib_iconWorks::getSpriteIcon('empty-empty', array(
- 'title' => $GLOBALS['LANG']->getLL('bookmark_inactive')
- ));
-
- $workspaceMenu[] = '<a href="#" class="toolbar-item">' .
- t3lib_iconWorks::getSpriteIcon('apps-toolbar-menu-workspace', array('title' => $title)) .
- '</a>';
- $workspaceMenu[] = '<ul class="toolbar-item-menu" style="display: none;">';
-
- if (count($availableWorkspaces)) {
- foreach($availableWorkspaces as $workspaceId => $label) {
- $selected = '';
- $icon = $stateUncheckedIcon;
- if((int) $GLOBALS['BE_USER']->workspace === $workspaceId) {
- $selected = ' class="selected"';
- $icon = $stateCheckedIcon;
- }
-
- $workspaceMenu[] = '<li' . $selected . '>' . $icon .
- ' <a href="backend.php?changeWorkspace=' .
- intval($workspaceId) . '" id="ws-' . intval($workspaceId) .
- '" class="ws">' . $label . '</a></li>';
- }
- } else {
- $workspaceMenu[] = '<li>' . $stateUncheckedIcon . ' ' .
- $GLOBALS['LANG']->getLL('bookmark_noWSfound', TRUE) .
- '</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>';
-
- return implode(LF, $workspaceMenu);
- }
-
- /**
- * adds the necessary JavaScript to the backend
- *
- * @return void
- */
- protected function addJavascriptToBackend() {
- $this->backendReference->addJavascriptFile(t3lib_extMgm::extRelPath('workspaces') . 'Resources/Public/JavaScript/workspacemenu.js');
- }
-
- /**
- * returns additional attributes for the list item in the toolbar
- *
- * @return string list item HTML attibutes
- */
- public function getAdditionalAttributes() {
- return ' id="workspace-selector-menu"';
- }
-}
-
-
-if(!(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_AJAX)) {
- $GLOBALS['TYPO3backend']->addToolbarItem('workSpaceSelector', 'WorkspaceSelectorToolbarItem');
-}
-
-
-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
+++ /dev/null
-<?php
-/***************************************************************
- * Copyright notice
- *
- * (c) 2011 Tolleiv Nietsch <typo3@tolleiv.de>
- * All rights reserved
- *
- * This script is part of the TYPO3 project. The TYPO3 project is
- * free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * The GNU General Public License can be found at
- * http://www.gnu.org/copyleft/gpl.html.
- * A copy is found in the textfile GPL.txt and important notices to the license
- * from the author is found in LICENSE.txt distributed with these scripts.
- *
- *
- * This script is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * This copyright notice MUST APPEAR in all copies of the script!
- ***************************************************************/
-
-/**
- * Interface for classes which perform pre or post processing
- *
- * @author Tolleiv Nietsch <typo3@tolleiv.de>
- * @package TYPO3
- * @subpackage t3lib
- */
-class tx_workspaces_pagetree_CollectionsProcessor implements t3lib_tree_pagetree_interfaces_CollectionProcessor {
-
- /**
- * @abstract
- * @param t3lib_tree_pagetree_Node $node
- * @param int $mountPoint
- * @param int $level
- * @param t3lib_tree_pagetree_NodeCollection $nodeCollection
- * @return void
- */
- public function postProcessGetNodes($node, $mountPoint, $level, $nodeCollection) {
- foreach($nodeCollection as $node) {
- /** @var $node t3lib_tree_Node */
- $this->highlightVersionizedElements($node);
- }
- }
-
- /**
- * @abstract
- * @param t3lib_tree_pagetree_Node $node
- * @param string $searchFilter
- * @param int $mountPoint
- * @param t3lib_tree_pagetree_NodeCollection $nodeCollection
- * @return void
- */
- public function postProcessFilteredNodes($node, $searchFilter, $mountPoint, $nodeCollection) {
- foreach($nodeCollection as $node) {
- /** @var $node t3lib_tree_Node */
- $this->highlightVersionizedElements($node);
- }
- }
-
- /**
- * @abstract
- * @param string $searchFilter
- * @param t3lib_tree_pagetree_NodeCollection $nodeCollection
- * @return void
- */
- public function postProcessGetTreeMounts($searchFilter, $nodeCollection) {
- foreach($nodeCollection as $node) {
- /** @var $node t3lib_tree_Node */
- $this->highlightVersionizedElements($node);
- }
- }
-
- /**
- * Sets the CSS Class on all pages which have versioned records
- * in the current workspace
- *
- * @param t3lib_tree_Node $node
- * @return void
- */
- protected function highlightVersionizedElements(t3lib_tree_Node $node) {
- if (!$node->getCls() && count(t3lib_BEfunc::countVersionsOfRecordsOnPage($GLOBALS['BE_USER']->workspace, $node->getId(), TRUE))) {
- $node->setCls('ver-versions');
- }
- }
-}
-
-?>
\ No newline at end of file
protected $stageService;
/**
- * @var tx_Workspaces_Service_Workspaces
+ * @var Tx_Workspaces_Service_Workspaces
*/
protected $workspaceService;
protected function initializeAction() {
parent::initializeAction();
$this->stageService = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
- $this->workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $this->workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$this->template->setExtDirectStateProvider();
$resourcePath = t3lib_extMgm::extRelPath('workspaces') . 'Resources/Public/StyleSheet/preview.css';
list(, $nextStage) = $this->stageService->getNextStageForElementCollection($workspaceItemsArray);
list(, $previousStage) = $this->stageService->getPreviousStageForElementCollection($workspaceItemsArray);
- /** @var $wsService tx_Workspaces_Service_Workspaces */
- $wsService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ /** @var $wsService Tx_Workspaces_Service_Workspaces */
+ $wsService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$wsList = $wsService->getAvailableWorkspaces();
$activeWorkspace = $GLOBALS['BE_USER']->workspace;
// @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)) {
+ if (Tx_Workspaces_Service_Workspaces::isNewPage($this->pageId)) {
$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);
* @return void
*/
public function indexAction() {
- $wsService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $wsService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$this->view->assign('showGrid', !($GLOBALS['BE_USER']->workspace === 0 && !$GLOBALS['BE_USER']->isAdmin()));
$this->view->assign('showAllWorkspaceTab', $GLOBALS['BE_USER']->isAdmin());
$this->view->assign('pageUid', t3lib_div::_GP('id'));
$GLOBALS['BE_USER']->setWorkspace($activeWorkspace);
$performWorkspaceSwitch = TRUE;
t3lib_BEfunc::setUpdateSignal('updatePageTree');
- } elseif ($switchWs == tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES) {
+ } elseif ($switchWs == Tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES) {
$this->redirect('fullIndex');
}
}
$this->view->assign('performWorkspaceSwitch', $performWorkspaceSwitch);
$this->view->assign('workspaceList', $wsList);
$this->view->assign('activeWorkspaceUid', $activeWorkspace);
- $this->view->assign('activeWorkspaceTitle', tx_Workspaces_Service_Workspaces::getWorkspaceTitle($activeWorkspace));
+ $this->view->assign('activeWorkspaceTitle', Tx_Workspaces_Service_Workspaces::getWorkspaceTitle($activeWorkspace));
$this->view->assign('showPreviewLink', $wsService->canCreatePreviewLink( t3lib_div::_GP('id'), $activeWorkspace));
$GLOBALS['BE_USER']->setAndSaveSessionData('tx_workspace_activeWorkspace', $activeWorkspace);
}
if (!$GLOBALS['BE_USER']->isAdmin()) {
$this->redirect('index');
} else {
- $wsService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $wsService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$this->view->assign('pageUid', t3lib_div::_GP('id'));
$this->view->assign('showGrid', TRUE);
$this->view->assign('showLegend', TRUE);
$this->view->assign('showAllWorkspaceTab', $GLOBALS['BE_USER']->isAdmin());
$this->view->assign('workspaceList', $wsService->getAvailableWorkspaces());
- $this->view->assign('activeWorkspaceUid', tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
+ $this->view->assign('activeWorkspaceUid', Tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
$this->view->assign('showPreviewLink', FALSE);
- $GLOBALS['BE_USER']->setAndSaveSessionData('tx_workspace_activeWorkspace', tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
+ $GLOBALS['BE_USER']->setAndSaveSessionData('tx_workspace_activeWorkspace', Tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
// set flag for javascript
$this->pageRenderer->addInlineSetting('Workspaces', 'allView', '1');
}
*/
public function singleIndexAction() {
- $wsService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $wsService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$wsList = $wsService->getAvailableWorkspaces();
$activeWorkspace = $GLOBALS['BE_USER']->workspace;
$this->template->setExtDirectStateProvider();
- if (tx_Workspaces_Service_Workspaces::isOldStyleWorkspaceUsed()) {
+ if (Tx_Workspaces_Service_Workspaces::isOldStyleWorkspaceUsed()) {
$message = t3lib_div::makeInstance(
't3lib_FlashMessage',
$GLOBALS['LANG']->sL('LLL:EXT:workspaces/Resources/Private/Language/locallang.xml:warning.oldStyleWorkspaceInUser'),
* @package Workspaces
* @subpackage ExtDirect
*/
-abstract class tx_Workspaces_ExtDirect_AbstractHandler {
+abstract class Tx_Workspaces_ExtDirect_AbstractHandler {
/**
* Gets the current workspace ID.
*
/**
* Gets an instance of the workspaces service.
*
- * @return tx_Workspaces_Service_Workspaces
+ * @return Tx_Workspaces_Service_Workspaces
*/
protected function getWorkspaceService() {
- return t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ return t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
}
}
* @package Workspaces
* @subpackage ExtDirect
*/
-class tx_Workspaces_ExtDirect_ActionHandler extends tx_Workspaces_ExtDirect_AbstractHandler {
+class Tx_Workspaces_ExtDirect_ActionHandler extends Tx_Workspaces_ExtDirect_AbstractHandler {
/**
* @var Tx_Workspaces_Service_Stages
* @return void
*/
public function viewSingleRecord($table, $uid) {
- return tx_Workspaces_Service_Workspaces::viewSingleRecord($table, $uid);
+ return Tx_Workspaces_Service_Workspaces::viewSingleRecord($table, $uid);
}
/**
*/
public function discardStagesFromPage($pageId) {
$cmdMapArray = array();
- /** @var $workspaceService tx_Workspaces_Service_Workspaces */
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ /** @var $workspaceService Tx_Workspaces_Service_Workspaces */
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
/** @var $stageService Tx_Workspaces_Service_Stages */
$stageService = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
$workspaceItemsArray = $workspaceService->selectVersionsInWorkspace($stageService->getWorkspaceId(), $filter = 1, $stage = -99, $pageId, $recursionLevel = 0, $selectionType = 'tables_modify');
* @author Michael Klapper <development@morphodo.com>
*/
public function sendPageToPreviousStage($id) {
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$workspaceItemsArray = $workspaceService->selectVersionsInWorkspace($this->stageService->getWorkspaceId(), $filter = 1, $stage = -99, $id, $recursionLevel = 0, $selectionType = 'tables_modify');
list($currentStage, $previousStage) = $this->getStageService()->getPreviousStageForElementCollection($workspaceItemsArray);
* @author Michael Klapper <development@morphodo.com>
*/
public function sendPageToNextStage($id) {
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$workspaceItemsArray = $workspaceService->selectVersionsInWorkspace($this->stageService->getWorkspaceId(), $filter = 1, $stage = -99, $id, $recursionLevel = 0, $selectionType = 'tables_modify');
list($currentStage, $nextStage) = $this->getStageService()->getNextStageForElementCollection($workspaceItemsArray);
// get only the relevant items for processing
public function updateStageChangeButtons($id) {
$stageService = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
// fetch the next and previous stage
$workspaceItemsArray = $workspaceService->selectVersionsInWorkspace($stageService->getWorkspaceId(), $filter = 1, $stage = -99, $id, $recursionLevel = 0, $selectionType = 'tables_modify');
* @package Workspaces
* @subpackage ExtDirect
*/
-class tx_Workspaces_ExtDirect_MassActionHandler extends tx_Workspaces_ExtDirect_AbstractHandler {
+class Tx_Workspaces_ExtDirect_MassActionHandler extends Tx_Workspaces_ExtDirect_AbstractHandler {
const MAX_RECORDS_TO_PROCESS = 30;
/**
$currentWorkspace = $this->getCurrentWorkspace();
// in case we're working within "All Workspaces" we can't provide Mass Actions
- if ($currentWorkspace != tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES) {
+ 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' => $GLOBALS['LANG']->sL($this->pathToLocallang . ':label_doaction_publish')
}
}
- if ($currentWorkspace !== tx_Workspaces_Service_Workspaces::LIVE_WORKSPACE_ID) {
+ if ($currentWorkspace !== Tx_Workspaces_Service_Workspaces::LIVE_WORKSPACE_ID) {
$actions[] = array('action' => 'discard', 'title' => $GLOBALS['LANG']->sL($this->pathToLocallang . ':label_doaction_discard')
);
}
* @return integer
*/
protected function initPublishData($workspace, $swap) {
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
// workspace might be -98 a.k.a "All Workspaces but that's save here
$publishData = $workspaceService->getCmdArrayForPublishWS($workspace, $swap);
$recordCount = 0;
* @return integer
*/
protected function initFlushData($workspace) {
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
// workspace might be -98 a.k.a "All Workspaces but that's save here
$flushData = $workspaceService->getCmdArrayForFlushWS($workspace);
$recordCount = 0;
--- /dev/null
+<?php
+/***************************************************************
+ * Copyright notice
+ *
+ * (c) 2011 Tolleiv Nietsch <typo3@tolleiv.de>
+ * All rights reserved
+ *
+ * This script is part of the TYPO3 project. The TYPO3 project is
+ * free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * The GNU General Public License can be found at
+ * http://www.gnu.org/copyleft/gpl.html.
+ * A copy is found in the textfile GPL.txt and important notices to the license
+ * from the author is found in LICENSE.txt distributed with these scripts.
+ *
+ *
+ * This script is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This copyright notice MUST APPEAR in all copies of the script!
+ ***************************************************************/
+
+/**
+ * Interface for classes which perform pre or post processing
+ *
+ * @author Tolleiv Nietsch <typo3@tolleiv.de>
+ * @package TYPO3
+ * @subpackage t3lib
+ */
+class Tx_Workspaces_ExtDirect_PagetreeCollectionsProcessor implements t3lib_tree_pagetree_interfaces_CollectionProcessor {
+
+ /**
+ * @abstract
+ * @param t3lib_tree_pagetree_Node $node
+ * @param int $mountPoint
+ * @param int $level
+ * @param t3lib_tree_pagetree_NodeCollection $nodeCollection
+ * @return void
+ */
+ public function postProcessGetNodes($node, $mountPoint, $level, $nodeCollection) {
+ foreach($nodeCollection as $node) {
+ /** @var $node t3lib_tree_Node */
+ $this->highlightVersionizedElements($node);
+ }
+ }
+
+ /**
+ * @abstract
+ * @param t3lib_tree_pagetree_Node $node
+ * @param string $searchFilter
+ * @param int $mountPoint
+ * @param t3lib_tree_pagetree_NodeCollection $nodeCollection
+ * @return void
+ */
+ public function postProcessFilteredNodes($node, $searchFilter, $mountPoint, $nodeCollection) {
+ foreach($nodeCollection as $node) {
+ /** @var $node t3lib_tree_Node */
+ $this->highlightVersionizedElements($node);
+ }
+ }
+
+ /**
+ * @abstract
+ * @param string $searchFilter
+ * @param t3lib_tree_pagetree_NodeCollection $nodeCollection
+ * @return void
+ */
+ public function postProcessGetTreeMounts($searchFilter, $nodeCollection) {
+ foreach($nodeCollection as $node) {
+ /** @var $node t3lib_tree_Node */
+ $this->highlightVersionizedElements($node);
+ }
+ }
+
+ /**
+ * Sets the CSS Class on all pages which have versioned records
+ * in the current workspace
+ *
+ * @param t3lib_tree_Node $node
+ * @return void
+ */
+ protected function highlightVersionizedElements(t3lib_tree_Node $node) {
+ if (!$node->getCls() && count(t3lib_BEfunc::countVersionsOfRecordsOnPage($GLOBALS['BE_USER']->workspace, $node->getId(), TRUE))) {
+ $node->setCls('ver-versions');
+ }
+ }
+}
+
+?>
\ No newline at end of file
* @package Workspaces
* @subpackage ExtDirect
*/
-class tx_Workspaces_ExtDirect_Server extends tx_Workspaces_ExtDirect_AbstractHandler {
+class Tx_Workspaces_ExtDirect_Server extends Tx_Workspaces_ExtDirect_AbstractHandler {
/**
* Get List of workspace changes
*
// To avoid too much work we use -1 to indicate that every page is relevant
$pageId = $parameter->id > 0 ? $parameter->id : -1;
- $wslibObj = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $wslibObj = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
$versions = $wslibObj->selectVersionsInWorkspace($this->getCurrentWorkspace(), 0, -99, $pageId, $parameter->depth);
- $workspacesService = t3lib_div::makeInstance('tx_Workspaces_Service_GridData');
+ $workspacesService = t3lib_div::makeInstance('Tx_Workspaces_Service_GridData');
$data = $workspacesService->generateGridListFromVersions($versions, $parameter, $this->getCurrentWorkspace());
return $data;
}
public function getStageActions($parameter) {
$currentWorkspace = $this->getCurrentWorkspace();
$stages = array();
- if ($currentWorkspace != tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES) {
+ if ($currentWorkspace != Tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES) {
$stagesService = t3lib_div::makeInstance('Tx_Workspaces_Service_Stages');
$stages = $stagesService->getStagesForWSUser();
}
* @package Workspaces
* @subpackage ExtDirect
*/
-class tx_Workspaces_ExtDirect_ToolbarMenu {
+class Tx_Workspaces_ExtDirect_ToolbarMenu {
/**
* @param $parameter
$GLOBALS['BE_USER']->setWorkspace($workspaceId);
return array(
- 'title' => tx_Workspaces_Service_Workspaces::getWorkspaceTitle($workspaceId),
+ 'title' => Tx_Workspaces_Service_Workspaces::getWorkspaceTitle($workspaceId),
'id' => $workspaceId
);
}
--- /dev/null
+<?php
+/***************************************************************
+* Copyright notice
+*
+* (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
+* free software; you can redistribute it and/or modify
+* it under the terms of the GNU General Public License as published by
+* the Free Software Foundation; either version 2 of the License, or
+* (at your option) any later version.
+*
+* The GNU General Public License can be found at
+* http://www.gnu.org/copyleft/gpl.html.
+* A copy is found in the textfile GPL.txt and important notices to the license
+* from the author is found in LICENSE.txt distributed with these scripts.
+*
+*
+* This script is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU General Public License for more details.
+*
+* This copyright notice MUST APPEAR in all copies of the script!
+***************************************************************/
+
+if(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_AJAX) {
+ require_once(PATH_typo3 . 'interfaces/interface.backend_toolbaritem.php');
+}
+
+/**
+ * class to render the workspace selector
+ *
+ * @author Ingo Renner <ingo@typo3.org>
+ * @package Workspaces
+ * @subpackage ExtDirect
+ */
+class Tx_Workspaces_ExtDirect_WorkspaceSelectorToolbarItem implements backend_toolbarItem {
+
+ protected $changeWorkspace;
+ protected $changeWorkspacePreview;
+
+ /**
+ * reference back to the backend object
+ *
+ * @var TYPO3backend
+ */
+ protected $backendReference;
+
+ protected $checkAccess = NULL;
+
+ /**
+ * constructor
+ *
+ * @param TYPO3backend TYPO3 backend object reference
+ */
+ public function __construct(TYPO3backend &$backendReference = NULL) {
+ $this->backendReference = $backendReference;
+ $this->changeWorkspace = t3lib_div::_GP('changeWorkspace');
+ $this->changeWorkspacePreview = t3lib_div::_GP('changeWorkspacePreview');
+
+ $pageRenderer = t3lib_div::makeInstance('t3lib_pageRenderer');
+ $this->backendReference->addJavaScript("TYPO3.Workspaces = { workspaceTitle : '" . htmlspecialchars(Tx_Workspaces_Service_Workspaces::getWorkspaceTitle($GLOBALS['BE_USER']->workspace)) . "'};\n");
+ }
+
+ /**
+ * checks whether the user has access to this toolbar item
+ *
+ * @see typo3/alt_shortcut.php
+ * @return boolean TRUE if user has access, FALSE if not
+ */
+ public function checkAccess() {
+ if (t3lib_extMgm::isLoaded('workspaces')) {
+ if ($this->checkAccess == NULL) {
+ $availableWorkspaces = Tx_Workspaces_Service_Workspaces::getAvailableWorkspaces();
+ if (count($availableWorkspaces) > 0) {
+ $this->checkAccess = TRUE;
+ } else {
+ $this->checkAccess = FALSE;
+ }
+ }
+ return $this->checkAccess;
+ }
+ return FALSE;
+ }
+
+ /**
+ * Creates the selector for workspaces
+ *
+ * @return string workspace selector as HTML select
+ */
+ public function render() {
+ $title = $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xml:toolbarItems.workspace', TRUE);
+ $this->addJavascriptToBackend();
+ $availableWorkspaces = Tx_Workspaces_Service_Workspaces::getAvailableWorkspaces();
+ $workspaceMenu = array();
+
+ $stateCheckedIcon = t3lib_iconWorks::getSpriteIcon('status-status-checked');
+
+ $stateUncheckedIcon = t3lib_iconWorks::getSpriteIcon('empty-empty', array(
+ 'title' => $GLOBALS['LANG']->getLL('bookmark_inactive')
+ ));
+
+ $workspaceMenu[] = '<a href="#" class="toolbar-item">' .
+ t3lib_iconWorks::getSpriteIcon('apps-toolbar-menu-workspace', array('title' => $title)) .
+ '</a>';
+ $workspaceMenu[] = '<ul class="toolbar-item-menu" style="display: none;">';
+
+ if (count($availableWorkspaces)) {
+ foreach($availableWorkspaces as $workspaceId => $label) {
+ $selected = '';
+ $icon = $stateUncheckedIcon;
+ if((int) $GLOBALS['BE_USER']->workspace === $workspaceId) {
+ $selected = ' class="selected"';
+ $icon = $stateCheckedIcon;
+ }
+
+ $workspaceMenu[] = '<li' . $selected . '>' . $icon .
+ ' <a href="backend.php?changeWorkspace=' .
+ intval($workspaceId) . '" id="ws-' . intval($workspaceId) .
+ '" class="ws">' . $label . '</a></li>';
+ }
+ } else {
+ $workspaceMenu[] = '<li>' . $stateUncheckedIcon . ' ' .
+ $GLOBALS['LANG']->getLL('bookmark_noWSfound', TRUE) .
+ '</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>';
+
+ return implode(LF, $workspaceMenu);
+ }
+
+ /**
+ * adds the necessary JavaScript to the backend
+ *
+ * @return void
+ */
+ protected function addJavascriptToBackend() {
+ $this->backendReference->addJavascriptFile(t3lib_extMgm::extRelPath('workspaces') . 'Resources/Public/JavaScript/workspacemenu.js');
+ }
+
+ /**
+ * returns additional attributes for the list item in the toolbar
+ *
+ * @return string list item HTML attibutes
+ */
+ public function getAdditionalAttributes() {
+ return ' id="workspace-selector-menu"';
+ }
+}
+
+
+if(!(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_AJAX)) {
+ $GLOBALS['TYPO3backend']->addToolbarItem('workSpaceSelector', 'Tx_Workspaces_ExtDirect_WorkspaceSelectorToolbarItem');
+}
+
+
+if (defined('TYPO3_MODE') && isset($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/ExtDirect/Tx_Workspaces_ExtDirect_WorkspaceSelectorToolbarItem.php'])) {
+ include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/workspaces/Classes/ExtDirect/Tx_Workspaces_ExtDirect_WorkspaceSelectorToolbarItem.php']);
+}
+?>
\ No newline at end of file
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_AutoPublish {
+class Tx_Workspaces_Service_AutoPublish {
/**
* This method is called by the Scheduler task that triggers
* the autopublication process
t3lib_BEfunc::deleteClause('sys_workspace')
);
- $workspaceService = t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ $workspaceService = t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
foreach ($workspaces as $rec) {
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_AutoPublishTask extends tx_scheduler_Task {
+class Tx_Workspaces_Service_AutoPublishTask extends tx_scheduler_Task {
/**
* Method executed from the Scheduler.
* @return void
*/
public function execute() {
- $autopubObj = t3lib_div::makeInstance('tx_Workspaces_Service_AutoPublish');
+ $autopubObj = t3lib_div::makeInstance('Tx_Workspaces_Service_AutoPublish');
// Publish the workspaces that need to be
$autopubObj->autoPublishWorkspaces();
// There's no feedback from the publishing process,
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_Befunc {
+class Tx_Workspaces_Service_Befunc {
/**
* Hooks into the t3lib_beFunc::viewOnClick and redirects to the workspace preview
* @throws InvalidArgumentException
* @param integer $uid
* @return integer
- * @deprecated since TYPO3 4.6 - use tx_Workspaces_Service_Workspaces::getLivePageUid() instead
+ * @deprecated since TYPO3 4.6 - use Tx_Workspaces_Service_Workspaces::getLivePageUid() instead
*/
protected function getLivePageUid($uid) {
- t3lib_div::deprecationLog(__METHOD__ . ' is deprected since TYPO3 4.6 - use tx_Workspaces_Service_Workspaces::getLivePageUid() instead');
+ t3lib_div::deprecationLog(__METHOD__ . ' is deprected since TYPO3 4.6 - use Tx_Workspaces_Service_Workspaces::getLivePageUid() instead');
return $this->getWorkspaceService()->getLivePageUid($uid);
}
/**
* Gets an instance of the workspaces service.
*
- * @return tx_Workspaces_Service_Workspaces
+ * @return Tx_Workspaces_Service_Workspaces
*/
protected function getWorkspaceService() {
- return t3lib_div::makeInstance('tx_Workspaces_Service_Workspaces');
+ return t3lib_div::makeInstance('Tx_Workspaces_Service_Workspaces');
}
/**
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_Fehooks {
+class Tx_Workspaces_Service_Fehooks {
/**
* @param tslib_fe $pObj
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_GridData {
+class Tx_Workspaces_Service_GridData {
protected $currentWorkspace = NULL;
protected $dataArray = array();
protected $sort = '';
$recordState = $this->workspaceState($versionRecord['t3ver_state']);
}
$isDeletedPage = ($table == 'pages' && $recordState == 'deleted');
- $viewUrl = tx_Workspaces_Service_Workspaces::viewSingleRecord($table, $record['t3ver_oid'], $origRecord);
+ $viewUrl = Tx_Workspaces_Service_Workspaces::viewSingleRecord($table, $record['t3ver_oid'], $origRecord);
$pctChange = $this->calculateChangePercentage($table, $origRecord, $versionRecord);
$versionArray['uid'] = $record['uid'];
$versionArray['change'] = $pctChange;
$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_Title'] = htmlspecialchars(Tx_Workspaces_Service_Workspaces::getWorkspaceTitle($versionRecord['t3ver_wsid']));
$versionArray['workspace_Tstamp'] = $versionRecord['tstamp'];
$versionArray['workspace_Formated_Tstamp'] = t3lib_BEfunc::datetime($versionRecord['tstamp']);
break;
}
} else {
- t3lib_div::sysLog('Try to sort "' . $this->sort . '" in "tx_Workspaces_Service_GridData::sortDataArray" but $this->dataArray is empty! This might be the Bug #26422 which could not reproduced yet.', 3);
+ t3lib_div::sysLog('Try to sort "' . $this->sort . '" in "Tx_Workspaces_Service_GridData::sortDataArray" but $this->dataArray is empty! This might be the Bug #26422 which could not reproduced yet.', 3);
}
}
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_Tcemain {
+class Tx_Workspaces_Service_Tcemain {
/**
* In case a sys_workspace_stage record is deleted we do a hard reset
if ($command === 'delete') {
if ($table === Tx_Workspaces_Service_Stages::TABLE_STAGE) {
$this->resetStageOfElements($id);
- } elseif ($table === tx_Workspaces_Service_Workspaces::TABLE_WORKSPACE) {
+ } elseif ($table === Tx_Workspaces_Service_Workspaces::TABLE_WORKSPACE) {
$this->flushWorkspaceElements($id);
}
}
protected function flushWorkspaceCacheEntriesByWorkspaceId($workspaceId) {
$workspacesCache = $GLOBALS['typo3CacheManager']->getCache('workspaces_cache');
$workspacesCache->flushByTag($workspaceId);
- $workspacesCache->flushByTag(tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
+ $workspacesCache->flushByTag(Tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES);
}
}
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_Workspaces implements t3lib_Singleton {
+class Tx_Workspaces_Service_Workspaces implements t3lib_Singleton {
/**
* @var array
*/
* @package Workspaces
* @subpackage Service
*/
-class tx_Workspaces_Service_WorkspacesTest extends tx_phpunit_database_testcase {
+class Tx_Workspaces_Service_WorkspacesTest extends tx_phpunit_database_testcase {
/**
* @test
public function emptyWorkspaceReturnsEmptyArray() {
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultWorkspaces.xml');
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
$result = $service->selectVersionsInWorkspace(90);
$this->assertTrue(empty($result), "The workspace 90 contains no changes and the result was supposed to be empty");
$this->assertTrue(is_array($result), "Even the empty result from workspace 90 is supposed to be an array");
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultWorkspaces.xml');
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultPages.xml');
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
$result = $service->selectVersionsInWorkspace(91, 0, -99, 2);
$this->assertTrue(is_array($result), "The result from workspace 91 is supposed to be an array");
$this->assertEquals(1, sizeof($result['pages']), "The result is supposed to contain one version for this page in workspace 91");
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultWorkspaces.xml');
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultPages.xml');
- $service = new tx_Workspaces_Service_Workspaces();
- $result = $service->selectVersionsInWorkspace(tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES, 0, -99, 2);
+ $service = new Tx_Workspaces_Service_Workspaces();
+ $result = $service->selectVersionsInWorkspace(Tx_Workspaces_Service_Workspaces::SELECT_ALL_WORKSPACES, 0, -99, 2);
$this->assertTrue(is_array($result), "The result from workspace 91 is supposed to be an array");
$this->assertEquals(2, sizeof($result['pages']), "The result is supposed to contain one version for this page in workspace 91");
}
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultWorkspaces.xml');
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultPages.xml');
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
$result = $service->selectVersionsInWorkspace(91, 0, -99, 1, 99);
$this->assertTrue(is_array($result), "The result from workspace 91 is supposed to be an array");
$this->assertEquals(4, sizeof($result['pages']), "The result is supposed to contain four versions for this page in workspace 91");
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultWorkspaces.xml');
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultPages.xml');
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
// testing stage 1
$result = $service->selectVersionsInWorkspace(91, 0, 1, 1, 99);
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultWorkspaces.xml');
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbDefaultPages.xml');
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
// testing all "draft" records
$result = $service->selectVersionsInWorkspace(91, 1, -99, 1, 99);
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbMovedContent.xml');
// Test if the placeholder can be found when we ask using recursion (same result)
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
$result = $service->selectVersionsInWorkspace(91, 0, -99, 2, 99);
$this->assertEquals(0, sizeof($result['pages']), "Changes should not show up in this branch of the tree within workspace 91");
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbMovedContent.xml');
// Test if the placeholder can be found when we ask using recursion (same result)
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
$result = $service->selectVersionsInWorkspace(91, 0, -99, 5, 99);
$this->assertEquals(1, sizeof($result['pages']), "Wrong amount of page versions found within workspace 91");
$this->assertEquals(103, $result['pages'][0]['uid'], "Wrong move-to pointer found for page 3 in workspace 91");
$this->importDataSet(dirname(__FILE__) . '/fixtures/dbMovedContent.xml');
// Test if the placeholder can be found when we ask using recursion (same result)
- $service = new tx_Workspaces_Service_Workspaces();
+ $service = new Tx_Workspaces_Service_Workspaces();
$result = $service->selectVersionsInWorkspace(91, 0, -99, 3, 99);
$this->assertEquals(1, sizeof($result), "Wrong amount of versions found within workspace 91");
die ('Access denied.');
}
if(TYPO3_MODE == 'BE') {
- $workspaceSelectorToolbarItemClassPath = t3lib_extMgm::extPath('workspaces', 'Classes/BackendUserInterface/WorkspaceSelectorToolbarItem.php');
+ $workspaceSelectorToolbarItemClassPath = t3lib_extMgm::extPath('workspaces', 'Classes/ExtDirect/WorkspaceSelectorToolbarItem.php');
$GLOBALS['TYPO3_CONF_VARS']['typo3/backend.php']['additionalBackendItems'][] = $workspaceSelectorToolbarItemClassPath;
}
// Register the autopublishing task
-$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['tasks']['tx_Workspaces_Service_AutoPublishTask'] = array(
+$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['tasks']['Tx_Workspaces_Service_AutoPublishTask'] = array(
'extension' => $_EXTKEY,
'title' => 'LLL:EXT:' . $_EXTKEY . '/Resources/Private/Language/locallang_mod.xml:autopublishTask.name',
'description' => 'LLL:EXT:' . $_EXTKEY . '/Resources/Private/Language/locallang_mod.xml:autopublishTask.description'
);
-$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processCmdmapClass']['workspaces'] = 'EXT:workspaces/Classes/Service/Tcemain.php:tx_Workspaces_Service_Tcemain';
-$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_befunc.php']['viewOnClickClass']['workspaces'] = 'EXT:workspaces/Classes/Service/Befunc.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';
-$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['typo3/alt_doc.php']['makeEditForm_accessCheck']['workspaces'] = 'EXT:workspaces/Classes/Service/Befunc.php:tx_Workspaces_Service_Befunc->makeEditForm_accessCheck';
+$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processCmdmapClass']['workspaces'] = 'EXT:workspaces/Classes/Service/Tcemain.php:Tx_Workspaces_Service_Tcemain';
+$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_befunc.php']['viewOnClickClass']['workspaces'] = 'EXT:workspaces/Classes/Service/Befunc.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';
+$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['typo3/alt_doc.php']['makeEditForm_accessCheck']['workspaces'] = 'EXT:workspaces/Classes/Service/Befunc.php:Tx_Workspaces_Service_Befunc->makeEditForm_accessCheck';
// Register workspaces cache if not already done in localconf.php or a previously loaded extension.
// We do not set frontend and backend: The cache manager uses t3lib_cache_frontend_VariableFrontend
t3lib_extMgm::addUserTSConfig('options.workspaces.considerReferences = 1');
-$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/tree/pagetree/class.t3lib_tree_pagetree_dataprovider.php']['postProcessCollections'][] = 'EXT:workspaces/Classes/BackendUserInterface/class.tx_workspaces_pagetree_collectionsprocessor.php:tx_workspaces_pagetree_collectionsprocessor';
+$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/tree/pagetree/class.t3lib_tree_pagetree_dataprovider.php']['postProcessCollections'][] = 'EXT:workspaces/Classes/ExtDirect/PagetreeCollectionsProcessor.php:Tx_Workspaces_ExtDirect_PagetreeCollectionsProcessor';
t3lib_extMgm::addUserTSConfig('options.workspaces.considerReferences = 1');
);
// register ExtDirect
- t3lib_extMgm::registerExtDirectComponent(
- 'TYPO3.Workspaces.ExtDirect',
- t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/Server.php:tx_Workspaces_ExtDirect_Server',
- 'web_WorkspacesWorkspaces',
- 'user,group'
- );
+ t3lib_extMgm::registerExtDirectComponent(
+ 'TYPO3.Workspaces.ExtDirect',
+ t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/Server.php:Tx_Workspaces_ExtDirect_Server',
+ 'web_WorkspacesWorkspaces',
+ 'user,group'
+ );
- t3lib_extMgm::registerExtDirectComponent(
- 'TYPO3.Workspaces.ExtDirectActions',
- t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/ActionHandler.php:tx_Workspaces_ExtDirect_ActionHandler',
- 'web_WorkspacesWorkspaces',
- 'user,group'
- );
+ t3lib_extMgm::registerExtDirectComponent(
+ 'TYPO3.Workspaces.ExtDirectActions',
+ t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/ActionHandler.php:Tx_Workspaces_ExtDirect_ActionHandler',
+ 'web_WorkspacesWorkspaces',
+ 'user,group'
+ );
- t3lib_extMgm::registerExtDirectComponent(
- 'TYPO3.Workspaces.ExtDirectMassActions',
- t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/MassActionHandler.php:tx_Workspaces_ExtDirect_MassActionHandler',
- 'web_WorkspacesWorkspaces',
- 'user,group'
- );
+ t3lib_extMgm::registerExtDirectComponent(
+ 'TYPO3.Workspaces.ExtDirectMassActions',
+ t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/MassActionHandler.php:Tx_Workspaces_ExtDirect_MassActionHandler',
+ 'web_WorkspacesWorkspaces',
+ 'user,group'
+ );
- t3lib_extMgm::registerExtDirectComponent(
- 'TYPO3.Ajax.ExtDirect.ToolbarMenu',
- t3lib_extMgm::extPath($_EXTKEY) . 'Classes/ExtDirect/ToolbarMenu.php:tx_Workspaces_ExtDirect_ToolbarMenu'
- );
+ t3lib_extMgm::registerExtDirectComponent(
+ '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';