Fc_member_filmfilm=this.jdbcTemplate.queryForBean("select * from fc_member_film where id = ?",Fc_member_film.class,member_film_id);
Fc_member_film_enrollenroll=this.jdbcTemplate.queryForBean("select * from fc_member_film_enroll where film_id = ? and enroll_type_id = ?",Fc_member_film_enroll.class,member_film_id,enroll_type_id);
Integerround=film.getReview_round();
Integerround=enroll.getReview_round();
IntegernextRound=null;
IntegernextRound=null;
if(round==null||round==0){
if(round==null||round==0){
nextRound=1;
nextRound=1;
}else{
}else{
nextRound=round+1;
nextRound=round+1;
}
}
jdbcTemplate.executeUpdate("update fc_member_film set review_round = ? where id = ?",nextRound,member_film_id);
jdbcTemplate.executeUpdate("update fc_member_film_enroll set review_round = ? where film_id = ? and enroll_type_id = ?",nextRound,member_film_id,enroll_type_id);
Integercount=jdbcTemplate.queryForInt("select count(id) from fc_review where film_id = ? and review_round = ?",member_film_id,nextRound);
Integercount=jdbcTemplate.queryForInt("select count(id) from fc_review where film_id = ? and review_round = ? and enroll_type_id = ?",member_film_id,nextRound,enroll_type_id);
if(count==0){
if(count==0){
Fc_reviewreview=newFc_review();
Fc_reviewreview=newFc_review();
review.setEnroll_type_id(enroll_type_id);
review.setFilm_id(member_film_id.intValue());
review.setFilm_id(member_film_id.intValue());
review.setReview_round(nextRound);
review.setReview_round(nextRound);
review.setReview_state(0);
review.setReview_state(0);
...
@@ -477,7 +478,6 @@ public class FilmServiceImpl implements FilmService {
...
@@ -477,7 +478,6 @@ public class FilmServiceImpl implements FilmService {
}
}
}
}
/**
/**
* 检索审片列表
* 检索审片列表
*/
*/
...
@@ -503,7 +503,7 @@ public class FilmServiceImpl implements FilmService {
...
@@ -503,7 +503,7 @@ public class FilmServiceImpl implements FilmService {
jdbcTemplate.executeUpdate("delete from fc_review_user where film_id = ? and review_round = ?",member_film_id,review_round);
jdbcTemplate.executeUpdate("delete from fc_review_user where film_id = ? and review_round = ?",member_film_id,review_round);
jdbcTemplate.executeUpdate("update fc_review set review_state = 1 where film_id = ? and review_round = ? and review_state = 0",member_film_id.intValue(),review_round);
jdbcTemplate.executeUpdate("update fc_review set review_state = 1 where film_id = ? and review_round = ? and review_state = 0",member_film_id.intValue(),review_round);
if(user_id!=null&&user_id.length>0){
if(user_id!=null&&user_id.length>0){
...
@@ -526,4 +526,9 @@ public class FilmServiceImpl implements FilmService {
...
@@ -526,4 +526,9 @@ public class FilmServiceImpl implements FilmService {
jdbcTemplate.executeUpdate("update fc_member_film set upload_state = ? where id = ?",upload_state,member_film_id);
jdbcTemplate.executeUpdate("update fc_member_film set upload_state = ? where id = ?",upload_state,member_film_id);
Stringsql="select mf.* from fc_member_film mf, fc_member_film_enroll mfe, fc_review r where mf.id = mfe.film_id and mfe.enroll_type_id = ? and mf.id = r.film_id and mf.review_round = r.review_round and r.create_time >= and r.create_time < ? and r.review_state in () and ";