WorkflowModelInterface

Interface for a workflow model.

since

4.0.0

Methods

executeTransition

Runs transition for item.

executeTransition(array $pks, integer $transitionId) : boolean
since

4.0.0

Arguments

$pks

arrayId of items to execute the transition

$transitionId

integerId of transition

Response

boolean

getName

Method to get the model name

getName() : string

The model name. By default parsed using the classname or it can be set by passing a $config['name'] in the class constructor

since

4.0.0

throws

\Exception

Response

stringThe name of the model

getState

Method to get state variables.

getState(string $property = null, mixed $default = null) : mixed
since

4.0.0

Arguments

$property

stringOptional parameter name

$default

mixedOptional default value

Response

mixedThe property where specified, the state object where omitted

getTable

Method to get a table object, load it if necessary.

getTable(string $name = '', string $prefix = '', array $options = array()) : \Joomla\CMS\Table\Table
since

3.0

throws

\Exception

Arguments

$name

stringThe table name. Optional.

$prefix

stringThe class prefix. Optional.

$options

arrayConfiguration array for model. Optional.

Response

\Joomla\CMS\Table\TableA Table object

setUpWorkflow

Set Up the workflow

setUpWorkflow(string $extension) : void
since

4.0.0

Arguments

$extension

stringThe option and section separated by.

workflowAfterSave

Executing of relevant workflow methods

workflowAfterSave( $data) : void
since

4.0.0

Arguments

$data

workflowBeforeSave

Preparation of workflow data/plugins

workflowBeforeSave() : void
since

4.0.0

workflowBeforeStageChange

Let plugins access stage change events

workflowBeforeStageChange() : void
since

4.0.0

workflowCleanupBatchMove

Batch change workflow stage or current.

workflowCleanupBatchMove(integer $oldId, integer $newId) : null
since

4.0.0

Arguments

$oldId

integerThe ID of the item copied from

$newId

integerThe ID of the new item

Response

null

workflowPreprocessForm

Method to allow derived classes to preprocess the form.

workflowPreprocessForm(\Joomla\CMS\Form\Form $form, mixed $data) : void
see \Joomla\CMS\MVC\Model\FormField
since

4.0.0

throws

\Exceptionif there is an error in the form event.

Arguments

$form

\Joomla\CMS\Form\FormA Form object.

$data

mixedThe data expected for the form.