Commit daca2c1b by 冷斌

fix bug

parent f1c0c130
...@@ -595,7 +595,9 @@ class AdminPaperAction extends AdministratorAction ...@@ -595,7 +595,9 @@ class AdminPaperAction extends AdministratorAction
{ {
$map = []; $map = [];
$limit = intval($_POST['limit']) ?: 15; $limit = intval($_POST['limit']) ?: 15;
!empty($_POST['question_type']) && $map['exams_question_type_id'] = intval($_POST['question_type']); if (!empty($_POST['question_type']) ) {
$map['exams_question_type_id'] = intval($_POST['question_type']);
}
// 获取当前的试卷 // 获取当前的试卷
$paper_id = intval($_POST['paper_id']); $paper_id = intval($_POST['paper_id']);
$paper = $this->mod->getPaperById($paper_id); $paper = $this->mod->getPaperById($paper_id);
......
...@@ -25,6 +25,8 @@ class ExamsQuestionModel extends Model ...@@ -25,6 +25,8 @@ class ExamsQuestionModel extends Model
public function getQuestionPageList($map = [], $limit = 20, $isJump = false) public function getQuestionPageList($map = [], $limit = 20, $isJump = false)
{ {
$map['is_del'] = 0; $map['is_del'] = 0;
var_dump($map);
die;
$list = $this->where($map)->order('exams_question_id desc')->findPage($limit,false,[],$isJump); $list = $this->where($map)->order('exams_question_id desc')->findPage($limit,false,[],$isJump);
if ($list['data']) { if ($list['data']) {
$list['data'] = $this->haddleData($list['data']); $list['data'] = $this->haddleData($list['data']);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment