first commit
This commit is contained in:
46
common/models/Banner.php
Executable file
46
common/models/Banner.php
Executable file
@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
namespace common\models;
|
||||
|
||||
use Yii;
|
||||
|
||||
/**
|
||||
* This is the model class for table "banner".
|
||||
*
|
||||
* @property int $id
|
||||
* @property string|null $photo
|
||||
* @property int|null $rating
|
||||
*/
|
||||
class Banner extends \yii\db\ActiveRecord
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public static function tableName()
|
||||
{
|
||||
return 'banner';
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function rules()
|
||||
{
|
||||
return [
|
||||
[['rating'], 'integer'],
|
||||
[['photo'], 'string', 'max' => 255],
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function attributeLabels()
|
||||
{
|
||||
return [
|
||||
'id' => 'ID',
|
||||
'photo' => 'Photo',
|
||||
'rating' => 'Rating',
|
||||
];
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user