| | |
| | | import com.ruoyi.common.security.utils.SecurityUtils; |
| | | import com.ruoyi.system.api.domain.dto.MgtBaseGetDto; |
| | | import com.ruoyi.system.api.domain.dto.MgtPageDto; |
| | | import com.ruoyi.system.api.domain.vo.MgtBulletinBoardVo; |
| | | import com.ruoyi.system.domain.dto.*; |
| | | import com.ruoyi.system.domain.vo.*; |
| | | import com.ruoyi.system.service.config.*; |
| | |
| | | |
| | | @Resource |
| | | private RegionService regionService; |
| | | |
| | | @Resource |
| | | private RecommendCooperationService recommendCooperationService; |
| | | |
| | | |
| | | @RequestMapping(value = "/getCustomConfig", method = RequestMethod.POST) |
| | |
| | | List<RegionVo> regionVoList = regionService.listRegionVo(); |
| | | return R.ok(regionVoList); |
| | | } |
| | | |
| | | @RequestMapping(value = "/pageAllotRecommend", method = RequestMethod.POST) |
| | | @ApiOperation(value = "分页获取推荐分配列表") |
| | | public R<Page<MgtAllotRecommendPageVo>> pageAllotRecommend(@RequestBody MgtAllotRecommendPageDto mgtAllotRecommendPageDto) { |
| | | Long userId = SecurityUtils.getUserId(); |
| | | mgtAllotRecommendPageDto.setUserId(userId); |
| | | Page<MgtAllotRecommendPageVo> page = new Page<>(); |
| | | page.setSize(mgtAllotRecommendPageDto.getPageSize()); |
| | | page.setCurrent(mgtAllotRecommendPageDto.getPageNum()); |
| | | List<MgtAllotRecommendPageVo> allotRecommendPageVoList = recommendCooperationService.pageAllotRecommend(page, mgtAllotRecommendPageDto); |
| | | return R.ok(page.setRecords(allotRecommendPageVoList)); |
| | | } |
| | | |
| | | @RequestMapping(value = "/allotRecommend", method = RequestMethod.POST) |
| | | @ApiOperation(value = "删除文章") |
| | | public R allotRecommend(@RequestBody MgtAllotRecommendDto mgtAllotRecommendDto) { |
| | | mgtAllotRecommendDto.setUserId(SecurityUtils.getUserId()); |
| | | recommendCooperationService.allotRecommend(mgtAllotRecommendDto); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @RequestMapping(value = "/getBulletinBoard", method = RequestMethod.POST) |
| | | @ApiOperation(value = "获取看板统计") |
| | | public R<MgtBulletinBoardVo> getBulletinBoard() { |
| | | Long userId = SecurityUtils.getUserId(); |
| | | MgtBulletinBoardVo bulletinBoard = customConfigService.getBulletinBoard(); |
| | | return R.ok(bulletinBoard); |
| | | } |
| | | } |