Class JModelAdmin

Description

Prototype admin model.

  • abstract:
  • since: 11.1

Located in /libraries/joomla/application/component/modeladmin.php (line 21)

JObject
   |
   --JModel
      |
      --JModelForm
         |
         --JModelAdmin
Direct descendents
Class Description
ModulesModelModule Module model.
MessagesModelMessage Private Message model.
UsersModelUser User model.
UsersModelNote User note model.
UsersModelGroup User group model.
UsersModelLevel User view level model.
UsersModelMail Users mail model.
NewsfeedsModelNewsfeed Newsfeed model.
LanguagesModelLanguage Languages Component Language Model
LanguagesModelOverride Languages Override Model
WeblinksModelWeblink Weblinks model.
PluginsModelPlugin Plugin model.
CategoriesModelCategory Categories Component Category Model
RedirectModelLink Redirect link model.
TemplatesModelStyle Template style model.
FinderModelFilter Filter model class for Finder.
ContactModelContact Item Model for a Contact.
ContentModelArticle Item Model for an Article.
MenusModelItem Menu Item Model for Menus.
BannersModelClient Client model.
BannersModelBanner Banner model.
Variable Summary
Method Summary
JModelAdmin __construct ([array $config = array()])
boolean batch (array $commands, array $pks, array $contexts)
boolean batchAccess (integer $value, array $pks, array $contexts)
mixed batchCopy (integer $value, array $pks, array $contexts)
boolean batchLanguage (string $value, array $pks, array $contexts)
boolean batchMove (integer $value, array $pks, array $contexts)
boolean canDelete (object $record)
boolean canEditState (object $record)
mixed checkin ([mixed $pks = array()])
boolean checkout ([integer $pk = null])
boolean delete (array &$pks)
array generateNewTitle (integer $category_id, string $alias, string $title)
mixed getItem ([integer $pk = null])
array getReorderConditions (JTable $table)
void populateState ()
void prepareTable (JTable &$table)
boolean publish (array &$pks, [integer $value = 1])
mixed reorder (integer $pks, [integer $delta = 0])
boolean save (array $data)
mixed saveorder ([array $pks = null], [integer $order = null])
Variables
string $event_after_delete = null (line 37)

The event to trigger after deleting the data.

  • since: 11.1
  • access: protected
string $event_after_save = null (line 45)

The event to trigger after saving the data.

  • since: 11.1
  • access: protected

Redefined in descendants as:
string $event_before_delete = null (line 53)

The event to trigger before deleting the data.

  • since: 11.1
  • access: protected
string $event_before_save = null (line 61)

The event to trigger before saving the data.

  • since: 11.1
  • access: protected

Redefined in descendants as:
string $event_change_state = null (line 69)

The event to trigger after changing the published state of the data.

  • since: 11.1
  • access: protected
string $text_prefix = null (line 29)

The prefix to use with controller messages.

  • since: 11.1
  • access: protected

Redefined in descendants as:

Inherited Variables

Inherited from JModelForm

JModelForm::$_forms

Inherited from JModel

JModel::$event_clean_cache
JModel::$name
JModel::$option
JModel::$state
JModel::$_db
JModel::$__state_set

Inherited from JObject

JObject::$_errors
Methods
Constructor __construct (line 79)

Constructor.

JModelAdmin __construct ([array $config = array()])
  • array $config: An optional associative array of configuration settings.

Redefinition of:
JModel::__construct()
Constructor
batch (line 150)

Method to perform batch operations on an item or a set of items.

  • return: Returns true on success, false on failure.
  • since: 11.1
  • access: public
boolean batch (array $commands, array $pks, array $contexts)
  • array $commands: An array of commands to perform.
  • array $pks: An array of item ids.
  • array $contexts: An array of item contexts.

Redefined in descendants as:
batchAccess (line 236)

Batch access level changes for a group of rows.

  • return: True if successful, false otherwise and internal error is set.
  • since: 11.1
  • access: protected
boolean batchAccess (integer $value, array $pks, array $contexts)
  • integer $value: The new value matching an Asset Group ID.
  • array $pks: An array of row IDs.
  • array $contexts: An array of item contexts.
batchCopy (line 280)

Batch copy items to a new category or current.

  • return: An array of new IDs on success, boolean false on failure.
  • since: 11.1
  • access: protected
mixed batchCopy (integer $value, array $pks, array $contexts)
  • integer $value: The new category.
  • array $pks: An array of row IDs.
  • array $contexts: An array of item contexts.

Redefined in descendants as:
batchLanguage (line 400)

Batch language changes for a group of rows.

  • return: True if successful, false otherwise and internal error is set.
  • since: 11.3
  • access: protected
boolean batchLanguage (string $value, array $pks, array $contexts)
  • string $value: The new value matching a language.
  • array $pks: An array of row IDs.
  • array $contexts: An array of item contexts.
batchMove (line 444)

Batch move items to a new category

  • return: True if successful, false otherwise and internal error is set.
  • since: 11.1
  • access: protected
