SaasUnitFounderLevel.php 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  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 $admin_id
  17. * @property string $name
  18. * @property string $rate
  19. * @property string $achieve
  20. * @property integer $is_delete
  21. * @property integer $status
  22. * @property integer $created_at
  23. * @property integer $updated_at
  24. */
  25. class SaasUnitFounderLevel extends \yii\db\ActiveRecord
  26. {
  27. /**
  28. * @inheritdoc
  29. */
  30. public static function tableName()
  31. {
  32. return '{{%saas_unit_founder_level}}';
  33. }
  34. public function behaviors()
  35. {
  36. return [
  37. [
  38. 'class' => TimestampBehavior::class,
  39. 'attributes' => [
  40. ActiveRecord::EVENT_BEFORE_INSERT => ['created_at'],
  41. ActiveRecord::EVENT_BEFORE_UPDATE => ['updated_at']
  42. ]
  43. ]
  44. ];
  45. }
  46. /**
  47. * @inheritdoc
  48. */
  49. public function rules()
  50. {
  51. return [
  52. [['level', 'status','is_delete','admin_id'], 'integer'],
  53. [['rate','achieve'], 'number'],
  54. [['name'], 'string'],
  55. [['created_at', 'updated_at'], 'safe']
  56. ];
  57. }
  58. /**
  59. * @inheritdoc
  60. */
  61. public function attributeLabels()
  62. {
  63. return [
  64. 'id' => 'ID',
  65. 'level' => '等级',
  66. 'name' => '名称',
  67. 'rate' => '比例',
  68. 'status' => '状态',
  69. 'created_at' => '创建时间',
  70. 'updated_at' => '更新时间',
  71. ];
  72. }
  73. }