StoreStaffApply.php 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. <?php
  2. namespace addons\Store\common\models;
  3. use Yii;
  4. /**
  5. * This is the model class for table "qimall_addons_store_staff_apply".
  6. *
  7. * @property int $id ID
  8. * @property int $mall_id 商城ID
  9. * @property int $user_id 用户ID
  10. * @property int $store_id 门店ID
  11. * @property int $status 状态;1正常,0禁用,-1删除
  12. * @property int $check_status 审核状态:0:待审核;1:已通过;2:未通过
  13. * @property string $check_remark 审核备注
  14. * @property int $created_at 创建时间
  15. * @property int $updated_at 更新时间
  16. * @property string $name 姓名
  17. * @property string $pic 相片
  18. * @property string $phone 电话
  19. */
  20. class StoreStaffApply extends \common\models\base\BaseActiveRecord
  21. {
  22. /**
  23. * {@inheritdoc}
  24. */
  25. public static function tableName()
  26. {
  27. return 'qimall_addons_store_staff_apply';
  28. }
  29. /**
  30. * {@inheritdoc}
  31. */
  32. public function rules()
  33. {
  34. return [
  35. [['mall_id', 'user_id', 'store_id', 'status', 'check_status', 'created_at', 'updated_at'], 'integer'],
  36. [['check_remark', 'pic'], 'string', 'max' => 255],
  37. [['name'], 'string', 'max' => 50],
  38. [['phone'], 'string', 'max' => 15],
  39. ];
  40. }
  41. /**
  42. * {@inheritdoc}
  43. */
  44. public function attributeLabels()
  45. {
  46. return [
  47. 'id' => 'ID',
  48. 'mall_id' => 'Mall ID',
  49. 'user_id' => 'User ID',
  50. 'store_id' => 'Store ID',
  51. 'status' => 'Status',
  52. 'check_status' => 'Check Status',
  53. 'check_remark' => 'Check Remark',
  54. 'created_at' => 'Created At',
  55. 'updated_at' => 'Updated At',
  56. 'name' => 'Name',
  57. 'pic' => 'Pic',
  58. 'phone' => 'Phone',
  59. ];
  60. }
  61. public function getStore()
  62. {
  63. return $this->hasOne(Store::class, ['id' => 'store_id']);
  64. }
  65. }