SpecialistInfosAssociation.php 661 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. namespace App\Models;
  3. /**
  4. * 专家信息关联表
  5. */
  6. class SpecialistInfosAssociation extends SoftBaseModel
  7. {
  8. /**
  9. * 关联类型[1:点赞,2:喜欢]
  10. * @var integer
  11. */
  12. const ASSOCIATION_TYPE_THUMBS_UP = 1;
  13. /**
  14. * 关联类型[1:点赞,2:喜欢]
  15. * @var integer
  16. */
  17. const ASSOCIATION_TYPE_LOVE = 2;
  18. //操作类型[1:课堂,2:训练]
  19. const OPERATION_TYPE_CLASS_ROOM = 1;
  20. const OPERATION_TYPE_WORKOUT = 2;
  21. protected $table = "specialist_infos_association";
  22. public function specialist(){
  23. return $this->belongsTo(SpecialistInfo::class, 'association_id',"id");
  24. }
  25. }