mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-27 12:33:09 +08:00
40 lines
606 B
PHP
40 lines
606 B
PHP
<?php
|
|
|
|
|
|
namespace yiiunit\extensions\gii;
|
|
|
|
|
|
use yii\db\ActiveRecord;
|
|
|
|
class Profile extends ActiveRecord
|
|
{
|
|
/**
|
|
* @inheritdoc
|
|
*/
|
|
public static function tableName()
|
|
{
|
|
return 'profile';
|
|
}
|
|
|
|
/**
|
|
* @inheritdoc
|
|
*/
|
|
public function rules()
|
|
{
|
|
return [
|
|
[['description'], 'required'],
|
|
[['description'], 'string', 'max' => 128]
|
|
];
|
|
}
|
|
|
|
/**
|
|
* @inheritdoc
|
|
*/
|
|
public function attributeLabels()
|
|
{
|
|
return [
|
|
'id' => 'ID',
|
|
'description' => 'Description',
|
|
];
|
|
}
|
|
}
|