Commit 8cef1767 authored by Quxl's avatar Quxl

x

parent c15a6589
...@@ -32,4 +32,8 @@ public interface AdminUserService { ...@@ -32,4 +32,8 @@ public interface AdminUserService {
void deleteGroupById(Integer group_id); void deleteGroupById(Integer group_id);
List<Map<String, Object>> getReviewUserList(Integer review_id);
List<Map<String, Object>> getReviewGroupList(Integer review_id);
} }
...@@ -93,4 +93,16 @@ public class AdminUserServiceImpl implements AdminUserService { ...@@ -93,4 +93,16 @@ public class AdminUserServiceImpl implements AdminUserService {
jdbcTemplate.executeUpdate("delete from fc_user_group where group_id = ?", group_id); jdbcTemplate.executeUpdate("delete from fc_user_group where group_id = ?", group_id);
} }
@Override
public List<Map<String, Object>> getReviewUserList(Integer review_id) {
String sql = "select u.* from fc_user u, fc_user_group_fun fn, fc_review r where u.group_id = fn.group_id and fn.fun_id = r.enroll_type_id and r.id = ?";
return jdbcTemplate.queryForList(sql);
}
@Override
public List<Map<String, Object>> getReviewGroupList(Integer review_id) {
String sql = "select g.* from fc_user_group g, fc_user_group_fun fn, fc_review r where g.group_id = fn.group_id and fn.fun_id = r.enroll_type_id and r.id = ?";
return jdbcTemplate.queryForList(sql);
}
} }
...@@ -12,6 +12,7 @@ import org.springframework.web.bind.annotation.ResponseBody; ...@@ -12,6 +12,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
import com.egolm.common.bean.Rjx; import com.egolm.common.bean.Rjx;
import com.egolm.common.jdbc.Page; import com.egolm.common.jdbc.Page;
import com.egolm.film.api.service.AdminTokenService; import com.egolm.film.api.service.AdminTokenService;
import com.egolm.film.api.service.AdminUserService;
import com.egolm.film.api.service.FilmService; import com.egolm.film.api.service.FilmService;
import com.egolm.film.api.service.ReviewService; import com.egolm.film.api.service.ReviewService;
import com.egolm.film.bean.Fc_admin; import com.egolm.film.bean.Fc_admin;
...@@ -35,6 +36,9 @@ public class AdminReviewController { ...@@ -35,6 +36,9 @@ public class AdminReviewController {
@Autowired @Autowired
AdminTokenService tokenService; AdminTokenService tokenService;
@Autowired
AdminUserService adminUserService;
@ResponseBody @ResponseBody
@PostMapping("list") @PostMapping("list")
@ApiOperation("查询选片列表") @ApiOperation("查询选片列表")
...@@ -60,6 +64,18 @@ public class AdminReviewController { ...@@ -60,6 +64,18 @@ public class AdminReviewController {
return Rjx.jsonOk().setData(list).setPage(page); return Rjx.jsonOk().setData(list).setPage(page);
} }
@ResponseBody
@PostMapping("getReviewGroupUserList")
@ApiOperation("分配审片评委")
@ApiImplicitParams({
@ApiImplicitParam(paramType="query", dataType="int", required=true, name="review_id", value="审片主表ID"),
})
public Object getReviewGroupUserList(Integer review_id) {
List<Map<String, Object>> groupList = adminUserService.getReviewGroupList(review_id);
List<Map<String, Object>> userList = adminUserService.getReviewUserList(review_id);
return Rjx.jsonOk().set("userList", userList).set("groupList", groupList);
}
@ResponseBody @ResponseBody
@PostMapping("allot") @PostMapping("allot")
@ApiOperation("分配审片评委") @ApiOperation("分配审片评委")
...@@ -84,4 +100,16 @@ public class AdminReviewController { ...@@ -84,4 +100,16 @@ public class AdminReviewController {
return Rjx.jsonOk().setData(list); return Rjx.jsonOk().setData(list);
} }
@ResponseBody
@PostMapping("toNextRound")
@ApiOperation("查询审片评委")
@ApiImplicitParams({
@ApiImplicitParam(paramType="query", dataType="int", required=true, name="review_id", value="审片主表ID"),
})
public Object toNextRound(Integer review_id) {
reviewService.toNextRound(review_id);
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