TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Version\Utility\WorkspacesUtility Class Reference
Inheritance diagram for TYPO3\CMS\Version\Utility\WorkspacesUtility:
wslib

Public Member Functions

 getCmdArrayForPublishWS ($wsid, $doSwap, $pageId=0)
 
 selectVersionsInWorkspace ($wsid, $filter=0, $stage=-99, $pageId=-1)
 
 autoPublishWorkspaces ()
 

Detailed Description

Library with Workspace related functionality

Author
Kasper Skårhøj kaspe.nosp@m.rYYY.nosp@m.Y@typ.nosp@m.o3.c.nosp@m.om

Definition at line 24 of file WorkspacesUtility.php.

Member Function Documentation

◆ autoPublishWorkspaces()

TYPO3\CMS\Version\Utility\WorkspacesUtility::autoPublishWorkspaces ( )

This method is called by the Scheduler task that triggers the autopublication process It searches for workspaces whose publication date is in the past and publishes them

Returns
void
Todo:
Define visibility

Definition at line 109 of file WorkspacesUtility.php.

References $GLOBALS, TYPO3\CMS\Backend\Utility\BackendUtility\deleteClause(), TYPO3\CMS\Version\Utility\WorkspacesUtility\getCmdArrayForPublishWS(), and TYPO3\CMS\Core\Utility\GeneralUtility\makeInstance().

◆ getCmdArrayForPublishWS()

TYPO3\CMS\Version\Utility\WorkspacesUtility::getCmdArrayForPublishWS (   $wsid,
  $doSwap,
  $pageId = 0 
)

Building tcemain CMD-array for swapping all versions in a workspace.

Parameters
integer$wsidReal workspace ID, cannot be ONLINE (zero).
boolean$doSwapIf set, then the currently online versions are swapped into the workspace in exchange for the offline versions. Otherwise the workspace is emptied.
int$pageId
Returns
array Command array for tcemain
Todo:
Define visibility

Definition at line 35 of file WorkspacesUtility.php.

References TYPO3\CMS\Version\Utility\WorkspacesUtility\selectVersionsInWorkspace().

Referenced by TYPO3\CMS\Version\Utility\WorkspacesUtility\autoPublishWorkspaces().

◆ selectVersionsInWorkspace()

TYPO3\CMS\Version\Utility\WorkspacesUtility::selectVersionsInWorkspace (   $wsid,
  $filter = 0,
  $stage = -99,
  $pageId = -1 
)

Select all records from workspace pending for publishing Used from backend to display workspace overview User for auto-publishing for selecting versions for publication

Parameters
integer$wsidWorkspace ID. If -99, will select ALL versions from ANY workspace. If -98 will select all but ONLINE. >=-1 will select from the actual workspace
integer$filterLifecycle filter: 1 = select all drafts (never-published), 2 = select all published one or more times (archive/multiple), anything else selects all.
integer$stageStage filter: -99 means no filtering, otherwise it will be used to select only elements with that stage. For publishing, that would be "10
integer$pageIdPage id: Live page for which to find versions in workspace!
Returns
array Array of all records uids etc. First key is table name, second key incremental integer. Records are associative arrays with uid and t3ver_oid fields. The REAL pid of the online record is found as "realpid
Todo:
Define visibility

Definition at line 76 of file WorkspacesUtility.php.

References $GLOBALS, and TYPO3\CMS\Backend\Utility\BackendUtility\deleteClause().

Referenced by TYPO3\CMS\Version\Utility\WorkspacesUtility\getCmdArrayForPublishWS().