|
|
|
package com.supervision.controller;
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
|
import com.supervision.model.KgPolicy;
|
|
|
|
import com.supervision.service.KgPolicyService;
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
import io.swagger.annotations.ApiImplicitParam;
|
|
|
|
import io.swagger.annotations.ApiImplicitParams;
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
import org.springframework.web.bind.annotation.GetMapping;
|
|
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
|
|
@Api(tags = "政策法规")
|
|
|
|
@RestController
|
|
|
|
@RequestMapping("policy")
|
|
|
|
@RequiredArgsConstructor
|
|
|
|
public class PolicyController {
|
|
|
|
|
|
|
|
private final KgPolicyService kgPolicyService;
|
|
|
|
|
|
|
|
|
|
|
|
@GetMapping("queryPolicyPage")
|
|
|
|
@ApiImplicitParams({
|
|
|
|
@ApiImplicitParam(name = "keyword", value = "模糊搜索", required = false, dataType = "String", paramType = "query"),
|
|
|
|
@ApiImplicitParam(name = "level", value = "政策层级(1国家级;2省级;3市级;4县级)", required = false, dataType = "String", paramType = "query"),
|
|
|
|
@ApiImplicitParam(name = "subject", value = "主题(1养老退休;2人事人才;3就业创业;4社会保障;5劳动关系)", required = false, dataType = "String", paramType = "query"),
|
|
|
|
@ApiImplicitParam(name = "type", value = "政策类型(1意见;2方案;3通知;4规章;5政策解读)", required = false, dataType = "String", paramType = "query"),
|
|
|
|
@ApiImplicitParam(name = "order", value = "排序方式 默认发文时间降序,1最多收藏降序;2最多浏览降序", required = false, dataType = "Integer", paramType = "query"),
|
|
|
|
@ApiImplicitParam(name = "pageSize", value = "pageSize", required = true, dataType = "Integer", paramType = "query"),
|
|
|
|
@ApiImplicitParam(name = "pageNum", value = "pageNum", required = true, dataType = "Integer", paramType = "query")
|
|
|
|
})
|
|
|
|
public IPage<KgPolicy> queryPolicyPage(String keyword, Integer level, Integer subject, Integer type, Integer order, Integer pageNum, Integer pageSize) {
|
|
|
|
return kgPolicyService.queryPolicyPage(keyword, level, subject, type, order, pageNum, pageSize);
|
|
|
|
}
|
|
|
|
}
|