Commit 4bd10bfd authored by Quxl's avatar Quxl

x

parent 4e580fc1
......@@ -18,4 +18,6 @@ public interface ReviewService {
void saveDoubtful(Fc_review_doubtful doubtful);
List<Map<String, Object>> queryDoubtfulListByFilmId(Integer film_id, Integer user_id);
}
\ No newline at end of file
......@@ -75,5 +75,11 @@ public class ReviewServiceImpl implements ReviewService {
jdbcTemplate.save(doubtful);
}
@Override
public List<Map<String, Object>> queryDoubtfulListByFilmId(Integer film_id, Integer user_id) {
String sql = "select rd.* from fc_review_doubtful rd, fc_review r where rd.review_id = r.id and r.film_id = ? and rd.user_id = ?";
return jdbcTemplate.queryForList(sql, film_id, user_id);
}
}
......@@ -83,4 +83,17 @@ public class UserReviewController {
service.saveDoubtful(doubtful);
return Rjx.jsonOk().setData(doubtful);
}
@ResponseBody
@PostMapping("doubtful_list")
@ApiOperation("查询疑点记录")
@ApiImplicitParams({
@ApiImplicitParam(paramType = "query", dataType = "int", required = false, name = "review_id", value="审片ID"),
})
public Object getDoubtfulList(Integer film_id) {
LoginToken token = tokenService.getToken();
Integer user_id = (Integer)token.getId();
List<Map<String, Object>> list = service.queryDoubtfulListByFilmId(film_id, user_id);
return Rjx.jsonOk().setData(list);
}
}
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