...
|
...
|
@@ -92,14 +92,12 @@ class Goods extends WechatBase |
|
|
}else{
|
|
|
$data['is_answer'] = 1;//答过题
|
|
|
//判断是否全部正确
|
|
|
$correct = Db::name('user_question_answer')->where(['goods_id'=>$goods_id,'user_id'=>$this->user_id,'is_correct'=>0])->fetchSql()->find();
|
|
|
dump($correct);
|
|
|
$correct = Db::name('user_question_answer')->where(['goods_id'=>$goods_id,'user_id'=>$this->user_id,'is_correct'=>"0"])->find();
|
|
|
if(empty($correct)){
|
|
|
$is_correct = 1;//全部正确
|
|
|
}else{
|
|
|
$is_correct = 0;//未全部正确
|
|
|
}
|
|
|
dump($is_correct);
|
|
|
}
|
|
|
$data['is_correct'] = $is_correct;
|
|
|
//数据回显
|
...
|
...
|
|