StoreAdmin.php 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  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 "{{%store_admin}}".
  13. *
  14. * @property integer $id
  15. * @property string $username
  16. * @property string $password
  17. * @property integer $store_id
  18. * @property integer $saas_id
  19. * @property integer $is_delete
  20. * @property integer $status
  21. * @property integer $created_at
  22. * @property integer $updated_at
  23. * @property string $rules
  24. */
  25. class StoreAdmin extends \yii\db\ActiveRecord
  26. {
  27. /**
  28. * @inheritdoc
  29. */
  30. public static function tableName()
  31. {
  32. return '{{%store_admin}}';
  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. [["id", "store_id", "is_delete", "status", "created_at", "updated_at", "saas_id"], 'integer'],
  53. [["username", "password", 'rules'], 'string']
  54. ];
  55. }
  56. /**
  57. * @inheritdoc
  58. */
  59. public function attributeLabels()
  60. {
  61. return [
  62. "id" => "",
  63. "username" => "用户名",
  64. "password" => "密码",
  65. "store_id" => "商城id",
  66. "is_delete" => "是否删除",
  67. "status" => "状态 0关闭 1开启",
  68. "created_at" => "",
  69. "updated_at" => "",
  70. "rules" => "规则",
  71. "saas_id" => '联盟用户id'
  72. ];
  73. }
  74. }