|
|
|
@ -16,6 +16,7 @@
|
|
|
|
|
*/ |
|
|
|
|
package com.logpm.basic.controller; |
|
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
|
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
|
|
|
|
import com.logpm.basic.entity.BasicNotice; |
|
|
|
@ -95,7 +96,9 @@ public class BasicNoticeController extends BladeController {
|
|
|
|
|
@ApiOperationSupport(order = 2) |
|
|
|
|
@ApiOperation(value = "分页", notes = "传入notice") |
|
|
|
|
public R<List<BasicNoticeVO>> list() { |
|
|
|
|
List<BasicNotice> list = noticeService.list(); |
|
|
|
|
LambdaQueryWrapper<BasicNotice> lambdaQueryWrapper = new LambdaQueryWrapper<>(); |
|
|
|
|
lambdaQueryWrapper.orderByDesc(BasicNotice::getReleaseTime); |
|
|
|
|
List<BasicNotice> list = noticeService.list(lambdaQueryWrapper); |
|
|
|
|
List<BasicNoticeVO> data = new ArrayList<>(); |
|
|
|
|
for (BasicNotice notice : list) { |
|
|
|
|
BasicNoticeVO vo = BasicNoticeWrapper.build().entityVO(notice); |
|
|
|
|