Commit a516c04d authored by Quxl's avatar Quxl

x

parent 9a8af575
...@@ -105,17 +105,57 @@ public class AdminReviewController { ...@@ -105,17 +105,57 @@ public class AdminReviewController {
@ResponseBody @ResponseBody
@PostMapping({"getNewAsianRoundList", "getBestMvListByGroup"}) @PostMapping({"getNewAsianRoundList", "getBestMvListByGroup"})
@ApiOperation("查询亚新榜单") @ApiOperation("查询亚新榜单(全部分组)")
@ApiImplicitParams({ @ApiImplicitParams({
@ApiImplicitParam(paramType="query", dataType="string", name="keyword", value="搜索关键字"), @ApiImplicitParam(paramType="query", dataType="string", name="keyword", value="搜索关键字"),
@ApiImplicitParam(paramType="query", dataType="int", name="review_state", value="评委意见(3参赛 4参赛备选 5参展)"), @ApiImplicitParam(paramType="query", dataType="int", name="review_state", value="评委意见(3参赛 4参赛备选 5参展)"),
@ApiImplicitParam(paramType="query", dataType="int", name="ext_type", value="获奖类型(前端根据审片时保存到数据库的对应字段进行检索)"), @ApiImplicitParam(paramType="query", dataType="int", name="ext_type", value="获奖类型(前端根据审片时保存到数据库的对应字段进行检索)"),
@ApiImplicitParam(paramType="query", dataType="int", name="review_round", value="第2或3选(2,3)"), @ApiImplicitParam(paramType="query", dataType="int", name="review_round", value="第2或3选(2,3)"),
})
public Object getBestMvListByGroup(
String keyword,
Integer review_state,
Integer review_round,
String ext_type) {
Page page = new Page(1L, 999999999999L);
List<Map<String, Object>> ugList = reviewService.queryUserGroupListByReviewRecord(2, review_round);
for(Map<String, Object> ugMap : ugList) {
Integer ugId = ((Number)ugMap.get("group_id")).intValue();
List<Map<String, Object>> list = reviewService.queryBestMvListByGroup(keyword, ugId, review_state, review_round, ext_type, page);
ugMap.put("list", list);
}
return Rjx.jsonOk().setData(ugList);
}
@ResponseBody
@PostMapping({"getUserGroupListByReviewRecord"})
@ApiOperation("查询参与评审环节的评委组")
@ApiImplicitParams({
@ApiImplicitParam(paramType="query", dataType="int", name="enroll_type_id"),
@ApiImplicitParam(paramType="query", dataType="int", name="review_round"),
})
public Object queryUserGroupListByReviewRecord(Integer enroll_type_id, Integer review_round) {
XRException.assertNotBlank("影片性质不能为空", enroll_type_id);
XRException.assertNotBlank("审片环节不能为空", review_round);
List<Map<String, Object>> ugList = reviewService.queryUserGroupListByReviewRecord(enroll_type_id, review_round);
return Rjx.jsonOk().setData(ugList);
}
@ResponseBody
@PostMapping({"getBestMvList"})
@ApiOperation("查询亚新榜单(单个分组)")
@ApiImplicitParams({
@ApiImplicitParam(paramType="query", dataType="string", name="keyword", value="搜索关键字"),
@ApiImplicitParam(paramType="query", dataType="int", name="review_state", value="评委意见(3参赛 4参赛备选 5参展)"),
@ApiImplicitParam(paramType="query", dataType="int", name="user_group_id", value="评委组ID)"),
@ApiImplicitParam(paramType="query", dataType="int", name="ext_type", value="获奖类型(前端根据审片时保存到数据库的对应字段进行检索)"),
@ApiImplicitParam(paramType="query", dataType="int", name="review_round", value="第2或3选(2,3)"),
@ApiImplicitParam(paramType="query", dataType="long", name="index", value="分页编号"), @ApiImplicitParam(paramType="query", dataType="long", name="index", value="分页编号"),
@ApiImplicitParam(paramType="query", dataType="long", name="limit", value="分页大小"), @ApiImplicitParam(paramType="query", dataType="long", name="limit", value="分页大小"),
}) })
public Object getBestMvListByGroup( public Object getBestMvList(
String keyword, String keyword,
Integer user_group_id,
Integer review_state, Integer review_state,
Integer review_round, Integer review_round,
String ext_type, String ext_type,
...@@ -124,13 +164,8 @@ public class AdminReviewController { ...@@ -124,13 +164,8 @@ public class AdminReviewController {
index = index == null ? 1 : index; index = index == null ? 1 : index;
limit = limit == null ? 20 : limit; limit = limit == null ? 20 : limit;
Page page = new Page(index, limit); Page page = new Page(index, limit);
List<Map<String, Object>> ugList = reviewService.queryUserGroupListByReviewRecord(2, review_round); List<Map<String, Object>> list = reviewService.queryBestMvListByGroup(keyword, user_group_id, review_state, review_round, ext_type, page);
for(Map<String, Object> ugMap : ugList) { return Rjx.jsonOk().setData(list).setPage(page);
Integer ugId = ((Number)ugMap.get("group_id")).intValue();
List<Map<String, Object>> list = reviewService.queryBestMvListByGroup(keyword, ugId, review_state, review_round, ext_type, page);
ugMap.put("list", list);
}
return Rjx.jsonOk().setData(ugList).setPage(page);
} }
@ResponseBody @ResponseBody
......
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