PluginPoolLevel.php 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <?php
  2. /**
  3. * 厦门云联储网络科技有限公司
  4. * https://www.baokuaiyun.com
  5. * Copyright (c) 2023 爆块云 All rights reserved.
  6. */
  7. namespace app\models;
  8. use Yii;
  9. use yii\behaviors\TimestampBehavior;
  10. use yii\db\ActiveRecord;
  11. /**
  12. * This is the model class for table "{{%saas_partner_level}}".
  13. *
  14. * @property integer $id
  15. * @property integer $level
  16. * @property integer $store_id
  17. * @property integer $config_id
  18. * @property string $name
  19. * @property string $rate
  20. * @property string $achieve
  21. * @property integer $is_delete
  22. * @property integer $is_share
  23. * @property integer $status
  24. * @property integer $created_at
  25. * @property integer $updated_at
  26. */
  27. class PluginPoolLevel extends \yii\db\ActiveRecord
  28. {
  29. /**
  30. * @inheritdoc
  31. */
  32. public static function tableName()
  33. {
  34. return '{{%plugin_pool_level}}';
  35. }
  36. public function behaviors()
  37. {
  38. return [
  39. [
  40. 'class' => TimestampBehavior::class,
  41. 'attributes' => [
  42. ActiveRecord::EVENT_BEFORE_INSERT => ['created_at'],
  43. ActiveRecord::EVENT_BEFORE_UPDATE => ['updated_at']
  44. ]
  45. ]
  46. ];
  47. }
  48. /**
  49. * @inheritdoc
  50. */
  51. public function rules()
  52. {
  53. return [
  54. [['level', 'status','is_delete','store_id','is_share','config_id'], 'integer'],
  55. [['rate','achieve'], 'number'],
  56. [['name'], 'string'],
  57. [['created_at', 'updated_at'], 'safe']
  58. ];
  59. }
  60. /**
  61. * @inheritdoc
  62. */
  63. public function attributeLabels()
  64. {
  65. return [
  66. 'id' => 'ID',
  67. 'level' => '等级',
  68. 'name' => '名称',
  69. 'rate' => '比例',
  70. 'status' => '状态',
  71. 'created_at' => '创建时间',
  72. 'updated_at' => '更新时间',
  73. ];
  74. }
  75. }