boolean batchMove (integer $value, array $pks, array $contexts)
  • integer $value: The new category ID.
  • array $pks: An array of row IDs.
  • array $contexts: An array of item contexts.

Redefined in descendants as:
canDelete (line 544)

Method to test whether a record can be deleted.

  • return: True if allowed to delete the record. Defaults to the permission for the component.
  • since: 11.1
  • access: protected
boolean canDelete (object $record)
  • object $record: A record object.

Redefined in descendants as:
canEditState (line 559)

Method to test whether a record can be deleted.

  • return: True if allowed to change the state of the record. Defaults to the permission for the component.
  • since: 11.1
  • access: protected
boolean canEditState (object $record)
  • object $record: A record object.

Redefined in descendants as:
checkin (line 574)

Method override to check-in a record or an array of record

  • return: Boolean false if there is an error, otherwise the count of records checked in.
  • since: 11.1
  • access: public
mixed checkin ([mixed $pks = array()])
  • mixed $pks: The ID of the primary key or an array of IDs

Redefinition of:
JModelForm::checkin()
Method to checkin a row.
checkout (line 621)

Method override to check-out a record.

  • return: True if successful, false if an error occurs.
  • since: 11.1
  • access: public
boolean checkout ([integer $pk = null])
  • integer $pk: The ID of the primary key.

Redefinition of:
JModelForm::checkout()
Method to check-out a row for editing.
delete (line 638)

Method to delete one or more records.

  • return: True if successful, false if an error occurs.
  • since: 11.1
  • access: public
boolean delete (array &$pks)
  • array &$pks: An array of record primary keys.

Redefined in descendants as:
generateNewTitle (line 721)

Method to change the title & alias.

  • return: Contains the modified title and alias.
  • since: 11.1
  • access: protected
array generateNewTitle (integer $category_id, string $alias, string $title)
  • integer $category_id: The id of the category.
  • string $alias: The alias.
  • string $title: The title.

Redefined in descendants as:
getItem (line 743)

Method to get a single record.

  • return: Object on success, false on failure.
  • since: 11.1
  • access: public
mixed getItem ([integer $pk = null])
  • integer $pk: The id of the primary key.

Redefined in descendants as:
getReorderConditions (line 785)

A protected method to get a set of ordering conditions.

  • return: An array of conditions to add to ordering queries.
  • since: 11.1
  • access: protected
array getReorderConditions (JTable $table)
  • JTable $table: A JTable object.

Redefined in descendants as:
populateState (line 797)

Stock method to auto-populate the model state.

  • since: 11.1
  • access: protected
void populateState ()

Redefinition of:
JModel::populateState()
Method to auto-populate the model state.

Redefined in descendants as:
prepareTable (line 821)

Prepare and sanitise the table data prior to saving.

  • since: 11.1
  • access: protected
void prepareTable (JTable &$table)
  • JTable &$table: A reference to a JTable object.

Redefined in descendants as:
publish (line 836)

Method to change the published state of one or more records.

  • return: True on success.
  • since: 11.1
  • access: public
boolean publish (array &$pks, [integer $value = 1])
  • array &$pks: A list of the primary keys to change.
  • integer $value: The value of the published state.

Redefined in descendants as:
reorder (line 901)

Method to adjust the ordering of a row.

Returns NULL if the user did not have edit privileges for any of the selected primary keys.

  • return: False on failure or error, true on success, null if the $pk is empty (no items selected).
  • since: 11.1
  • access: public
mixed reorder (integer $pks, [integer $delta = 0])
  • integer $pks: The ID of the primary key to move.
  • integer $delta: Increment, usually +1 or -1
save (line 970)

Method to save the form data.

  • return: True on success, False on error.
  • since: 11.1
  • access: public
boolean save (array $data)
  • array $data: The form data.

Redefined in descendants as:
saveorder (line 1058)

Saves the manually set order of records.

  • since: 11.1
  • access: public
mixed saveorder ([array $pks = null], [integer $order = null])
  • array $pks: An array of primary key ids.
  • integer $order: +1 or -1

Redefined in descendants as:

Inherited Methods

Inherited From JModelForm

JModelForm::checkin()
JModelForm::checkout()
JModelForm::getForm()
JModelForm::loadForm()
JModelForm::loadFormData()
JModelForm::preprocessForm()
JModelForm::validate()

Inherited From JModel

JModel::__construct()
JModel::addIncludePath()
JModel::addTablePath()
JModel::cleanCache()
JModel::getDbo()
JModel::getInstance()
JModel::getName()
JModel::getState()
JModel::getTable()
JModel::populateState()
JModel::setDbo()
JModel::setState()
JModel::_createFileName()
JModel::_createTable()
JModel::_getList()
JModel::_getListCount()

Inherited From JObject

JObject::__construct()
JObject::def()
JObject::get()
JObject::getError()
JObject::getErrors()
JObject::getProperties()
JObject::set()
JObject::setError()
JObject::setProperties()
JObject::toString()
JObject::__toString()

Documentation generated on Mon, 25 Jun 2012 13:57:27 -0500 by phpDocumentor 1.4.4