eZPublish  4.6
copysubtree.php File Reference

Namespaces

 kernel
 Autoloader definition for eZ Publish Kernel files.
 

Functions

 browse ($Module, $srcNode)
 
 chooseOptionsToCopy ($Module, &$Result, $srcNode, $chooseVersions, $chooseCreator, $chooseTime)
 
if($Module->isCurrentAction(
'Cancel')) 
copyPublishContentObject ($sourceObject, $sourceSubtreeNodeIDList, &$syncNodeIDListSrc, &$syncNodeIDListNew, &$syncObjectIDListSrc, &$syncObjectIDListNew, $objectIDBlackList, &$nodeIDBlackList, &$notifications, $allVersions=false, $keepCreator=false, $keepTime=false)
 
 copySubtree ($srcNodeID, $dstNodeID, &$notifications, $allVersions, $keepCreator, $keepTime)
 
 showNotificationAfterCopying ($http, $Module, &$Result, &$Notifications, $srcNode)
 

Variables

else $allVersions = ( $versionHandling == 'last-published' ) ? false : true
 
 $chooseCreator = ( $creatorHandling == 'user-defined' )
 
 $chooseTime = ( $timeHandling == 'user-defined' )
 
 $chooseVersions = ( $versionHandling == 'user-defined' )
 
 $contentINI = eZINI::instance( 'content.ini' )
 
 $creatorHandling = $contentINI->variable( 'CopySettings', 'CreatorHandling' )
 
 $http = eZHTTPTool::instance()
 
else $keepCreator = ( $creatorHandling == 'keep-unchanged' )
 
else $keepTime = ( $timeHandling == 'keep-unchanged' )
 
 $maxNodesCopySubtree = $contentINI->variable( 'CopySettings', 'MaxNodesCopySubtree' )
 
 $Module = $Params['Module']
 
 $NodeID = $Params['NodeID']
 
 $notifications
 
 $Result = array()
 
 $showCopySubtreeNotification = $contentINI->variable( 'CopySettings', 'ShowCopySubtreeNotification' )
 
 $showNotification = ( $showCopySubtreeNotification == 'enabled' )
 
if($http->hasPostVariable(
'BrowseCancelButton')) if($NodeID===null) 
$srcNode = eZContentObjectTreeNode::fetch( $NodeID )
 
 $srcSubtreeNodesCount = $srcNode->subTreeCount()
 
 $timeHandling = $contentINI->variable( 'CopySettings', 'TimeHandling' )
 
if($srcSubtreeNodesCount >
$maxNodesCopySubtree) 
$versionHandling = $contentINI->variable( 'CopySettings', 'VersionHandling' )
 
if($Module->isCurrentAction(
'Copy')) else if($Module->
isCurrentAction( 'CopySubtree')) 
else
 

Function Documentation

browse (   $Module,
  $srcNode 
)

Browse for node to place the object copy into

chooseOptionsToCopy (   $Module,
$Result,
  $srcNode,
  $chooseVersions,
  $chooseCreator,
  $chooseTime 
)

Redirect to the page that lets a user to choose which versions to copy: either all version or the current one.

if ($Module->isCurrentAction( 'Cancel')) copyPublishContentObject (   $sourceObject,
  $sourceSubtreeNodeIDList,
$syncNodeIDListSrc,
$syncNodeIDListNew,
$syncObjectIDListSrc,
$syncObjectIDListNew,
  $objectIDBlackList,
$nodeIDBlackList,
$notifications,
  $allVersions = false,
  $keepCreator = false,
  $keepTime = false 
) -> handleError( eZError::KERNEL_ACCESS_DENIED, 'kernel' )
copySubtree (   $srcNodeID,
  $dstNodeID,
$notifications,
  $allVersions,
  $keepCreator,
  $keepTime 
)
showNotificationAfterCopying (   $http,
  $Module,
$Result,
$Notifications,
  $srcNode 
)

Variable Documentation

else $allVersions = ( $versionHandling == 'last-published' ) ? false : true
$chooseCreator = ( $creatorHandling == 'user-defined' )

Referenced by chooseOptionsToCopy().

$chooseTime = ( $timeHandling == 'user-defined' )

Referenced by chooseOptionsToCopy().

$chooseVersions = ( $versionHandling == 'user-defined' )
$contentINI = eZINI::instance( 'content.ini' )
$creatorHandling = $contentINI->variable( 'CopySettings', 'CreatorHandling' )
$keepCreator = ( $creatorHandling == 'keep-unchanged' )
$keepTime = ( $timeHandling == 'keep-unchanged' )
$maxNodesCopySubtree = $contentINI->variable( 'CopySettings', 'MaxNodesCopySubtree' )
$Module = $Params['Module']
$NodeID = $Params['NodeID']
$notifications
Initial value:
= array( 'Notifications' => array(),
'Warnings' => array(),
'Errors' => array(),
'Result' => false )

Referenced by copyPublishContentObject(), and copySubtree().

$Result = array()
$showCopySubtreeNotification = $contentINI->variable( 'CopySettings', 'ShowCopySubtreeNotification' )
$showNotification = ( $showCopySubtreeNotification == 'enabled' )
if ($http->hasPostVariable( 'BrowseCancelButton')) if ($NodeID===null) $srcNode = eZContentObjectTreeNode::fetch( $NodeID )
$srcSubtreeNodesCount = $srcNode->subTreeCount()
$timeHandling = $contentINI->variable( 'CopySettings', 'TimeHandling' )
if ($srcSubtreeNodesCount > $maxNodesCopySubtree) $versionHandling = $contentINI->variable( 'CopySettings', 'VersionHandling' )
if ($Module->isCurrentAction( 'Copy')) else if ($Module->isCurrentAction( 'CopySubtree')) else
Initial value:
{
browse($Module, $object)
Definition: content/copy.php:109
$Module
Definition: classlist.php:9
if($http->hasPostVariable( 'BrowseCancelButton')) if($NodeID===null) $srcNode
Definition: copysubtree.php:25