[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/administrator/components/com_workflow/src/Model/ -> WorkflowModel.php (summary)

(no description)

Copyright: (C) 2018 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
File Size: 398 lines (12 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

WorkflowModel:: (11 methods):
  populateState()
  generateNewTitle()
  save()
  getForm()
  loadFormData()
  preprocessForm()
  getReorderConditions()
  setDefault()
  canDelete()
  canEditState()
  publish()


Class: WorkflowModel  - X-Ref

Model class for workflow

populateState()   X-Ref
Auto-populate the model state.

Note. Calling getState in this method will result in recursion.

return: void

generateNewTitle($categoryId, $alias, $title)   X-Ref
Method to change the title

param: integer  $categoryId  The id of the category.
param: string   $alias       The alias.
param: string   $title       The title.
return: array  Contains the modified title and alias.

save($data)   X-Ref
Method to save the form data.

param: array  $data  The form data.
return: boolean True on success.

getForm($data = array()   X-Ref
Abstract method for getting the form from the model.

param: array    $data      Data for the form.
param: boolean  $loadData  True if the form is to load its own data (default case), false if not.
return: \Joomla\CMS\Form\Form|boolean A Form object on success, false on failure

loadFormData()   X-Ref
Method to get the data that should be injected in the form.

return: mixed  The data for the form.

preprocessForm(Form $form, $data, $group = 'content')   X-Ref
Method to preprocess the form.

param: Form    $form   Form object.
param: mixed   $data   The data expected for the form.
param: string  $group  The name of the plugin group to import (defaults to "content").
return: void

getReorderConditions($table)   X-Ref
A protected method to get a set of ordering conditions.

param: object  $table  A record object.
return: array  An array of conditions to add to ordering queries.

setDefault($pk, $value = 1)   X-Ref
Method to change the default state of one item.

param: array    $pk     A list of the primary keys to change.
param: integer  $value  The value of the home state.
return: boolean  True on success.

canDelete($record)   X-Ref
Method to test whether a record can be deleted.

param: object  $record  A record object.
return: boolean  True if allowed to delete the record. Defaults to the permission for the component.

canEditState($record)   X-Ref
Method to test whether a record can have its state changed.

param: object  $record  A record object.
return: boolean  True if allowed to change the state of the record. Defaults to the permission set in the component.

publish(&$pks, $value = 1)   X-Ref
Method to change the published state of one or more records.

param: array    &$pks   A list of the primary keys to change.
param: integer  $value  The value of the published state.
return: boolean  True on success.



Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer