标准预警 优化名称
This commit is contained in:
+41
@@ -0,0 +1,41 @@
|
||||
package com.adc.da.slrs.sarStandProjectLibrary.controller;
|
||||
|
||||
|
||||
import com.adc.da.http.ResponseMessage;
|
||||
import com.adc.da.http.Result;
|
||||
import com.adc.da.slrs.sarStandProjectLibrary.service.impl.SarStandProjectLibraryServiceImpl;
|
||||
import com.adc.da.slrs.sarStandWarning.entity.EarlyWarningEO;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import com.adc.da.slrs.sarStandProjectLibrary.entity.SarStandProjectLibrary;
|
||||
import io.swagger.annotations.Api;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.adc.da.base.web.BaseController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author ZhangJin
|
||||
* @since 2021-06-15
|
||||
*/
|
||||
@RestController
|
||||
@Api(description = "|SarStandProjectLibrary|")
|
||||
@RequestMapping("/sarStandProjectLibrary/sar-stand-project-library")
|
||||
public class SarStandProjectLibraryController extends BaseController<SarStandProjectLibrary> {
|
||||
@Resource
|
||||
private SarStandProjectLibraryServiceImpl sarStandProjectLibraryService;
|
||||
@GetMapping("/queryMaintenanceProject")
|
||||
@ApiOperation("项目查询")
|
||||
public ResponseMessage queryMaintenanceProject(@RequestParam(defaultValue = "1", value = "newStandPage")int Page, @RequestParam(defaultValue = "10", value = "newStandPageSize") int PageSize) {
|
||||
IPage<SarStandProjectLibrary> list = sarStandProjectLibraryService.queryMaintenanceProject(Page,PageSize);
|
||||
return Result.success("200",list);
|
||||
}
|
||||
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.adc.da.slrs.sarStandProjectLibrary.dao;
|
||||
|
||||
import com.adc.da.slrs.sarStandProjectLibrary.entity.SarStandProjectLibrary;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author ZhangJin
|
||||
* @since 2021-06-15
|
||||
*/
|
||||
public interface SarStandProjectLibraryDao extends BaseMapper<SarStandProjectLibrary> {
|
||||
|
||||
}
|
||||
+66
@@ -0,0 +1,66 @@
|
||||
package com.adc.da.slrs.sarStandProjectLibrary.entity;
|
||||
|
||||
import com.adc.da.base.entity.BaseEntity;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author ZhangJin
|
||||
* @since 2021-06-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Accessors(chain = true)
|
||||
@ApiModel(value="SarStandProjectLibrary对象", description="")
|
||||
public class SarStandProjectLibrary extends BaseEntity {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableId("id")
|
||||
@ApiModelProperty(value = "主键")
|
||||
private String id;
|
||||
|
||||
@ApiModelProperty(value = "产品平台")
|
||||
private String projectPlatfor;
|
||||
|
||||
@ApiModelProperty(value = "项目编号")
|
||||
private String projectNumber;
|
||||
|
||||
@ApiModelProperty(value = "项目名称")
|
||||
private String projectName;
|
||||
|
||||
@ApiModelProperty(value = "项目分类")
|
||||
private String projectClassification;
|
||||
|
||||
@ApiModelProperty(value = "项目状态")
|
||||
private String projectStatus;
|
||||
|
||||
@ApiModelProperty(value = "项目群")
|
||||
private String projectGroup;
|
||||
|
||||
@ApiModelProperty(value = "项目开始日期")
|
||||
private Date projectStartDate;
|
||||
|
||||
@ApiModelProperty(value = "项目完成日期")
|
||||
private Date projectEndDate;
|
||||
|
||||
@ApiModelProperty(value = "当前节点")
|
||||
private String currentNode;
|
||||
|
||||
@ApiModelProperty(value = "项目级别")
|
||||
private String projectLevel;
|
||||
|
||||
private String projectManager;
|
||||
|
||||
|
||||
}
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
package com.adc.da.slrs.sarStandProjectLibrary.service.impl;
|
||||
|
||||
import com.adc.da.slrs.sarStandProjectLibrary.entity.SarStandProjectLibrary;
|
||||
import com.adc.da.slrs.sarStandProjectLibrary.dao.SarStandProjectLibraryDao;
|
||||
import com.adc.da.slrs.sarStandProjectLibrary.service.ISarStandProjectLibraryService;
|
||||
import com.adc.da.slrs.sarStandWarning.entity.EarlyWarningEO;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author ZhangJin
|
||||
* @since 2021-06-15
|
||||
*/
|
||||
@Service
|
||||
public class SarStandProjectLibraryServiceImpl extends ServiceImpl<SarStandProjectLibraryDao, SarStandProjectLibrary> implements ISarStandProjectLibraryService {
|
||||
@Resource
|
||||
private SarStandProjectLibraryDao sarStandProjectLibraryDao;
|
||||
@Override
|
||||
public IPage<SarStandProjectLibrary> queryMaintenanceProject(int current,int pageSize) {
|
||||
QueryWrapper<SarStandProjectLibrary> wrapper= new QueryWrapper<>();
|
||||
wrapper.inSql("id", "select project_id from sar_stand_project_relation");
|
||||
Page<SarStandProjectLibrary> page = new Page<>(current, pageSize);
|
||||
IPage<SarStandProjectLibrary> userIPage = sarStandProjectLibraryDao.selectPage(page, wrapper);
|
||||
System.out.println("总条数"+userIPage.getTotal());
|
||||
System.out.println("总页数"+userIPage.getPages());
|
||||
return userIPage;
|
||||
}
|
||||
}
|
||||
+32
-3
@@ -27,7 +27,21 @@ import java.util.Map;
|
||||
public class EarlyWarningEOController extends BaseController<EarlyWarningEO> {
|
||||
@Resource
|
||||
private EarlyWarningEOServiceImpl earlyWarningEOService;
|
||||
|
||||
/**
|
||||
*
|
||||
* @param newStandPage
|
||||
* @param newStandPageSize
|
||||
* @param oldStandPage
|
||||
* @param oldStandPageSize
|
||||
* @param newItemsPage
|
||||
* @param newItemsPageSize
|
||||
* @param oldItemsPage
|
||||
* @param oldItemsPageSize
|
||||
* @param applyType
|
||||
* @return
|
||||
* @author zj
|
||||
* date 2021-06-15
|
||||
**/
|
||||
@GetMapping("/StandWarning")
|
||||
@ApiOperation("标准预警查询")
|
||||
public ResponseMessage newPageInfo(@RequestParam(defaultValue = "1", value = "newStandPage")int newStandPage, @RequestParam(defaultValue = "10", value = "newStandPageSize") int newStandPageSize,
|
||||
@@ -50,14 +64,29 @@ public class EarlyWarningEOController extends BaseController<EarlyWarningEO> {
|
||||
listMap .add(map);
|
||||
return Result.success("200",listMap);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
* @author zj
|
||||
* date 2021-06-15
|
||||
**/
|
||||
@GetMapping("/ChangePermissions")
|
||||
@ApiOperation("更改权限")
|
||||
public ResponseMessage ChangePermissions(String id) {
|
||||
String power = earlyWarningEOService.ChangePermissions(id);
|
||||
return Result.success("200",power);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param newPolicyPage
|
||||
* @param newPolicyPageSize
|
||||
* @param oldPolicyPage
|
||||
* @param oldPolicyPageSize
|
||||
* @return
|
||||
* @author zj
|
||||
* date 2021-06-15
|
||||
**/
|
||||
@GetMapping("/PolicyWarning")
|
||||
@ApiOperation("政策预警查询")
|
||||
public ResponseMessage newPolicyPageInfo(@RequestParam(defaultValue = "1", value = "newPolicyPage")int newPolicyPage, @RequestParam(defaultValue = "10", value = "newPolicyPageSize") int newPolicyPageSize,
|
||||
|
||||
Reference in New Issue
Block a user