Initial commit,修正
This commit is contained in:
Executable
+52
@@ -0,0 +1,52 @@
|
||||
<?php
|
||||
|
||||
namespace common\models;
|
||||
|
||||
use Yii;
|
||||
|
||||
/**
|
||||
* This is the model class for table "c_logs".
|
||||
*
|
||||
* @property string $username
|
||||
* @property string $ip
|
||||
* @property string $data
|
||||
* @property string $create_time
|
||||
*/
|
||||
class Logs extends \yii\db\ActiveRecord
|
||||
{
|
||||
/**
|
||||
* @inheritdoc
|
||||
*/
|
||||
public static function tableName()
|
||||
{
|
||||
return '{{%c_logs}}';
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function rules()
|
||||
{
|
||||
return [
|
||||
[['username', 'create_time'], 'string', 'max' => 32],
|
||||
[['ip'], 'string', 'max' => 64],
|
||||
[['uid'], 'string', 'max' => 11],
|
||||
[['usertype'], 'string', 'max' => 1],
|
||||
[['file','m','v','c','a','domain'], 'string', 'max' => 255],
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function attributeLabels()
|
||||
{
|
||||
return [
|
||||
'username' => Yii::t('common' ,'Username'),
|
||||
'usertype' => Yii::t('common' ,'Usertype'),
|
||||
'ip' => Yii::t('common' ,'Ip'),
|
||||
'data' => Yii::t('common' ,'Do Data'),
|
||||
'create_time' => Yii::t('common' ,'Create Time'),
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user