Public Member Functions | |
tableName () | |
rules () | |
relations () | |
getExistUser () | |
attributeLabels () | |
implementFromSession () | |
unsetExistFields () | |
search () | |
rules () | |
attributeLabels () | |
search () | |
tableName () |
Static Public Member Functions | |
static | model ($className=__CLASS__) |
static | model ($className=__CLASS__) |
Protected Member Functions | |
afterFind () | |
beforeSave () |
Definition at line 27 of file TmpUser.php.
TmpUser::attributeLabels | ( | ) |
Reimplemented from TmpUserBasic.
Definition at line 17 of file TmpUser.php.
References model(), and WebCustModule\t().
TmpUser::attributeLabels | ( | ) |
Reimplemented from TmpUserBasic.
Definition at line 176 of file TmpUser.php.
References WebCustModule\t().
|
static |
Returns the static model of the specified AR class.
string | $className | active record class name. |
Reimplemented from TmpUserBasic.
Definition at line 34 of file TmpUser.php.
Referenced by attributeLabels(), model(), rules(), search(), and ShoppingcartTest\setUp().
|
static |
Returns the static model of the specified AR class.
string | $className | active record class name. |
Reimplemented from TmpUserBasic.
Definition at line 37 of file TmpUser.php.
References model().
TmpUser::relations | ( | ) |
Reimplemented from TmpUserBasic.
Definition at line 154 of file TmpUser.php.
TmpUser::rules | ( | ) |
protected function beforeSave() { if(parent::beforeSave()) {
Format dates based on the locale foreach($this->metadata->tableSchema->columns as $columnName => $column) { if ($column->dbType == 'date') { $this->$columnName = date('Y-m-d', CDateTimeParser::parse($this->$columnName, Yii::app()->locale->getDateFormat('short'))); } elseif ($column->dbType == 'datetime') { $this->$columnName = date('Y-m-d H:i:s', CDateTimeParser::parse($this->$columnName, Yii::app()->locale->getDateTimeFormat('short'))); } } return true; } else return false; } protected function afterFind() { Format dates based on the locale foreach($this->metadata->tableSchema->columns as $columnName => $column) { if (!strlen($this->$columnName)) continue;
if ($column->dbType == 'date') { $this->$columnName = Yii::app()->dateFormatter->formatDateTime( CDateTimeParser::parse( $this->$columnName, 'yyyy-MM-dd' ), 'short',null ); } elseif ($column->dbType == 'datetime' || $column->dbType == 'timestamp') { $this->$columnName = Yii::app()->dateFormatter->formatDateTime( CDateTimeParser::parse( $this->$columnName, 'yyyy-MM-dd hh:mm:ss' ), 'short','short' ); } } return parent::afterFind(); }
Reimplemented from TmpUserBasic.
Definition at line 5 of file TmpUser.php.
References model().
TmpUser::rules | ( | ) |
protected function beforeSave() { if(parent::beforeSave()) {
Format dates based on the locale foreach($this->metadata->tableSchema->columns as $columnName => $column) { if ($column->dbType == 'date') { $this->$columnName = date('Y-m-d', CDateTimeParser::parse($this->$columnName, Yii::app()->locale->getDateFormat('short'))); } elseif ($column->dbType == 'datetime') { $this->$columnName = date('Y-m-d H:i:s', CDateTimeParser::parse($this->$columnName, Yii::app()->locale->getDateTimeFormat('short'))); } } return true; } else return false; } protected function afterFind() { Format dates based on the locale foreach($this->metadata->tableSchema->columns as $columnName => $column) { if (!strlen($this->$columnName)) continue;
if ($column->dbType == 'date') { $this->$columnName = Yii::app()->dateFormatter->formatDateTime( CDateTimeParser::parse( $this->$columnName, 'yyyy-MM-dd' ), 'short',null ); } elseif ($column->dbType == 'datetime' || $column->dbType == 'timestamp') { $this->$columnName = Yii::app()->dateFormatter->formatDateTime( CDateTimeParser::parse( $this->$columnName, 'yyyy-MM-dd hh:mm:ss' ), 'short','short' ); } } return parent::afterFind(); }
Reimplemented from TmpUserBasic.
Definition at line 131 of file TmpUser.php.
TmpUser::search | ( | ) |
Retrieves a list of models based on the current search/filter conditions.
Reimplemented from TmpUserBasic.
Definition at line 28 of file TmpUser.php.
References model().
TmpUser::search | ( | ) |
Retrieves a list of models based on the current search/filter conditions.
Reimplemented from TmpUserBasic.
Definition at line 237 of file TmpUser.php.
TmpUser::tableName | ( | ) |
Reimplemented from TmpUserBasic.
Definition at line 42 of file TmpUser.php.
TmpUser::tableName | ( | ) |
Reimplemented from TmpUserBasic.
Definition at line 42 of file TmpUser.php.