|
|
@ -31,7 +31,7 @@ public class SigninController { |
|
|
}) |
|
|
}) |
|
|
@RequestMapping(value = "info", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
@RequestMapping(value = "info", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
public JsonResponse<SigninVo.SignInfoVo> getSignField(HttpServletRequest request, |
|
|
public JsonResponse<SigninVo.SignInfoVo> getSignField(HttpServletRequest request, |
|
|
@ApiParam @Validated @RequestBody Long taskPluginId) throws Exception { |
|
|
@RequestParam Long taskPluginId) throws Exception { |
|
|
log.info("{}:查看签到需要填的信息"); |
|
|
log.info("{}:查看签到需要填的信息"); |
|
|
//获取userId
|
|
|
//获取userId
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
@ -40,18 +40,34 @@ public class SigninController { |
|
|
return JsonResponse.newInstance().ok(signInfoVo); |
|
|
return JsonResponse.newInstance().ok(signInfoVo); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// @ApiOperation(value = "模糊查询签到信息", notes = "")
|
|
|
@ApiOperation(value = "签到(保存签到的信息)", notes = "") |
|
|
// @ApiImplicitParams({
|
|
|
@ApiImplicitParams({ |
|
|
// })
|
|
|
}) |
|
|
// @RequestMapping(value = "fuzzy", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"})
|
|
|
@RequestMapping(value = "", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"}) |
|
|
// public JsonResponse<SigninVo.SignInfoVo> getSignByFuzzy(HttpServletRequest request,
|
|
|
public JsonResponse<SigninVo.SigninVoInfo> signin(HttpServletRequest request, |
|
|
// @ApiParam @Validated @RequestBody Long projectId,String signinName,String key) throws Exception {
|
|
|
@ApiParam @Validated @RequestBody SigninDto.SaveSign saveSign) throws Exception { |
|
|
// log.info("{}:查看签到需要填的信息");
|
|
|
log.info("{}:签到"); |
|
|
// //获取userId
|
|
|
//获取userId
|
|
|
// Long userId = userService.getUserIdByToken(request);
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
//
|
|
|
SigninVo.SignInfoVo signInfoVo = signinService.saveSignInfo(saveSign, userId); |
|
|
// return JsonResponse.newInstance().ok(signInfoVo);
|
|
|
|
|
|
// }
|
|
|
return JsonResponse.newInstance().ok(saveSign); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "模糊查询签到信息", notes = "") |
|
|
|
|
|
@ApiImplicitParams({ |
|
|
|
|
|
}) |
|
|
|
|
|
@RequestMapping(value = "fuzzy", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
|
|
|
public JsonResponse<List<String>> getSignByFuzzy(HttpServletRequest request, |
|
|
|
|
|
@RequestParam Long taskPluginId,String signinName,String key) throws Exception { |
|
|
|
|
|
log.info("{}:查看签到需要填的信息"); |
|
|
|
|
|
//获取userId
|
|
|
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
|
|
|
List<String> keys = signinService.getFuzzyKey(userId,taskPluginId,signinName,key); |
|
|
|
|
|
|
|
|
|
|
|
return JsonResponse.newInstance().ok(keys); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// @ApiOperation(value = "签到", notes = "")
|
|
|
// @ApiOperation(value = "签到", notes = "")
|
|
|
// @ApiImplicitParams({
|
|
|
// @ApiImplicitParams({
|
|
|
@ -67,33 +83,33 @@ public class SigninController { |
|
|
// return JsonResponse.newInstance().ok(signinVoInfo);
|
|
|
// return JsonResponse.newInstance().ok(signinVoInfo);
|
|
|
// }
|
|
|
// }
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "查看自己的签到信息", notes = "") |
|
|
// @ApiOperation(value = "查看自己的签到信息", notes = "")
|
|
|
@ApiImplicitParams({ |
|
|
// @ApiImplicitParams({
|
|
|
@ApiImplicitParam(name = "taskId", value = "签到任务的id", required = true, paramType = ""), |
|
|
// @ApiImplicitParam(name = "taskId", value = "签到任务的id", required = true, paramType = ""),
|
|
|
}) |
|
|
// })
|
|
|
@RequestMapping(value = "", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
// @RequestMapping(value = "", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"})
|
|
|
public JsonResponse<SigninVo.SigninVoInfo> getSignByTaskId(HttpServletRequest request, |
|
|
// public JsonResponse<SigninVo.SigninVoInfo> getSignByTaskId(HttpServletRequest request,
|
|
|
@RequestParam(required = true) Long taskId) throws Exception { |
|
|
// @RequestParam(required = true) Long taskId) throws Exception {
|
|
|
log.info("查看自己的签到信息"); |
|
|
// log.info("查看自己的签到信息");
|
|
|
//获取userId
|
|
|
// //获取userId
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
// Long userId = userService.getUserIdByToken(request);
|
|
|
SigninVo.SigninVoInfo signinVoInfo = signinService.getSignByTaskId(taskId,userId); |
|
|
// SigninVo.SigninVoInfo signinVoInfo = signinService.getSignByTaskId(taskId,userId);
|
|
|
|
|
|
//
|
|
|
return JsonResponse.newInstance().ok(signinVoInfo); |
|
|
// return JsonResponse.newInstance().ok(signinVoInfo);
|
|
|
} |
|
|
// }
|
|
|
|
|
|
//
|
|
|
@ApiOperation(value = "查看所有人的签到信息", notes = "") |
|
|
// @ApiOperation(value = "查看所有人的签到信息", notes = "")
|
|
|
@ApiImplicitParams({ |
|
|
// @ApiImplicitParams({
|
|
|
@ApiImplicitParam(name = "taskId", value = "签到任务的id", required = true, paramType = ""), |
|
|
// @ApiImplicitParam(name = "taskId", value = "签到任务的id", required = true, paramType = ""),
|
|
|
}) |
|
|
// })
|
|
|
@RequestMapping(value = "all", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
// @RequestMapping(value = "all", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"})
|
|
|
public JsonResponse<List<SigninVo.SigninVoInfo>> getSignAllByTaskId(HttpServletRequest request, |
|
|
// public JsonResponse<List<SigninVo.SigninVoInfo>> getSignAllByTaskId(HttpServletRequest request,
|
|
|
@RequestParam(required = true) Long taskId) throws Exception { |
|
|
// @RequestParam(required = true) Long taskId) throws Exception {
|
|
|
log.info("查看所有人的签到信息"); |
|
|
// log.info("查看所有人的签到信息");
|
|
|
//获取userId
|
|
|
// //获取userId
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
// Long userId = userService.getUserIdByToken(request);
|
|
|
List<SigninVo.SigninVoInfo> signinVoInfo = signinService.getSignAllByTaskId(taskId,userId); |
|
|
// List<SigninVo.SigninVoInfo> signinVoInfo = signinService.getSignAllByTaskId(taskId,userId);
|
|
|
|
|
|
//
|
|
|
return JsonResponse.newInstance().ok(signinVoInfo); |
|
|
// return JsonResponse.newInstance().ok(signinVoInfo);
|
|
|
} |
|
|
// }
|
|
|
} |
|
|
} |
|
|
|