| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394 |
- <?php
- /**
- * 厦门云联储网络科技有限公司
- * https://www.baokuaiyun.com
- * Copyright (c) 2023 爆块云 All rights reserved.
- */
- namespace app\models;
- use Yii;
- use yii\behaviors\TimestampBehavior;
- use yii\db\ActiveRecord;
- /**
- * This is the model class for table "{{%saas_integral_cat}}".
- *
- * @property integer $id
- * @property string $name
- * @property integer $is_enable
- * @property integer $is_delete
- * @property integer $created_at
- * @property integer $updated_at
- */
- class SaasIntegralCat extends \yii\db\ActiveRecord
- {
- /**
- * 删除状态:已删除
- */
- const DELETE_STATUS_TRUE = 1;
- /**
- * 删除状态:未删除
- */
- const DELETE_STATUS_FALSE = 0;
- /**
- * 禁用状态:已禁用
- */
- const IS_ENABLE_FALSE = 0;
- /**
- * 禁用状态:未禁用
- */
- const IS_ENABLE_TRUE= 1;
- /**
- * @inheritdoc
- */
- public static function tableName()
- {
- return '{{%saas_integral_cat}}';
- }
- /**
- * @inheritdoc
- */
- public function rules()
- {
- return [
- [['is_delete', 'is_enable', 'store_id'], 'integer'],
- [['name'], 'string', 'max' => 255],
- ];
- }
- public function behaviors()
- {
- return [
- [
- 'class' => TimestampBehavior::class,
- 'attributes' => [
- ActiveRecord::EVENT_BEFORE_INSERT => ['updated_at', 'created_at'],
- ActiveRecord::EVENT_BEFORE_UPDATE => 'updated_at'
- ]
- ]
- ];
- }
- /**
- * @inheritdoc
- */
- public function attributeLabels()
- {
- return [
- 'id' => '分类ID',
- 'store_id' => '商城id',
- 'name' => '分类名称',
- 'is_delete' => 'Is Delete',
- 'is_enable' => '状态',
- 'created_at' => '创建时间',
- 'updated_at' => '更新时间',
- ];
- }
- }
|