TrainingQuestions.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | likeadmin快速开发前后端分离管理后台(PHP版)
  4. // +----------------------------------------------------------------------
  5. // | 欢迎阅读学习系统程序代码,建议反馈是我们前进的动力
  6. // | 开源版本可自由商用,可去除界面版权logo
  7. // | gitee下载:https://gitee.com/likeshop_gitee/likeadmin
  8. // | github下载:https://github.com/likeshop-github/likeadmin
  9. // | 访问官网:https://www.likeadmin.cn
  10. // | likeadmin团队 版权所有 拥有最终解释权
  11. // +----------------------------------------------------------------------
  12. // | author: likeadminTeam
  13. // +----------------------------------------------------------------------
  14. namespace app\common\model\training;
  15. use app\common\model\BaseModel;
  16. use app\common\model\goods_category\GoodsCategory;
  17. /**
  18. * TrainingQuestions模型
  19. * Class TrainingQuestions
  20. * @package app\common\model
  21. */
  22. class TrainingQuestions extends BaseModel
  23. {
  24. protected $name = 'training_questions';
  25. protected $type = [
  26. 'question_selects' => 'array',
  27. ];
  28. public function goodsCategory()
  29. {
  30. return $this->hasOne(GoodsCategory::class,'id','subclass');
  31. }
  32. }