Commit 78e767be authored by Quxl's avatar Quxl

x

parent 375b33dd
......@@ -26,7 +26,30 @@ public class FilmGroupServiceImpl implements FilmGroupService {
@Override
public List<Map<String, Object>> queryFilmListByGroupId(Integer group_id) {
return jdbcTemplate.queryForList("select id, film_group_id, create_time, last_modify_time, film_no, en_name, cn_name from fc_member_film where film_group_id = ?", group_id);
String sql = ""
+ "select "
+ "mf.id, "
+ "mf.film_group_id, "
+ "mf.create_time, "
+ "mf.enroll_type_name, "
+ "mf.film_type_name, "
+ "mf.last_modify_time, "
+ "mf.film_no, "
+ "mf.en_name, "
+ "mf.cn_name, "
+ "r.review_state, "
+ "r.id review_id "
+ "from "
+ "fc_member_film mf "
+ "left join fc_review r on r.film_id = mf.id and r.opt_state = 3 "
+ "where "
+ "mf.film_group_id is not null and mf.film_group_id = ?";
System.out.println(sql);
return jdbcTemplate.queryForList(sql, group_id);
}
public static void main(String[] args) {
new FilmGroupServiceImpl().queryFilmListByGroupId(null);
}
@Override
......
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