|
|
@@ -37,6 +37,7 @@ import org.slf4j.LoggerFactory; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.web.bind.annotation.*; |
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.HashMap; |
|
|
|
import java.util.List; |
|
|
|
import java.util.Map; |
|
|
@@ -59,6 +60,15 @@ public class YqzjNewsController extends YqzjBaseController { |
|
|
|
@ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true)}) |
|
|
|
public ResultData list(@ModelAttribute YqzjNews record, Integer pageNum, Integer pageSize) { |
|
|
|
record.setSortColumns(" first desc, update_date desc, send_date desc, create_date desc"); |
|
|
|
if (null != record.getType()) { |
|
|
|
if (EnumYqzjNewsType.YUNYUZHOU.getCode().intValue() == record.getType().intValue()) { |
|
|
|
record.setType(null); |
|
|
|
List<Integer> typeList = new ArrayList<Integer>(); |
|
|
|
typeList.add(EnumYqzjNewsType.YUNYUZHOU_SHENDU.getCode()); |
|
|
|
typeList.add(EnumYqzjNewsType.YUNYUZHOU_ZIXUN.getCode()); |
|
|
|
record.setTypeList(typeList); |
|
|
|
} |
|
|
|
} |
|
|
|
final PageInfo<YqzjNews> page = this.yqzjService.listNewsAsPage(record, pageNum, pageSize); |
|
|
|
return new ResultData(page); |
|
|
|
} |
|
|
|