Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -16,7 +16,7 @@ import javax.validation.constraints.NotBlank;
|
|||||||
*/
|
*/
|
||||||
@Data
|
@Data
|
||||||
@ApiModel
|
@ApiModel
|
||||||
public class AlarmParam {
|
public class AlarmParam extends BaseParam{
|
||||||
|
|
||||||
@NotBlank(message = "起始时间不可为空")
|
@NotBlank(message = "起始时间不可为空")
|
||||||
@DateTimeStrValid
|
@DateTimeStrValid
|
||||||
@@ -45,12 +45,4 @@ public class AlarmParam {
|
|||||||
|
|
||||||
@ApiModelProperty(name = "processTime",value = "处理时间")
|
@ApiModelProperty(name = "processTime",value = "处理时间")
|
||||||
private String processTime;
|
private String processTime;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ApiModelProperty("页码")
|
|
||||||
private Integer pageNum;
|
|
||||||
|
|
||||||
@ApiModelProperty("页面尺寸")
|
|
||||||
private Integer pageSize;
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ import java.time.LocalDateTime;
|
|||||||
public class TerminalAlarmVO implements Serializable {
|
public class TerminalAlarmVO implements Serializable {
|
||||||
|
|
||||||
|
|
||||||
|
// 变电站
|
||||||
private String subName;
|
private String subName;
|
||||||
|
|
||||||
private String lineGrade;
|
private String lineGrade;
|
||||||
|
|||||||
@@ -1,12 +1,10 @@
|
|||||||
package com.njcn.device.pq.controller;
|
package com.njcn.device.pq.controller;
|
||||||
|
|
||||||
import cn.hutool.core.collection.CollectionUtil;
|
|
||||||
import com.njcn.common.pojo.annotation.OperateInfo;
|
import com.njcn.common.pojo.annotation.OperateInfo;
|
||||||
import com.njcn.common.pojo.enums.common.LogEnum;
|
import com.njcn.common.pojo.enums.common.LogEnum;
|
||||||
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||||
import com.njcn.common.pojo.response.HttpResult;
|
import com.njcn.common.pojo.response.HttpResult;
|
||||||
import com.njcn.common.utils.HttpResultUtil;
|
import com.njcn.common.utils.HttpResultUtil;
|
||||||
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
|
||||||
import com.njcn.device.pq.pojo.param.LargeScreenParam;
|
import com.njcn.device.pq.pojo.param.LargeScreenParam;
|
||||||
import com.njcn.device.pq.pojo.vo.MonitoringPointScaleVO;
|
import com.njcn.device.pq.pojo.vo.MonitoringPointScaleVO;
|
||||||
import com.njcn.device.pq.service.LargeScreenService;
|
import com.njcn.device.pq.service.LargeScreenService;
|
||||||
@@ -22,9 +20,6 @@ import org.springframework.web.bind.annotation.RequestBody;
|
|||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Objects;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @version 1.0.0
|
* @version 1.0.0
|
||||||
* @author: zbj
|
* @author: zbj
|
||||||
@@ -44,11 +39,24 @@ public class LargeScreenController extends BaseController {
|
|||||||
*/
|
*/
|
||||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
@PostMapping("/getMonitoringPointScale")
|
@PostMapping("/getMonitoringPointScale")
|
||||||
@ApiOperation("监测点规模")
|
@ApiOperation("监测点规模(区域)")
|
||||||
@ApiImplicitParam(name = "largeScreenParam", value = "查询终端条件", required = true)
|
@ApiImplicitParam(name = "largeScreenParam", value = "监测点规模(区域)", required = true)
|
||||||
public HttpResult<MonitoringPointScaleVO> getMonitoringPointScale(@RequestBody @Validated LargeScreenParam largeScreenParam) {
|
public HttpResult<MonitoringPointScaleVO> getMonitoringPointScale(@RequestBody @Validated LargeScreenParam largeScreenParam) {
|
||||||
String methodDescribe = getMethodDescribe("getMonitoringPointScale");
|
String methodDescribe = getMethodDescribe("getMonitoringPointScale");
|
||||||
MonitoringPointScaleVO result = largeScreenService.getMonitoringPointScale(largeScreenParam);
|
MonitoringPointScaleVO result = largeScreenService.getMonitoringPointScale(largeScreenParam);
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 监测点规模
|
||||||
|
*/
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/getLoadType")
|
||||||
|
@ApiOperation("监测点规模(负荷类型)")
|
||||||
|
@ApiImplicitParam(name = "getLoadType", value = "监测点规模(负荷类型)", required = true)
|
||||||
|
public HttpResult<MonitoringPointScaleVO> getLoadType(@RequestBody @Validated LargeScreenParam largeScreenParam) {
|
||||||
|
String methodDescribe = getMethodDescribe("getLoadType");
|
||||||
|
MonitoringPointScaleVO result = largeScreenService.getLoadType(largeScreenParam);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -64,7 +64,7 @@ FROM
|
|||||||
f.NAME type,
|
f.NAME type,
|
||||||
f.id typeId,
|
f.id typeId,
|
||||||
f.`Level`,
|
f.`Level`,
|
||||||
max( a.Occurred_Time ) occurredTime,
|
max(a.Occurred_Time) occurredTime,
|
||||||
e.NAME subName,
|
e.NAME subName,
|
||||||
b.NAME devLineName,
|
b.NAME devLineName,
|
||||||
b.id devLineId,
|
b.id devLineId,
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
package com.njcn.device.pq.service;
|
package com.njcn.device.pq.service;
|
||||||
|
|
||||||
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
|
||||||
import com.njcn.device.pq.pojo.param.LargeScreenParam;
|
import com.njcn.device.pq.pojo.param.LargeScreenParam;
|
||||||
import com.njcn.device.pq.pojo.vo.MonitoringPointScaleVO;
|
import com.njcn.device.pq.pojo.vo.MonitoringPointScaleVO;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @version 1.0.0
|
* @version 1.0.0
|
||||||
@@ -15,4 +13,5 @@ public interface LargeScreenService {
|
|||||||
|
|
||||||
MonitoringPointScaleVO getMonitoringPointScale(LargeScreenParam largeScreenParam);
|
MonitoringPointScaleVO getMonitoringPointScale(LargeScreenParam largeScreenParam);
|
||||||
|
|
||||||
|
MonitoringPointScaleVO getLoadType(LargeScreenParam largeScreenParam);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,6 @@ package com.njcn.device.pq.service.impl;
|
|||||||
|
|
||||||
import com.njcn.common.pojo.dto.SimpleDTO;
|
import com.njcn.common.pojo.dto.SimpleDTO;
|
||||||
import com.njcn.device.pq.mapper.LargeScreenMapper;
|
import com.njcn.device.pq.mapper.LargeScreenMapper;
|
||||||
import com.njcn.device.pq.mapper.LineIntegrityDataMapper;
|
|
||||||
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
||||||
import com.njcn.device.pq.pojo.param.DeviceInfoParam;
|
import com.njcn.device.pq.pojo.param.DeviceInfoParam;
|
||||||
import com.njcn.device.pq.pojo.param.LargeScreenParam;
|
import com.njcn.device.pq.pojo.param.LargeScreenParam;
|
||||||
@@ -37,7 +36,7 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
private final LargeScreenMapper largeScreenMapper;
|
private final LargeScreenMapper largeScreenMapper;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 监测点规模
|
* 监测点规模(区域)
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public MonitoringPointScaleVO getMonitoringPointScale(LargeScreenParam largeScreenParam) {
|
public MonitoringPointScaleVO getMonitoringPointScale(LargeScreenParam largeScreenParam) {
|
||||||
@@ -49,7 +48,7 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
deviceInfoParam.setDeptIndex(largeScreenParam.getDeptIndex());
|
deviceInfoParam.setDeptIndex(largeScreenParam.getDeptIndex());
|
||||||
//统计类型
|
//统计类型
|
||||||
SimpleDTO simpleDTO = new SimpleDTO();
|
SimpleDTO simpleDTO = new SimpleDTO();
|
||||||
simpleDTO.setName(String.valueOf(StatisticsEnum.POWER_NETWORK));
|
simpleDTO.setCode(String.valueOf(StatisticsEnum.POWER_NETWORK));
|
||||||
deviceInfoParam.setStatisticalType(simpleDTO);
|
deviceInfoParam.setStatisticalType(simpleDTO);
|
||||||
//添加时间
|
//添加时间
|
||||||
deviceInfoParam.setSearchBeginTime(largeScreenParam.getSearchBeginTime());
|
deviceInfoParam.setSearchBeginTime(largeScreenParam.getSearchBeginTime());
|
||||||
@@ -72,4 +71,37 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
result.setMonitorAddCount(count.get("count").toString());
|
result.setMonitorAddCount(count.get("count").toString());
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 监测点规模(负荷类型)
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public MonitoringPointScaleVO getLoadType(LargeScreenParam largeScreenParam) {
|
||||||
|
//创建返回VO
|
||||||
|
MonitoringPointScaleVO result = new MonitoringPointScaleVO();
|
||||||
|
ArrayList<MonitoringPointScaleParam> list = new ArrayList<>();
|
||||||
|
DeviceInfoParam.BusinessParam deviceInfoParam = new DeviceInfoParam.BusinessParam();
|
||||||
|
//部门索引
|
||||||
|
deviceInfoParam.setDeptIndex(largeScreenParam.getDeptIndex());
|
||||||
|
//统计类型
|
||||||
|
SimpleDTO simpleDTO = new SimpleDTO();
|
||||||
|
simpleDTO.setCode(String.valueOf(StatisticsEnum.LOAD_TYPE));
|
||||||
|
deviceInfoParam.setStatisticalType(simpleDTO);
|
||||||
|
//添加时间
|
||||||
|
deviceInfoParam.setSearchBeginTime(largeScreenParam.getSearchBeginTime());
|
||||||
|
deviceInfoParam.setSearchEndTime(largeScreenParam.getSearchEndTime());
|
||||||
|
// 获取所有数据
|
||||||
|
List<GeneralDeviceDTO> generalDeviceDTOList = generalDeviceService.getDeviceInfo(deviceInfoParam, Stream.of(0).collect(Collectors.toList()), Stream.of(1).collect(Collectors.toList()));
|
||||||
|
|
||||||
|
for (GeneralDeviceDTO generalDeviceDTO : generalDeviceDTOList) {
|
||||||
|
MonitoringPointScaleParam param = new MonitoringPointScaleParam();
|
||||||
|
param.setIndex(generalDeviceDTO.getIndex());
|
||||||
|
param.setName(generalDeviceDTO.getName());
|
||||||
|
param.setCount(generalDeviceDTO.getLineIndexes().size());
|
||||||
|
list.add(param);
|
||||||
|
}
|
||||||
|
result.setParam(list);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -401,12 +401,6 @@ public class LineServiceImpl extends ServiceImpl<LineMapper, Line> implements Li
|
|||||||
if (CollectionUtils.isEmpty(deviceIndexes)) {
|
if (CollectionUtils.isEmpty(deviceIndexes)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// 监测点流量统计
|
|
||||||
// deviceList = lineMapper.getNewDeviceRunStatistics(lineIndexes,
|
|
||||||
// DateUtil.beginOfDay(DateUtil.parse(deviceInfoParam.getSearchBeginTime())),
|
|
||||||
// DateUtil.beginOfDay(DateUtil.parse(deviceInfoParam.getSearchEndTime())),
|
|
||||||
// (deviceInfoParam.getPageNum()-1)*deviceInfoParam.getPageSize(),
|
|
||||||
// deviceInfoParam.getPageSize());
|
|
||||||
|
|
||||||
page = lineMapper.getNewDeviceRunStatistics(
|
page = lineMapper.getNewDeviceRunStatistics(
|
||||||
new Page(deviceInfoParam.getPageNum(), deviceInfoParam.getPageSize()),
|
new Page(deviceInfoParam.getPageNum(), deviceInfoParam.getPageSize()),
|
||||||
|
|||||||
@@ -29,19 +29,9 @@ public class TerminalAlarmServiceImpl implements TerminalAlarmService {
|
|||||||
@Override
|
@Override
|
||||||
public Page<TerminalAlarmVO> alarmList(AlarmParam alarmParam) {
|
public Page<TerminalAlarmVO> alarmList(AlarmParam alarmParam) {
|
||||||
|
|
||||||
String sql = "SELECT last(dev_line_type) as dev_line_type,line_id ,type FROM pqs_alarm group by type,line_id,dev_line_type";
|
// String sql = "SELECT last(dev_line_type) as dev_line_type,line_id ,type FROM pqs_alarm group by type,line_id,dev_line_type";
|
||||||
|
Page<TerminalAlarmVO> page = new Page<>(PageFactory.getPageNum(alarmParam),PageFactory.getPageSize(alarmParam));
|
||||||
|
return alarmMapper.getAlarmInfo(page,PubUtils.beginTimeToLocalDateTime(alarmParam.getStartTime()),PubUtils.endTimeToLocalDateTime(alarmParam.getEndTime()),alarmParam.getFlag(),alarmParam.getType(),alarmParam.getAlarmLevel(),alarmParam.getLineGrade());
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//Page<TerminalAlarmVO> page = new Page<>(PageFactory.getPageNum(alarmParam),PageFactory.getPageSize(alarmParam));
|
|
||||||
//return alarmMapper.getAlarmInfo(page,PubUtils.beginTimeToLocalDateTime(alarmParam.getStartTime()),PubUtils.endTimeToLocalDateTime(alarmParam.getEndTime()),alarmParam.getFlag(),alarmParam.getType(),alarmParam.getAlarmLevel(),alarmParam.getLineGrade());
|
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -128,4 +128,7 @@ public class RGeneralSurveyPlanPO {
|
|||||||
@TableField(value = "upload_time")
|
@TableField(value = "upload_time")
|
||||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
private Date uploadTime;
|
private Date uploadTime;
|
||||||
|
@TableField(value = "create_person")
|
||||||
|
private String createPerson;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -158,7 +158,7 @@ public class RGeneralSurveyPlanController extends BaseController {
|
|||||||
public HttpResult<IPage<RGeneralSurveyPlanVO>> queryPlan(@Validated @RequestBody RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm){
|
public HttpResult<IPage<RGeneralSurveyPlanVO>> queryPlan(@Validated @RequestBody RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm){
|
||||||
String methodDescribe = getMethodDescribe("queryPlan");
|
String methodDescribe = getMethodDescribe("queryPlan");
|
||||||
|
|
||||||
IPage<RGeneralSurveyPlanVO> rGeneralSurveyPlanVOS = rGeneralSurveyPlanPOService.query (rGeneralSurveyPlanQueryParm, Stream.of ("0","1","2","3").collect (Collectors.toList ()));
|
IPage<RGeneralSurveyPlanVO> rGeneralSurveyPlanVOS = rGeneralSurveyPlanPOService.query (rGeneralSurveyPlanQueryParm, Stream.of ("0","1","2","3").collect (Collectors.toList ()),"1");
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, rGeneralSurveyPlanVOS, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, rGeneralSurveyPlanVOS, methodDescribe);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -169,7 +169,7 @@ public class RGeneralSurveyPlanController extends BaseController {
|
|||||||
public HttpResult<IPage<RGeneralSurveyPlanVO>> queryPlanAudit(@Validated @RequestBody RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm){
|
public HttpResult<IPage<RGeneralSurveyPlanVO>> queryPlanAudit(@Validated @RequestBody RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm){
|
||||||
String methodDescribe = getMethodDescribe("queryPlanAudit");
|
String methodDescribe = getMethodDescribe("queryPlanAudit");
|
||||||
|
|
||||||
IPage<RGeneralSurveyPlanVO> rGeneralSurveyPlanVOS = rGeneralSurveyPlanPOService.query (rGeneralSurveyPlanQueryParm, Stream.of ("1","2").collect (Collectors.toList ()));
|
IPage<RGeneralSurveyPlanVO> rGeneralSurveyPlanVOS = rGeneralSurveyPlanPOService.query (rGeneralSurveyPlanQueryParm, Stream.of ("1","2").collect (Collectors.toList ()),"2");
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, rGeneralSurveyPlanVOS, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, rGeneralSurveyPlanVOS, methodDescribe);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -191,7 +191,7 @@ public class RGeneralSurveyPlanController extends BaseController {
|
|||||||
public HttpResult<IPage<RGeneralSurveyPlanVO>> queryPlanResult(@Validated @RequestBody RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm){
|
public HttpResult<IPage<RGeneralSurveyPlanVO>> queryPlanResult(@Validated @RequestBody RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm){
|
||||||
String methodDescribe = getMethodDescribe("queryPlanResult");
|
String methodDescribe = getMethodDescribe("queryPlanResult");
|
||||||
|
|
||||||
IPage<RGeneralSurveyPlanVO> rGeneralSurveyPlanVOS = rGeneralSurveyPlanPOService.query (rGeneralSurveyPlanQueryParm, Stream.of ("3","4").collect (Collectors.toList ()));
|
IPage<RGeneralSurveyPlanVO> rGeneralSurveyPlanVOS = rGeneralSurveyPlanPOService.query (rGeneralSurveyPlanQueryParm, Stream.of ("3","4").collect (Collectors.toList ()),"3");
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, rGeneralSurveyPlanVOS, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, rGeneralSurveyPlanVOS, methodDescribe);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ public interface RGeneralSurveyPlanPOService extends IMppService<RGeneralSurveyP
|
|||||||
* @Author: clam
|
* @Author: clam
|
||||||
* @Date: 2022/11/15
|
* @Date: 2022/11/15
|
||||||
*/
|
*/
|
||||||
IPage<RGeneralSurveyPlanVO> query(RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm,List<String> statusList);
|
IPage<RGeneralSurveyPlanVO> query(RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm,List<String> statusList,String type);
|
||||||
/**
|
/**
|
||||||
* @Description: surveyResultUpload
|
* @Description: surveyResultUpload
|
||||||
* @Param: [surveyResultUploadParam]
|
* @Param: [surveyResultUploadParam]
|
||||||
|
|||||||
@@ -34,7 +34,9 @@ import com.njcn.system.api.DicDataFeignClient;
|
|||||||
import com.njcn.system.enums.DicDataTypeEnum;
|
import com.njcn.system.enums.DicDataTypeEnum;
|
||||||
import com.njcn.system.pojo.po.DictData;
|
import com.njcn.system.pojo.po.DictData;
|
||||||
import com.njcn.user.api.DeptFeignClient;
|
import com.njcn.user.api.DeptFeignClient;
|
||||||
|
import com.njcn.user.pojo.po.Dept;
|
||||||
import com.njcn.user.pojo.vo.PvTerminalTreeVO;
|
import com.njcn.user.pojo.vo.PvTerminalTreeVO;
|
||||||
|
import com.njcn.web.utils.RequestUtil;
|
||||||
import org.apache.poi.ss.usermodel.Workbook;
|
import org.apache.poi.ss.usermodel.Workbook;
|
||||||
import org.springframework.beans.BeanUtils;
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
@@ -113,7 +115,11 @@ public class RGeneralSurveyPlanPOServiceImpl extends MppServiceImpl<RGeneralSurv
|
|||||||
RSurveyCyclePO rSurveyCyclePO = rSurveyCycleMapper.selectOne (rSurveyCyclePOQueryWrapper);
|
RSurveyCyclePO rSurveyCyclePO = rSurveyCycleMapper.selectOne (rSurveyCyclePOQueryWrapper);
|
||||||
|
|
||||||
rGeneralSurveyPlanPO.setCycleId (rSurveyCyclePO.getId ( ));
|
rGeneralSurveyPlanPO.setCycleId (rSurveyCyclePO.getId ( ));
|
||||||
boolean b = this.saveOrUpdateByMultiId (rGeneralSurveyPlanPO);
|
String deptIndex = RequestUtil.getDeptIndex ( );
|
||||||
|
Dept data = deptFeignClient.getDeptById (deptIndex).getData ( );
|
||||||
|
rGeneralSurveyPlanPO.setCheckPerson (data.getPid ());
|
||||||
|
rGeneralSurveyPlanPO.setCreatePerson (RequestUtil.getUserIndex ());
|
||||||
|
boolean b = this.saveOrUpdateByMultiId (rGeneralSurveyPlanPO);
|
||||||
|
|
||||||
QueryWrapper<RGeneralSurveyPlanDetail> queryWrapper = new QueryWrapper ( );
|
QueryWrapper<RGeneralSurveyPlanDetail> queryWrapper = new QueryWrapper ( );
|
||||||
queryWrapper.lambda ( ).eq (RGeneralSurveyPlanDetail::getPlanNo, rGeneralSurveyPlanAddParm.getPlanNo ( ));
|
queryWrapper.lambda ( ).eq (RGeneralSurveyPlanDetail::getPlanNo, rGeneralSurveyPlanAddParm.getPlanNo ( ));
|
||||||
@@ -149,11 +155,18 @@ public class RGeneralSurveyPlanPOServiceImpl extends MppServiceImpl<RGeneralSurv
|
|||||||
* @Date: 2022/11/15
|
* @Date: 2022/11/15
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public IPage<RGeneralSurveyPlanVO> query(RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm, List<String> statusList) {
|
public IPage<RGeneralSurveyPlanVO> query(RGeneralSurveyPlanQueryParm rGeneralSurveyPlanQueryParm, List<String> statusList,String type) {
|
||||||
IPage<RGeneralSurveyPlanPO> page = new Page<> (rGeneralSurveyPlanQueryParm.getCurrentPage ( ), rGeneralSurveyPlanQueryParm.getPageSize ( ));
|
IPage<RGeneralSurveyPlanPO> page = new Page<> (rGeneralSurveyPlanQueryParm.getCurrentPage ( ), rGeneralSurveyPlanQueryParm.getPageSize ( ));
|
||||||
IPage<RGeneralSurveyPlanVO> returnpage = new Page<> (rGeneralSurveyPlanQueryParm.getCurrentPage ( ), rGeneralSurveyPlanQueryParm.getPageSize ( ));
|
IPage<RGeneralSurveyPlanVO> returnpage = new Page<> (rGeneralSurveyPlanQueryParm.getCurrentPage ( ), rGeneralSurveyPlanQueryParm.getPageSize ( ));
|
||||||
|
|
||||||
LambdaQueryWrapper<RGeneralSurveyPlanPO> queryWrapper = new LambdaQueryWrapper<> ( );
|
LambdaQueryWrapper<RGeneralSurveyPlanPO> queryWrapper = new LambdaQueryWrapper<> ( );
|
||||||
|
/*type=1:新建页面:查看自己负责的计划;type=2:审核页面:审核者==当前用户;结果页面:查看自己负责的计划*/
|
||||||
|
if(type=="1"||type=="3"){
|
||||||
|
queryWrapper.eq (RGeneralSurveyPlanPO::getCreatePerson,RequestUtil.getUserIndex ());
|
||||||
|
}
|
||||||
|
if(type=="2"){
|
||||||
|
queryWrapper.eq (RGeneralSurveyPlanPO::getCheckPerson,RequestUtil.getDeptIndex ());
|
||||||
|
}
|
||||||
if (!StringUtils.isEmpty (rGeneralSurveyPlanQueryParm.getOrgNo ( ))) {
|
if (!StringUtils.isEmpty (rGeneralSurveyPlanQueryParm.getOrgNo ( ))) {
|
||||||
List<String> data = deptFeignClient.getDepSonIdtByDeptId (rGeneralSurveyPlanQueryParm.getOrgNo ( )).getData ( );
|
List<String> data = deptFeignClient.getDepSonIdtByDeptId (rGeneralSurveyPlanQueryParm.getOrgNo ( )).getData ( );
|
||||||
|
|
||||||
@@ -382,7 +395,7 @@ public class RGeneralSurveyPlanPOServiceImpl extends MppServiceImpl<RGeneralSurv
|
|||||||
UpdateWrapper<RGeneralSurveyPlanPO> updateWrapper = new UpdateWrapper ( );
|
UpdateWrapper<RGeneralSurveyPlanPO> updateWrapper = new UpdateWrapper ( );
|
||||||
updateWrapper.eq ("plan_no", rGeneralSurveyPlanChcekParm.getPlanNo ( ));
|
updateWrapper.eq ("plan_no", rGeneralSurveyPlanChcekParm.getPlanNo ( ));
|
||||||
updateWrapper.set ("check_comment", rGeneralSurveyPlanChcekParm.getCheckComment ( ));
|
updateWrapper.set ("check_comment", rGeneralSurveyPlanChcekParm.getCheckComment ( ));
|
||||||
updateWrapper.set ("check_person", rGeneralSurveyPlanChcekParm.getCheckPerson ( ));
|
// updateWrapper.set ("check_person", rGeneralSurveyPlanChcekParm.getCheckPerson ( ));
|
||||||
updateWrapper.set ("status", Objects.equals ("1", rGeneralSurveyPlanChcekParm.getCheckResult ( )) ? 3 : 2);
|
updateWrapper.set ("status", Objects.equals ("1", rGeneralSurveyPlanChcekParm.getCheckResult ( )) ? 3 : 2);
|
||||||
result = this.update (updateWrapper);
|
result = this.update (updateWrapper);
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
Reference in New Issue
Block a user