Amiro.CMS API Reference
Amiro.Ru / Manual
Loading search...

The AMI_Module_TableItem class

AMI_ModTableItem
   |
   --AMI_Module_TableItem

• Introduction

Common module table item model.

• Class synopsis

AMI_Module_TableItem extends AMI_ModTableItem {
/* Properties */
// Common fields validators
protected array $aCommonFieldsValidators = array( 'lang' => array('filled'),'header'=>array('filled','stop_on_error'),'announce'=>array('filled','stop_on_error'),'date_created'=>array('filled','stop_on_error'),'body'=>array('required'));
/* Inherited Properties */
// Element data
protected AMI_ModTableItem::$aData = array();
// Fields to load
protected AMI_ModTableItem::$aFields = array();
// Tainted fields list
protected AMI_ModTableItem::$aOrigFields = array('public' => false, 'cat_id' => false);
// Fields storing serialized data
// Iterator pointer
// Element id value
// Default value for empty element id
// DB query object
// Module table model
// Primary column field name
/* Inherited Methods */
// Constructor.
public AMI_ModTableItem::__construct ( AMI_ModTable $oTable, [ $oQuery = null ] ) returns AMI_ModTableItem;
// Adds fields to load.
public AMI_ModTableItem::addFields ( [ $aFields = array('*') ], [ bool $reset = false ] ) returns AMI_ModTableItem;
// Returns aData setuped on loading.
public AMI_ModTableItem::addSearchCondition ( $aCondition ) returns array;
// Returns the current element.
public AMI_ModTableItem::current ( ) returns mixed;
// Deletes item from table and clear data array.
public AMI_ModTableItem::delete ( [ mixed $id = null ] ) returns AMI_ModTableItem;
// Returns data array.
public AMI_ModTableItem::getData ( ) returns array;
// Returns difference from origin data.
public AMI_ModTableItem::getDiffFromOrigin ( ) returns array;
// Returns item empty primary key value.
public AMI_ModTableItem::getEmptyId ( ) returns mixed;
// Generates item module front link.
public AMI_ModTableItem::getFrontLink ( ) returns string;
// Generates item full front URL.
public AMI_ModTableItem::getFullURL ( ) returns string;
// Returns current item primary key value.
public AMI_ModTableItem::getId ( ) returns mixed;
// Returns module id.
public AMI_ModTableItem::getModId ( ) returns string;
// Returns link for current module & specific lang& pageID.
public AMI_ModTableItem::getModLink ( [ string $locale = 'en' ], [ int $pageId = 0 ] ) returns string|false;
// Returns origin data.
public AMI_ModTableItem::getOriginData ( ) returns array;
// Returns origin fields as array having keys as field names and values as hashing flag.
public AMI_ModTableItem::getOriginFields ( ) returns array;
// Returns primary key field name.
public AMI_ModTableItem::getPrimaryKeyField ( ) returns string;
// Returns table object.
// Generates item front URL.
public AMI_ModTableItem::getURL ( ) returns string;
// Returns validator exception object validator after save or null.
// Returns field value from data array.
public AMI_ModTableItem::getValue ( string $name ) returns mixed;
// Checks if the field has a specified callback.
public AMI_ModTableItem::hasFieldCallback ( string $field, callback $callback ) returns bool;
// Returns the key of the current element.
public AMI_ModTableItem::key ( ) returns mixed;
// Loads data by specified condition or sets new item data.
// Move forward to next element.
public AMI_ModTableItem::next ( ) returns void;
// Resets primary key.
// Rewinds the Iterator to the first element.
public AMI_ModTableItem::rewind ( ) returns void;
// Saves current item data.
// Sets field callback on AMI_ModTableItem::__get() and AMI_ModTableItem::__set().
public AMI_ModTableItem::setFieldCallback ( string $field, callback $callback ) returns AMI_ModTableItem;
// Sets origin fields.
public AMI_ModTableItem::setOriginFields ( $aFields, [ bool $bAsHash = false ], [ bool $bAppend = true ] ) returns AMI_ModTableItem;
// Sets model values from array.
public AMI_ModTableItem::setValues ( $aData ) returns AMI_ModTableItem;
// Checks if current position is valid.
public AMI_ModTableItem::valid ( ) returns bool;
// Destructor.
public AMI_ModTableItem::__destruct ( ) returns void;
// Property access getter.
public AMI_ModTableItem::__get ( string $name ) returns mixed;
// Property access getter.
public AMI_ModTableItem::__isset ( string $name ) returns bool;
// Property access setter.
public AMI_ModTableItem::__set ( string $name, string $value ) returns void;
// Property access setter.
public AMI_ModTableItem::__unset ( string $name ) returns void;
// Serialized field callback.
protected AMI_ModTableItem::fcbSerialized ( $aData ) returns array;
// Returns table item modifier object.
}
Tags:
since 5.14.4

• Class Properies

protected array $aCommonFieldsValidators

Common fields validators