| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- <?php
- /**
- * 厦门云联储网络科技有限公司
- * https://www.baokuaiyun.com
- * Copyright (c) 2023 爆块云 All rights reserved.
- */
- namespace app\models;
- use yii\db\ActiveRecord;
- /**
- * Class GiveIntegralRules
- * @property integer $id
- * @property integer $rate
- * @property integer $start_date
- * @property integer $end_date
- * @property integer $status
- * @property integer $created_at
- * @property integer $is_delete
- */
- class GiveIntegralRules extends ActiveRecord
- {
- public static function tableName()
- {
- return '{{%give_integral_rules}}';
- }
- public function rules()
- {
- return [
- [["id", "start_date", "end_date", "status", "created_at", "is_delete"], 'integer'],
- [['rate'], 'number'],
- ];
- }
- public function attributeLabels()
- {
- return [
- "id" => "ID",
- "rate" => "赠送积分比例",
- "start_date" => "开始时间",
- "end_date" => "结束时间",
- "status" => "1启用 2禁用",
- "created_at" => "创建时间",
- "is_delete" => "是否删除",
- ];
- }
- public function getFaceStore()
- {
- return $this->hasMany(RulesFaceStore::className(), ['rule_id' => 'id']);
- }
- public function getGiveIntegralStore()
- {
- return $this->hasMany(RulesGiveIntegralStore::className(), ['rule_id' => 'id']);
- }
- }
|