Commit a5f15362 authored by Quxl's avatar Quxl

x

parent 6f2ff710
......@@ -371,7 +371,6 @@ public class ReviewServiceImpl implements ReviewService {
public void tryNextRound(Integer review_id) {
Fc_review review = jdbcTemplate.queryForBean("select * from fc_review where id = ?", Fc_review.class, review_id);
List<Fc_review_record> records = jdbcTemplate.queryForBeans("select * from fc_review_record where review_id = ? and review_round = ?", Fc_review_record.class, review.getId(), review.getReview_round());
Integer review_round = review.getReview_round();
Integer review_state = this.reviewStateElection(records);
if(review_state == null) {//未完
......@@ -382,16 +381,6 @@ public class ReviewServiceImpl implements ReviewService {
jdbcTemplate.executeUpdate("update fc_review set opt_state = 3, review_state = 2 where id = ?", review.getId());
return;
}
Fc_review_history history = new Fc_review_history();
history.setReview_id(review.getId());
history.setEnroll_type_id(enroll_type_id);
history.setFilm_id(review.getFilm_id());
history.setReview_round(review_round);
history.setReview_state(review_state);
history.setCreate_time(new Date());
jdbcTemplate.save(history);
if(review_state.intValue() == -1) {//争议
if(enroll_type_id.intValue() == 4 && review_round.intValue() == 4 && this.queryRoundReviewCount(review.getId(), review_round) >= 2) {//展映把关已经产生两次争议,需要审片委员会介入
this.toNextRound(review.getId());
......@@ -400,7 +389,6 @@ public class ReviewServiceImpl implements ReviewService {
} else {
jdbcTemplate.executeUpdate("update fc_review set opt_state = 1, allot_state = 0 where id = ?", review.getId());
}
return;
}
if(review_round.intValue() == 1) {//审片第一轮都一样
if(review_state.intValue() == 1) {
......@@ -408,7 +396,6 @@ public class ReviewServiceImpl implements ReviewService {
} else {
throw new XRException("第1轮审片结论错误,正确应为:通过,否决");
}
return;
}
if(enroll_type_id.intValue() == 4) {//展映
......@@ -433,9 +420,7 @@ public class ReviewServiceImpl implements ReviewService {
} else {
throw new XRException("展映审片轮数错误[" + review_round + "]");
}
return;
}
if(enroll_type_id.intValue() == 2) {//亚新
} else if(enroll_type_id.intValue() == 2) {//亚新
if(review_round.intValue() == 2) {
if(review_state.intValue() == 3) {//参赛,等待管理员分配进入下一轮评选
jdbcTemplate.executeUpdate("update fc_review set opt_state = 2, review_state = 3 where id = ?", review.getId());
......@@ -470,14 +455,11 @@ public class ReviewServiceImpl implements ReviewService {
} else {
throw new XRException("亚新第6轮审片结论错误");
}
} else {
throw new XRException("亚新审片轮数错误[" + review_round + "]");
}
return;
}
if(enroll_type_id.intValue() == 1) {
} else if(enroll_type_id.intValue() == 1) {
Fc_member_film film = filmService.queryMemberFilmById(review.getFilm_id().longValue());
Integer film_type_id = Integer.valueOf(film.getFilm_type_name());
if(film_type_id == 4) {//金爵短片
......@@ -559,7 +541,14 @@ public class ReviewServiceImpl implements ReviewService {
}
return;
}
Fc_review_history history = new Fc_review_history();
history.setReview_id(review.getId());
history.setEnroll_type_id(enroll_type_id);
history.setFilm_id(review.getFilm_id());
history.setReview_round(review_round);
history.setReview_state(review_state);
history.setCreate_time(new Date());
jdbcTemplate.save(history);
}
@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