正在显示
1 个修改的文件
包含
2 行增加
和
4 行删除
@@ -166,10 +166,8 @@ class Index extends Api | @@ -166,10 +166,8 @@ class Index extends Api | ||
166 | { | 166 | { |
167 | $user = $this->auth->getUserinfo(); | 167 | $user = $this->auth->getUserinfo(); |
168 | $find = \db('study')->where('user_id',$user['id'])->find(); | 168 | $find = \db('study')->where('user_id',$user['id'])->find(); |
169 | - $res = \db('study_score_log')->where('study_id',$find['id'])->column('campus_id'); | ||
170 | - foreach ($res as $k){ | ||
171 | - $data = \db('campus')->where('id',$k)->find(); | ||
172 | - } | 169 | + $res = \db('study_score_log')->where('study_id',$find['id'])->value('campus_id'); |
170 | + $data[] = \db('campus')->where('id',$res)->find(); | ||
173 | // $data = db('campus c') | 171 | // $data = db('campus c') |
174 | // ->join('activity a','a.id = c.activity_id') | 172 | // ->join('activity a','a.id = c.activity_id') |
175 | // ->join('school s','s.id = c.school_id') | 173 | // ->join('school s','s.id = c.school_id') |
-
请 注册 或 登录 后发表评论