questionbankmodel.php 462 B

12345678910111213141516171819202122
  1. <?php
  2. namespace app\index\model;
  3. use think\Model;
  4. /**
  5. * 题库
  6. *
  7. * @author wj
  8. * @date 2025-07-24
  9. */
  10. class questionbankmodel extends Model {
  11. protected $table = 't_question_bank';
  12. public function getlistall() {
  13. $list = $this->where([])->order("sort asc")->select();
  14. return $list;
  15. }
  16. public function getinfobyid($id) {
  17. $where_arr['id'] = $id;
  18. $rec = $this->where($where_arr)->find();
  19. return $rec;
  20. }
  21. }