|  |  |  | 
|---|
|  |  |  | package cc.mrbird.febs.mall.controller.signActivity; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | import cc.mrbird.febs.common.entity.FebsResponse; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.service.ICommonService; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.dto.MoneyFlowDto; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.dto.signActivity.ApiSignDataDto; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.dto.signActivity.ApiSignListDto; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.service.IScoreService; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.vo.MoneyFlowVo; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.vo.ScoreSignVo; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.vo.signActivity.ApiGetRunDateVo; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.vo.signActivity.ApiSignListVo; | 
|---|
|  |  |  | import cc.mrbird.febs.mall.vo.signActivity.ApiSignVo; | 
|---|
|  |  |  | import io.swagger.annotations.Api; | 
|---|
|  |  |  | import io.swagger.annotations.ApiOperation; | 
|---|
|  |  |  | import io.swagger.annotations.ApiResponse; | 
|---|
|  |  |  | import io.swagger.annotations.ApiResponses; | 
|---|
|  |  |  | import lombok.RequiredArgsConstructor; | 
|---|
|  |  |  | import lombok.extern.slf4j.Slf4j; | 
|---|
|  |  |  | import org.springframework.beans.factory.annotation.Autowired; | 
|---|
|  |  |  | import org.springframework.validation.annotation.Validated; | 
|---|
|  |  |  | import org.springframework.web.bind.annotation.*; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | 
|---|
|  |  |  | @CrossOrigin("*") | 
|---|
|  |  |  | @RequiredArgsConstructor | 
|---|
|  |  |  | @RequestMapping(value = "/api/score") | 
|---|
|  |  |  | @Api(value = "ApiScoreController", tags = "365签到接口类") | 
|---|
|  |  |  | @Api(value = "ApiScoreController", tags = "365签到") | 
|---|
|  |  |  | public class ApiScoreController { | 
|---|
|  |  |  |  | 
|---|
|  |  |  | private final IScoreService scoreService; | 
|---|
|  |  |  | @ApiOperation(value = "积分签到", notes = "积分签到") | 
|---|
|  |  |  | @ApiOperation(value = "积分签到头部", notes = "积分签到头部") | 
|---|
|  |  |  | @ApiResponses({ | 
|---|
|  |  |  | @ApiResponse(code = 200, message = "success", response = ScoreSignVo.class) | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | 
|---|
|  |  |  | return new FebsResponse().success().data(scoreService.scoreSign()); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @ApiOperation(value = "积分签到日历", notes = "积分签到日历") | 
|---|
|  |  |  | @ApiResponses({ | 
|---|
|  |  |  | @ApiResponse(code = 200, message = "success", response = ApiGetRunDateVo.class) | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | @PostMapping(value = "/signData") | 
|---|
|  |  |  | public FebsResponse signData(@RequestBody @Validated ApiSignDataDto dto) { | 
|---|
|  |  |  | return new FebsResponse().success().data(scoreService.signData(dto)); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @ApiOperation(value = "签到", notes = "签到") | 
|---|
|  |  |  | @ApiResponses({ | 
|---|
|  |  |  | @ApiResponse(code = 200, message = "success", response = ApiSignVo.class) | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | @PostMapping(value = "/sign") | 
|---|
|  |  |  | public FebsResponse sign() { | 
|---|
|  |  |  | scoreService.sign(); | 
|---|
|  |  |  | return new FebsResponse().success(); | 
|---|
|  |  |  | return scoreService.sign(); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @ApiOperation(value = "签到记录") | 
|---|
|  |  |  | @ApiResponses({ | 
|---|
|  |  |  | @ApiResponse(code = 200, message = "success", response = ApiSignListVo.class) | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | @PostMapping(value = "/signList") | 
|---|
|  |  |  | public FebsResponse signList(@RequestBody ApiSignListDto dto) { | 
|---|
|  |  |  | return scoreService.signList(dto); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|