Commit dcdd9670 authored by liqin's avatar liqin 💬

bug fixed

parent 4f5b90da
......@@ -223,12 +223,10 @@ public class CopyrightOwnerController extends BaseController {
this.copyrightOwnerService.removeById(id);
final LambdaUpdateWrapper<VideoContent> updateWrapper = Wrappers.<VideoContent>lambdaUpdate().eq(VideoContent::getVideoContentCopyrightOwnerId, id);
updateWrapper.set(VideoContent::getDeleted, true);
this.videoContentService.update(updateWrapper);
this.videoContentService.remove(updateWrapper);
final LambdaUpdateWrapper<ExhibitionBoard> updateWrapper1 = Wrappers.<ExhibitionBoard>lambdaUpdate().eq(ExhibitionBoard::getBoardCopyrightOwnerId, id);
updateWrapper1.set(ExhibitionBoard::getDeleted, true);
this.exhibitionBoardService.update(updateWrapper1);
this.exhibitionBoardService.remove(updateWrapper1);
return getSuccessResult();
}
......
......@@ -192,7 +192,9 @@ public class ExhibitionBoardController extends BaseController {
@PostMapping("/getList")
@RequiresAuthentication //@RequiresPermissions("exhibition:board:list")
@ApiOperation(value = "获取展板全部列表(无分页)", notes = "获取展板全部列表(无分页)")
public Map<String, Object> getExhibitionBoardList(List<String> exhibitionBoardCatIdList, List<String> boardCopyrightOwnerIdList) {
public Map<String, Object> getExhibitionBoardList(
@RequestParam(value = "exhibitionBoardCatIdList", required = false) List<String> exhibitionBoardCatIdList,
@RequestParam(value = "boardCopyrightOwnerIdList", required = false) List<String> boardCopyrightOwnerIdList) {
final LambdaQueryWrapper<ExhibitionBoard> lambdaQueryWrapper = Wrappers.<ExhibitionBoard>lambdaQuery().eq(ExhibitionBoard::getAuditStatus, "APPROVED_FINAL").eq(ExhibitionBoard::getPublished, true);
if (exhibitionBoardCatIdList != null && !exhibitionBoardCatIdList.isEmpty()) {
lambdaQueryWrapper.in(ExhibitionBoard::getExhibitionBoardCatId, exhibitionBoardCatIdList);
......@@ -204,16 +206,28 @@ public class ExhibitionBoardController extends BaseController {
List<ExhibitionBoard> exhibitionBoardList = exhibitionBoardService.list(lambdaQueryWrapper);
for (ExhibitionBoard exhibitionBoard : exhibitionBoardList) {
if (exhibitionBoard.getBoardCopyrightOwnerId() != null) {
String name = this.copyrightOwnerService.getById(exhibitionBoard.getBoardCopyrightOwnerId()).getName();
exhibitionBoard.setBoardCopyrightOwnerName(name);
final CopyrightOwner copyrightOwner = this.copyrightOwnerService.getById(exhibitionBoard.getBoardCopyrightOwnerId());
if (copyrightOwner == null) {
exhibitionBoard.setBoardCopyrightOwnerName("对应的展板版权方已被删除");
} else {
exhibitionBoard.setBoardCopyrightOwnerName(copyrightOwner.getName());
}
}
if (exhibitionBoard.getVideoContentCopyrightOwnerId() != null) {
String name = this.copyrightOwnerService.getById(exhibitionBoard.getVideoContentCopyrightOwnerId()).getName();
exhibitionBoard.setVideoContentCopyrightOwnerName(name);
final CopyrightOwner copyrightOwner = this.copyrightOwnerService.getById(exhibitionBoard.getVideoContentCopyrightOwnerId());
if (copyrightOwner == null) {
exhibitionBoard.setVideoContentCopyrightOwnerName("对应的视频内容版权方已被删除");
} else {
exhibitionBoard.setVideoContentCopyrightOwnerName(copyrightOwner.getName());
}
}
if (exhibitionBoard.getExhibitionBoardCatId() != null) {
String name = this.exhibitionBoardCatService.getById(exhibitionBoard.getExhibitionBoardCatId()).getName();
exhibitionBoard.setExhibitionBoardCatName(name);
final ExhibitionBoardCat exhibitionBoardCat = this.exhibitionBoardCatService.getById(exhibitionBoard.getExhibitionBoardCatId());
if (exhibitionBoardCat == null) {
exhibitionBoard.setExhibitionBoardCatName("对应的展板分类已被删除");
} else {
exhibitionBoard.setExhibitionBoardCatName(exhibitionBoardCat.getName());
}
}
}
return getResult(exhibitionBoardList);
......
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