49 lines
989 B
PHP
49 lines
989 B
PHP
<?php
|
||
|
||
namespace app\models;
|
||
|
||
use Yii;
|
||
|
||
/**
|
||
* This is the model class for table "{{%goods_cat}}".
|
||
*
|
||
* @property int $id ID
|
||
* @property int $goods_hub_id 商品库ID
|
||
* @property int $cat_id 分类ID
|
||
* @property int $is_delete 是否删除,0=否,1=是
|
||
*/
|
||
class GoodsCat extends \yii\db\ActiveRecord
|
||
{
|
||
/**
|
||
* {@inheritdoc}
|
||
*/
|
||
public static function tableName()
|
||
{
|
||
return '{{%goods_cat}}';
|
||
}
|
||
|
||
/**
|
||
* {@inheritdoc}
|
||
*/
|
||
public function rules()
|
||
{
|
||
return [
|
||
[['goods_hub_id', 'cat_id'], 'required'],
|
||
[['goods_hub_id', 'cat_id', 'is_delete'], 'integer'],
|
||
];
|
||
}
|
||
|
||
/**
|
||
* {@inheritdoc}
|
||
*/
|
||
public function attributeLabels()
|
||
{
|
||
return [
|
||
'id' => 'ID',
|
||
'goods_hub_id' => '商品库ID',
|
||
'cat_id' => '分类ID',
|
||
'is_delete' => '是否删除,0=否,1=是',
|
||
];
|
||
}
|
||
}
|