Commit 9c3b8b3c authored by Quxl's avatar Quxl

x

parent f0919dcd
...@@ -135,7 +135,7 @@ public interface FilmService { ...@@ -135,7 +135,7 @@ public interface FilmService {
List<Map<String, Object>> queryReviewList(String keyword, Integer group_id, Integer enroll_type_id, Integer film_type_name, Integer film_type_name_short, List<Map<String, Object>> queryReviewList(String keyword, Integer group_id, Integer enroll_type_id, Integer film_type_name, Integer film_type_name_short,
String film_country, Integer review_round, Integer[] review_state, Page page); String film_country, Integer review_round, Integer[] review_state, Page page);
void allot(Integer review_id, Integer review_round, Integer[] user_id); void saveReviewRecordIfNotExists(Integer review_id, Integer review_round, Integer[] user_id);
void saveUploadId(Long member_film_id, String upload_id); void saveUploadId(Long member_film_id, String upload_id);
......
...@@ -497,7 +497,7 @@ public class FilmServiceImpl implements FilmService { ...@@ -497,7 +497,7 @@ public class FilmServiceImpl implements FilmService {
@Override @Override
@Transactional @Transactional
public void allot(Integer review_id, Integer review_round, Integer[] user_id) { public void saveReviewRecordIfNotExists(Integer review_id, Integer review_round, Integer[] user_id) {
String sql = "insert into fc_review_record(review_id, user_id, review_round, view_state, review_state, create_time) select ?, ?, ?, 0, 1, now() from dual where not exists (select * from fc_review_record where review_id = ? and user_id = ? and review_round = ?)"; String sql = "insert into fc_review_record(review_id, user_id, review_round, view_state, review_state, create_time) select ?, ?, ?, 0, 1, now() from dual where not exists (select * from fc_review_record where review_id = ? and user_id = ? and review_round = ?)";
Object[][] objs = new Object[user_id.length][]; Object[][] objs = new Object[user_id.length][];
for(int i = 0; i < objs.length; i++) { for(int i = 0; i < objs.length; i++) {
......
...@@ -62,7 +62,7 @@ public class AdminReviewController { ...@@ -62,7 +62,7 @@ public class AdminReviewController {
@ApiImplicitParam(paramType="query", dataType="int", required=true, name="user_id", value="审片评委ID", allowMultiple=true), @ApiImplicitParam(paramType="query", dataType="int", required=true, name="user_id", value="审片评委ID", allowMultiple=true),
}) })
public Object allot(Integer review_id, Integer review_round, Integer[] user_id) { public Object allot(Integer review_id, Integer review_round, Integer[] user_id) {
filmService.allot(review_id, review_round, user_id); filmService.saveReviewRecordIfNotExists(review_id, review_round, user_id);
return Rjx.jsonOk(); return Rjx.jsonOk();
} }
......
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