62 lines
1.4 KiB
PHP
62 lines
1.4 KiB
PHP
<?php
|
||
|
||
namespace app\models;
|
||
|
||
use Yii;
|
||
|
||
/**
|
||
* This is the model class for table "cx_box".
|
||
*
|
||
* @property int $id
|
||
* @property string $name 包厢名称
|
||
* @property int $store_id 所属门店ID
|
||
* @property int $status 1-启用 2-禁用
|
||
* @property string|null $content 门店说明
|
||
* @property int $created_at 添加时间
|
||
* @property int $updated_at 修改时间
|
||
* @property int $is_delete 是否删除,0=否,1=是
|
||
* @property int $deleted_at 删除时间
|
||
* @property string $notice 包厢公告
|
||
*
|
||
*/
|
||
class Box extends \yii\db\ActiveRecord
|
||
{
|
||
/**
|
||
* {@inheritdoc}
|
||
*/
|
||
public static function tableName()
|
||
{
|
||
return 'cx_box';
|
||
}
|
||
|
||
/**
|
||
* {@inheritdoc}
|
||
*/
|
||
public function rules()
|
||
{
|
||
return [
|
||
[['goods_id', 'bj_id', 'notice', 'status', 'created_at'], 'required'],
|
||
[['goods_id', 'bj_id', 'status', 'created_at', 'updated_at', 'is_delete', 'deleted_at','sort'], 'integer'],
|
||
[['notice', 'cover_pic'], 'string'],
|
||
];
|
||
}
|
||
|
||
/**
|
||
* {@inheritdoc}
|
||
*/
|
||
public function attributeLabels()
|
||
{
|
||
return [
|
||
'id' => 'ID',
|
||
'name' => 'Name',
|
||
'store_id' => 'Store ID',
|
||
'status' => 'Status',
|
||
'content' => 'Content',
|
||
'created_at' => 'Created At',
|
||
'updated_at' => 'Updated At',
|
||
'is_delete' => 'Is Delete',
|
||
'deleted_at' => 'Deleted At',
|
||
];
|
||
}
|
||
}
|