Commit 5fb59b65 authored by Quxl's avatar Quxl

x

parent 6a57e180
......@@ -274,8 +274,7 @@ public class ReviewServiceImpl implements ReviewService {
@Override
@Transactional
public void toFirstRound(Long member_film_id) {
Integer count = jdbcTemplate.queryForInt("select count(id) from fc_review where film_id = ?", member_film_id);
if(count == 0) {
this.rmReviewData(member_film_id);
List<Fc_member_film_enroll> enrolls = filmService.queryFilmEnrollList(member_film_id);
Integer enroll_type_id = null;
for(Fc_member_film_enroll enroll : enrolls) {
......@@ -303,9 +302,6 @@ public class ReviewServiceImpl implements ReviewService {
review.setCreate_time(now);
review.setFrom_round(0);
jdbcTemplate.save(review);
} else {
throw new XRException("该影片已存在审片流程");
}
}
public void toRound(Integer review_id, Integer review_round) {
......
......@@ -182,14 +182,16 @@ public class FilmController {
String create_ip = WebMvcConfig.getRemoteIp();
filmService.saveCreateBase(filmBase.getId(), admin_id, member_id, create_ip);
} else {
boolean isBeginReview = reviewService.isBeginReview(filmBase.getId());
Fc_member_film film = filmService.queryMemberFilmById(filmBase.getId());
boolean isInitReview = film.getEnroll_type_name() != null && !film.getEnroll_type_name().equals(filmBase.getEnroll_type_name()) && !reviewService.isBeginReview(filmBase.getId());
filmService.updateFilmBase(filmBase);
if(isInitReview) {
if(isBeginReview) {
if(film.getEnroll_type_name() != null && !film.getEnroll_type_name().equals(filmBase.getEnroll_type_name())) {
throw new XRException("审片流程已经开始,不能修改影片性质");
}
} else if(film.getApply_state().intValue() == 2) {
reviewService.rmReviewData(filmBase.getId());
reviewService.toFirstRound(filmBase.getId());
} else {
throw new XRException("影片已经进入审片流程,不能修改影片性质");
}
}
filmService.initKeywords(filmBase.getId());
......
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