Commit 8cef1767 authored by Quxl's avatar Quxl

x

parent c15a6589
......@@ -15,7 +15,7 @@ public interface AdminUserService {
void mergeGroup(Fc_user_group group);
List<Map<String, Object>> queryUserList(String keyword, Integer group_id, Page page);
void saveUser(Fc_user user);
void updateUserInfo(Fc_user user);
......@@ -32,4 +32,8 @@ public interface AdminUserService {
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 {
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;
import com.egolm.common.bean.Rjx;
import com.egolm.common.jdbc.Page;
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.ReviewService;
import com.egolm.film.bean.Fc_admin;
......@@ -34,6 +35,9 @@ public class AdminReviewController {
@Autowired
AdminTokenService tokenService;
@Autowired
AdminUserService adminUserService;
@ResponseBody
@PostMapping("list")
......@@ -60,6 +64,18 @@ public class AdminReviewController {
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
@PostMapping("allot")
@ApiOperation("分配审片评委")
......@@ -84,4 +100,16 @@ public class AdminReviewController {
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