59 lines
1.4 KiB
PHP
59 lines
1.4 KiB
PHP
<?php
|
|
|
|
namespace common\modelsgii;
|
|
|
|
use Yii;
|
|
|
|
/**
|
|
* This is the model class for table "yii_medical_advice".
|
|
*
|
|
* @property int $id
|
|
* @property int $su_id
|
|
* @property string $username 用户名称
|
|
* @property string $idcard 身份证号码
|
|
* @property int $hospital_id 医院id
|
|
* @property int $department_id 科室id
|
|
* @property int $created_at
|
|
* @property int $updated_at
|
|
*/
|
|
class MedicalAdvice extends \common\core\BaseActiveRecord
|
|
{
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
public static function tableName()
|
|
{
|
|
return 'yii_medical_advice';
|
|
}
|
|
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
public function rules()
|
|
{
|
|
return [
|
|
[['su_id', 'username', 'idcard', 'hospital_id', 'department_id'], 'required'],
|
|
[['su_id', 'hospital_id', 'department_id', 'created_at', 'updated_at'], 'integer'],
|
|
[['username'], 'string', 'max' => 30],
|
|
[['idcard'], 'string', 'max' => 11],
|
|
];
|
|
}
|
|
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
public function attributeLabels()
|
|
{
|
|
return [
|
|
'id' => 'ID',
|
|
'su_id' => 'Su ID',
|
|
'username' => '用户名称',
|
|
'idcard' => '身份证号码',
|
|
'hospital_id' => '医院id',
|
|
'department_id' => '科室id',
|
|
'created_at' => 'Created At',
|
|
'updated_at' => 'Updated At',
|
|
];
|
|
}
|
|
}
|