Class BannersModelBanner

Description

Banner model.

  • since: 1.6

Located in /administrator/components/com_banners/models/banner.php (line 19)

JObject
   |
   --JModelLegacy
      |
      --JModelForm
         |
         --JModelAdmin
            |
            --BannersModelBanner
Variable Summary
 string $text_prefix
 string $typeAlias
Method Summary
 boolean batch (array $commands, array $pks, array $contexts)
 boolean batchClient (string $value, array $pks, array $contexts)
 mixed batchCopy (integer $value, array $pks, array $contexts)
 boolean canDelete (object $record)
 boolean canEditState (object $record)
 mixed getForm ([array $data = array()], [boolean $loadData = true])
 array getReorderConditions (JTable $table)
 JTable getTable ([string $type = 'Banner'], [string $prefix = 'BannersTable'], [array $config = array()])
 mixed loadFormData ()
 void prepareTable ( $table)
 boolean save (array $data)
 boolean stick (array &$pks, [integer $value = 1])
Variables
string $text_prefix = 'COM_BANNERS_BANNER' (line 25)
  • var: The prefix to use with controller messages.
  • since: 1.6
  • access: protected

Redefinition of:
JModelAdmin::$text_prefix
The prefix to use with controller messages.
string $typeAlias = 'com_banners.banner' (line 33)

The type alias for this content type.

  • since: 3.2
  • access: public

Inherited Variables

Inherited from JModelAdmin

JModelAdmin::$event_after_delete
JModelAdmin::$event_after_save
JModelAdmin::$event_before_delete
JModelAdmin::$event_before_save
JModelAdmin::$event_change_state

Inherited from JModelForm

JModelForm::$_forms

Inherited from JModelLegacy

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

Inherited from JObject

JObject::$_errors
Methods
batch (line 46)

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

  • return: Returns true on success, false on failure.
  • since: 2.5
  • 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.

Redefinition of:
JModelAdmin::batch()
Method to perform batch operations on an item or a set of items.
batchClient (line 132)

Batch client changes for a group of banners.

  • return: True if successful, false otherwise and internal error is set.
  • since: 2.5
  • access: protected
boolean batchClient (string $value, array $pks, array $contexts)
  • string $value: The new value matching a client.
  • array $pks: An array of row IDs.
  • array $contexts: An array of item contexts.
batchCopy (line 176)

Batch copy items to a new category or current.

  • return: An array of new IDs on success, boolean false on failure.
  • since: 2.5
  • 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.

Redefinition of:
JModelAdmin::batchCopy()
Batch copy items to a new category or current.
canDelete (line 293)

Method to test whether a record can be deleted.

  • return: True if allowed to delete the record. Defaults to the permission set in the component.
  • since: 1.6
  • access: protected
boolean canDelete (object $record)
  • object $record: A record object.
canEditState (line 323)

Method to test whether a record can have its state changed.

  • return: True if allowed to change the state of the record. Defaults to the permission set in the component.
  • since: 1.6
  • access: protected
boolean canEditState (object $record)
  • object $record: A record object.
getForm (line 365)

Method to get the record form.

  • return: A JForm object on success, false on failure
  • since: 1.6
  • access: public
mixed getForm ([array $data = array()], [boolean $loadData = true])
  • array $data: Data for the form. [optional]
  • boolean $loadData: True if the form is to load its own data (default case), false if not. [optional]

Redefinition of:
JModelForm::getForm()
Abstract method for getting the form from the model.
getReorderConditions (line 486)

A protected method to get a set of ordering conditions.

  • return: An array of conditions to add to add to ordering queries.
  • since: 1.6
  • access: protected
array getReorderConditions (JTable $table)
  • JTable $table: A record object.
getTable (line 350)

Returns a JTable object, always creating it.

  • return: A database object
  • since: 1.6
  • access: public
JTable getTable ([string $type = 'Banner'], [string $prefix = 'BannersTable'], [array $config = array()])
  • string $type: The table type to instantiate. [optional]
  • string $prefix: A prefix for the table class name. [optional]
  • array $config: Configuration array for model. [optional]

Redefinition of:
JModelLegacy::getTable()
Method to get a table object, load it if necessary.
loadFormData (line 415)

Method to get the data that should be injected in the form.

  • return: The data for the form.
  • since: 1.6
  • access: protected
mixed loadFormData ()

Redefinition of:
JModelForm::loadFormData()
Method to get the data that should be injected in the form.
prepareTable (line 497)
  • since: 3.0
  • access: protected
void prepareTable ( $table)
  • $table
save (line 540)

Method to save the form data.

  • return: True on success.
  • since: 1.6
  • access: public
boolean save (array $data)
  • array $data: The form data.
stick (line 447)

Method to stick records.

  • return: True on success.
  • since: 1.6
  • access: public
boolean stick (array &$pks, [integer $value = 1])
  • array &$pks: The ids of the items to publish.
  • integer $value: The value of the published state

Inherited Methods

Inherited From JModelAdmin

 JModelAdmin::__construct()
 JModelAdmin::batch()
 JModelAdmin::batchAccess()
 JModelAdmin::batchCopy()

Inherited From JModelForm

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

Inherited From JModelLegacy

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

Inherited From JObject

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

Documentation generated on Tue, 19 Nov 2013 14:54:14 +0100 by phpDocumentor 1.4.3