ClonerOptions
class ClonerOptions (View source)
A class representing the options for the page/collection/version Cloner.
Properties
protected User | $currentUser | The currently logged in user. |
|
private bool | $keepOriginalAuthor | Should the original author be kept? |
|
private bool | $forceUnapproved | Mark the copied data as not approved? |
|
private bool | $copyAttributes | Should the collection version attributes be copied? |
|
private bool | $copyPageTypeComposerOutputBlocks | Should the page type composer output block records be copied? |
|
private bool | $copyCustomStyles | Should the custom theme styles be copied? |
|
private bool | $copyContents | Should the collection version contents (blocks/areas/...) be copied? |
|
private string | $versionComments | The version comments (if empty string, automatically build them). |
Methods
Get the currently logged in user.
Should the original author be kept?
Should the original author be kept?
Mark the copied data as not approved?
Mark the copied data as not approved?
Should the collection version attributes be copied?
Should the collection version attributes be copied?
Should the page type composer output block records be copied?
Should the page type composer output block records be copied?
Should the custom theme styles be copied?
Should the custom theme styles be copied?
Should the collection version contents (blocks/areas/...) be copied?
Should the collection version contents (blocks/areas/...) be copied?
Get the version comments (if empty string, automatically build it).
Set the version comments (if empty string, automatically build it).
Details
__construct(User $currentUser)
Initialize the instance.
User
getCurrentUser()
Get the currently logged in user.
bool
keepOriginalAuthor()
Should the original author be kept?
$this
setKeepOriginalAuthor(bool $value)
Should the original author be kept?
bool
forceUnapproved()
Mark the copied data as not approved?
$this
setForceUnapproved(bool $value)
Mark the copied data as not approved?
bool
copyAttributes()
Should the collection version attributes be copied?
$this
setCopyAttributes(bool $value)
Should the collection version attributes be copied?
bool
copyPageTypeComposerOutputBlocks()
Should the page type composer output block records be copied?
setCopyPageTypeComposerOutputBlocks(bool $copyPageTypeComposerOutputBlocks)
Should the page type composer output block records be copied?
bool
copyCustomStyles()
Should the custom theme styles be copied?
$this
setCopyCustomStyles(bool $value)
Should the custom theme styles be copied?
bool
copyContents()
Should the collection version contents (blocks/areas/...) be copied?
$this
setCopyContents(bool $value)
Should the collection version contents (blocks/areas/...) be copied?
getVersionComments()
Get the version comments (if empty string, automatically build it).
$this
setVersionComments(string|object $value)
Set the version comments (if empty string, automatically build it).