yang_shj
2 years ago
63 changed files with 1815 additions and 71 deletions
@ -0,0 +1,33 @@
|
||||
package com.hnac.hzims.operational.alert.entity; |
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import lombok.EqualsAndHashCode; |
||||
import org.springblade.core.mp.base.BaseEntity; |
||||
|
||||
@Data |
||||
@TableName("hzims_alarm_handle_detail") |
||||
@EqualsAndHashCode(callSuper = true) |
||||
@ApiModel(value = "告警处理详情对象") |
||||
public class AlarmHandleDetailEntity extends BaseEntity { |
||||
|
||||
@ApiModelProperty("现象ID") |
||||
private Long phenomenonId; |
||||
|
||||
@ApiModelProperty("检修ID") |
||||
private Long accessId; |
||||
|
||||
@ApiModelProperty("延后时间") |
||||
private Long delayTime; |
||||
|
||||
@ApiModelProperty("延后原因") |
||||
private Long delayCause; |
||||
|
||||
@ApiModelProperty("误报描述") |
||||
private Long falseAlarmDesc; |
||||
|
||||
@ApiModelProperty("附件路径") |
||||
private Long filePath; |
||||
} |
@ -0,0 +1,35 @@
|
||||
package com.hnac.hzims.operational.alert.entity; |
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import lombok.EqualsAndHashCode; |
||||
import org.springblade.core.mp.base.BaseEntity; |
||||
|
||||
import java.util.Date; |
||||
|
||||
@Data |
||||
@TableName("hzims_alarm_handle") |
||||
@EqualsAndHashCode(callSuper = true) |
||||
@ApiModel(value = "告警处理对象") |
||||
public class AlarmHandleEntity extends BaseEntity { |
||||
|
||||
@ApiModelProperty("站点编码") |
||||
private String stationCode; |
||||
|
||||
@ApiModelProperty("告警类型") |
||||
private Long alarmType; |
||||
|
||||
@ApiModelProperty("告警时间") |
||||
private Date alarmTime; |
||||
|
||||
@ApiModelProperty("告警内容") |
||||
private String alarmContent; |
||||
|
||||
@ApiModelProperty("处理方式") |
||||
private String handleWay; |
||||
|
||||
@ApiModelProperty("处理详情ID") |
||||
private String detailId; |
||||
} |
@ -0,0 +1,22 @@
|
||||
package com.hnac.hzims.operational.census.vo; |
||||
|
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/02/23 13:37:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Data |
||||
public class DeviceClassifyVo { |
||||
|
||||
@ApiModelProperty("站点名称") |
||||
private String stationName; |
||||
|
||||
@ApiModelProperty("设备名称") |
||||
private String deviceName; |
||||
|
||||
@ApiModelProperty("设备状态") |
||||
private String deviceStatus; |
||||
} |
@ -0,0 +1,44 @@
|
||||
package com.hnac.hzims.operational.fill.entity; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
import org.springframework.format.annotation.DateTimeFormat; |
||||
|
||||
import java.io.Serializable; |
||||
import java.util.Date; |
||||
|
||||
|
||||
@Data |
||||
@TableName("hzims_fill_inset_power") |
||||
@ApiModel(value="InsetPowerEntity对象", description="接入电站历史发电量填报") |
||||
public class InsertPowerEntity extends TenantEntity implements Serializable { |
||||
|
||||
@ApiModelProperty("开始工作日期") |
||||
@DateTimeFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
@JsonFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
private Date startDate; |
||||
|
||||
@ApiModelProperty("结束工作日期") |
||||
@DateTimeFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
@JsonFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
private Date endDate; |
||||
|
||||
@ApiModelProperty("FA_投入条数") |
||||
private Integer faQuantity; |
||||
|
||||
@ApiModelProperty("设备在线率") |
||||
private String onlineRate; |
||||
} |
@ -0,0 +1,44 @@
|
||||
package com.hnac.hzims.operational.fill.entity; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
import org.springframework.format.annotation.DateTimeFormat; |
||||
|
||||
import java.io.Serializable; |
||||
import java.util.Date; |
||||
|
||||
|
||||
@Data |
||||
@TableName("hzims_fill_inset_use") |
||||
@ApiModel(value="InsertUseEntity对象", description="接入电站历史发电量填报") |
||||
public class InsertUseEntity extends TenantEntity implements Serializable { |
||||
|
||||
@ApiModelProperty("开始工作日期") |
||||
@DateTimeFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
@JsonFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
private Date startDate; |
||||
|
||||
@ApiModelProperty("结束工作日期") |
||||
@DateTimeFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
@JsonFormat( |
||||
pattern = "yyyy-MM-dd" |
||||
) |
||||
private Date endDate; |
||||
|
||||
@ApiModelProperty("FA_投入条数") |
||||
private Integer faQuantity; |
||||
|
||||
@ApiModelProperty("设备在线率") |
||||
private String onlineRate; |
||||
} |
@ -0,0 +1,33 @@
|
||||
package com.hnac.hzims.operational.fill.entity; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
import org.springframework.format.annotation.DateTimeFormat; |
||||
|
||||
import java.io.Serializable; |
||||
import java.math.BigDecimal; |
||||
import java.util.Date; |
||||
|
||||
|
||||
@Data |
||||
@TableName("hzims_fill_notinset_power") |
||||
@ApiModel(value="NotInsetPowerEntity对象", description="未接入电站历史发电量填报") |
||||
public class NotInsertPowerEntity extends TenantEntity implements Serializable { |
||||
|
||||
@ApiModelProperty("站点编号") |
||||
private String stationCode; |
||||
|
||||
@ApiModelProperty("站点名称") |
||||
private String stationName; |
||||
|
||||
@ApiModelProperty("发电量") |
||||
private BigDecimal power; |
||||
|
||||
@ApiModelProperty("填报日期") |
||||
private Date fillDate; |
||||
} |
@ -0,0 +1,33 @@
|
||||
package com.hnac.hzims.operational.fill.entity; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
import org.springframework.format.annotation.DateTimeFormat; |
||||
|
||||
import java.io.Serializable; |
||||
import java.math.BigDecimal; |
||||
import java.util.Date; |
||||
|
||||
|
||||
@Data |
||||
@TableName("hzims_fill_notinset_use") |
||||
@ApiModel(value="NotInsertUseEntity对象", description="未接入泵站用电量填报") |
||||
public class NotInsertUseEntity extends TenantEntity implements Serializable { |
||||
|
||||
@ApiModelProperty("站点编号") |
||||
private String stationCode; |
||||
|
||||
@ApiModelProperty("站点名称") |
||||
private String stationName; |
||||
|
||||
@ApiModelProperty("用电量") |
||||
private BigDecimal use; |
||||
|
||||
@ApiModelProperty("填报日期") |
||||
private Date fillDate; |
||||
} |
@ -0,0 +1,33 @@
|
||||
package com.hnac.hzims.operational.fill.entity; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
import org.springframework.format.annotation.DateTimeFormat; |
||||
|
||||
import java.io.Serializable; |
||||
import java.math.BigDecimal; |
||||
import java.util.Date; |
||||
|
||||
|
||||
@Data |
||||
@TableName("hzims_fill_rainfall") |
||||
@ApiModel(value="RainfallEntity", description="水利降雨量填报") |
||||
public class RainfallEntity extends TenantEntity implements Serializable { |
||||
|
||||
@ApiModelProperty("站点编号") |
||||
private String stationCode; |
||||
|
||||
@ApiModelProperty("站点名称") |
||||
private String stationName; |
||||
|
||||
@ApiModelProperty("发电量") |
||||
private BigDecimal rain; |
||||
|
||||
@ApiModelProperty("填报日期") |
||||
private Date fillDate; |
||||
} |
@ -0,0 +1,32 @@
|
||||
package com.hnac.hzims.operational.fill.entity; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
|
||||
import java.io.Serializable; |
||||
import java.math.BigDecimal; |
||||
import java.util.Date; |
||||
|
||||
|
||||
@Data |
||||
@TableName("hzims_fill_storage") |
||||
@ApiModel(value="StorageEntity", description="储能站发电量对象") |
||||
public class StorageEntity extends TenantEntity implements Serializable { |
||||
|
||||
@ApiModelProperty("站点编号") |
||||
private String stationCode; |
||||
|
||||
@ApiModelProperty("站点名称") |
||||
private String stationName; |
||||
|
||||
@ApiModelProperty("发电量") |
||||
private BigDecimal power; |
||||
|
||||
@ApiModelProperty("填报日期") |
||||
private Date fillDate; |
||||
|
||||
} |
@ -0,0 +1,22 @@
|
||||
package com.hnac.hzims.operational.fill.vo; |
||||
|
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
|
||||
import java.util.Date; |
||||
|
||||
@Data |
||||
public class QueryVo{ |
||||
|
||||
@ApiModelProperty("站点编号") |
||||
private String stationCode; |
||||
|
||||
@ApiModelProperty("开始时间") |
||||
private Date startTime; |
||||
|
||||
@ApiModelProperty("结束时间") |
||||
private Date endTime; |
||||
|
||||
@ApiModelProperty("设备编号") |
||||
private String deviceCode; |
||||
} |
@ -0,0 +1,77 @@
|
||||
package com.hnac.hzims.operational.alert.controller; |
||||
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleEntity; |
||||
import com.hnac.hzims.operational.alert.service.AlarmHandleService; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:19:13 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Api(tags = {"告警处理"}) |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/alarm/handle") |
||||
public class AlarmHandleController extends BladeController { |
||||
|
||||
private final AlarmHandleService service; |
||||
|
||||
|
||||
/** |
||||
* 详情 |
||||
*/ |
||||
@GetMapping("/detail") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "详情", notes = "传入AlarmHandleEntity") |
||||
public R<AlarmHandleEntity> detail(AlarmHandleEntity entity) { |
||||
AlarmHandleEntity detail = service.getOne(Condition.getQueryWrapper(entity)); |
||||
return R.data(detail); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*/ |
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "分页", notes = "传入AlarmHandleEntity") |
||||
public R<IPage<AlarmHandleEntity>> list(AlarmHandleEntity entity, Query query) { |
||||
IPage<AlarmHandleEntity> pages = service.page(Condition.getPage(query), Condition.getQueryWrapper(entity)); |
||||
return R.data(pages); |
||||
} |
||||
|
||||
/** |
||||
* 新增或修改 |
||||
*/ |
||||
@PostMapping("/submit") |
||||
@ApiOperationSupport(order = 3) |
||||
@ApiOperation(value = "新增或修改", notes = "传入AlarmHandleEntity") |
||||
public R submit(@Valid @RequestBody AlarmHandleEntity entity) { |
||||
return R.status(service.saveOrUpdate(entity)); |
||||
} |
||||
|
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入ids") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
} |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.alert.mapper; |
||||
|
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleDetailEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:19:13 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface AlarmHandleDetailMapper extends UserDataScopeBaseMapper<AlarmHandleDetailEntity> { |
||||
|
||||
} |
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
<mapper namespace="com.hnac.hzims.operational.alert.mapper.AlarmHandleDetailMapper"> |
||||
|
||||
|
||||
</mapper> |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.alert.mapper; |
||||
|
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:19:13 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface AlarmHandleMapper extends UserDataScopeBaseMapper<AlarmHandleEntity> { |
||||
|
||||
} |
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
<mapper namespace="com.hnac.hzims.operational.alert.mapper.AlarmHandleMapper"> |
||||
|
||||
|
||||
</mapper> |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.alert.service; |
||||
|
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleDetailEntity; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:19:13 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface AlarmHandleDetailService extends BaseService<AlarmHandleDetailEntity> { |
||||
|
||||
} |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.alert.service; |
||||
|
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleEntity; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:19:13 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface AlarmHandleService extends BaseService<AlarmHandleEntity> { |
||||
|
||||
} |
@ -0,0 +1,21 @@
|
||||
package com.hnac.hzims.operational.alert.service.impl; |
||||
|
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleDetailEntity; |
||||
import com.hnac.hzims.operational.alert.mapper.AlarmHandleDetailMapper; |
||||
import com.hnac.hzims.operational.alert.service.AlarmHandleDetailService; |
||||
import lombok.RequiredArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:29:34 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@RequiredArgsConstructor |
||||
public class AlarmHandleDetailServiceImpl extends BaseServiceImpl<AlarmHandleDetailMapper, AlarmHandleDetailEntity> implements AlarmHandleDetailService { |
||||
|
||||
} |
@ -0,0 +1,21 @@
|
||||
package com.hnac.hzims.operational.alert.service.impl; |
||||
|
||||
import com.hnac.hzims.operational.alert.entity.AlarmHandleEntity; |
||||
import com.hnac.hzims.operational.alert.mapper.AlarmHandleMapper; |
||||
import com.hnac.hzims.operational.alert.service.AlarmHandleService; |
||||
import lombok.RequiredArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 09:29:34 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@RequiredArgsConstructor |
||||
public class AlarmHandleServiceImpl extends BaseServiceImpl<AlarmHandleMapper, AlarmHandleEntity> implements AlarmHandleService { |
||||
|
||||
} |
@ -0,0 +1,74 @@
|
||||
package com.hnac.hzims.operational.fill.controller; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.fill.entity.InsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.entity.OtherEntity; |
||||
import com.hnac.hzims.operational.fill.service.InsertPowerService; |
||||
import com.hnac.hzims.operational.fill.service.OtherService; |
||||
import com.hnac.hzims.operational.fill.vo.OtherVo; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/insert/power") |
||||
@Api(value = "接入电站填报", tags = "接入电站历史发电量填报") |
||||
public class InsertPowerController extends BladeController { |
||||
|
||||
private final InsertPowerService service; |
||||
|
||||
/** |
||||
* 新增 |
||||
*/ |
||||
@PostMapping("/save") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "新增", notes = "传入InsertPowerEntity对象") |
||||
public R save(@RequestBody InsertPowerEntity entity) { |
||||
return R.status(service.save(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入id字符串以逗号分隔") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
/** |
||||
* 修改 |
||||
*/ |
||||
@PostMapping("/update") |
||||
@ApiOperationSupport(order = 3) |
||||
@ApiOperation(value = "修改") |
||||
public R update(@Valid @RequestBody InsertPowerEntity entity) { |
||||
return R.status(service.updateById(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*//*
|
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "分页", notes = "查询条件:createDept,fileName,startTime,endTime") |
||||
public R<IPage<OtherVo>> list(OtherVo vo, Query query) { |
||||
return service.pageCondition(vo, query); |
||||
}*/ |
||||
} |
@ -0,0 +1,69 @@
|
||||
package com.hnac.hzims.operational.fill.controller; |
||||
|
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.fill.entity.InsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.service.InsertPowerService; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/insert/use") |
||||
@Api(value = "接入泵站用电量填报", tags = "接入泵站用电量填报") |
||||
public class InsertUseController extends BladeController { |
||||
|
||||
private final InsertPowerService service; |
||||
|
||||
/** |
||||
* 新增 |
||||
*/ |
||||
@PostMapping("/save") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "新增", notes = "传入InsertPowerEntity对象") |
||||
public R save(@RequestBody InsertPowerEntity entity) { |
||||
return R.status(service.save(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入id字符串以逗号分隔") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
/** |
||||
* 修改 |
||||
*/ |
||||
@PostMapping("/update") |
||||
@ApiOperationSupport(order = 3) |
||||
@ApiOperation(value = "修改") |
||||
public R update(@Valid @RequestBody InsertPowerEntity entity) { |
||||
return R.status(service.updateById(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*//*
|
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "分页", notes = "查询条件:createDept,fileName,startTime,endTime") |
||||
public R<IPage<OtherVo>> list(OtherVo vo, Query query) { |
||||
return service.pageCondition(vo, query); |
||||
}*/ |
||||
} |
@ -0,0 +1,63 @@
|
||||
package com.hnac.hzims.operational.fill.controller; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.fill.entity.NotInsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.service.NotInsertPowerService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/notInsert/power") |
||||
@Api(value = "未接入电站填报", tags = "未接入电站历史发电量填报") |
||||
public class NotInsertPowerController extends BladeController { |
||||
|
||||
private final NotInsertPowerService service; |
||||
|
||||
/** |
||||
* 新增 |
||||
*/ |
||||
@PostMapping("/saveOrUpdate") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "新增", notes = "传入InsertPowerEntity对象") |
||||
public R saveOrUpdate(@RequestBody NotInsertPowerEntity entity) { |
||||
return R.status(service.saveUpdate(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入id字符串以逗号分隔") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*/ |
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "分页", notes = "查询条件::startTime,endTime,stationCode") |
||||
public R<IPage<NotInsertPowerEntity>> list(QueryVo filter, Query query) { |
||||
return service.pageCondition(filter, query); |
||||
} |
||||
} |
@ -0,0 +1,63 @@
|
||||
package com.hnac.hzims.operational.fill.controller; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.fill.entity.NotInsertUseEntity; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.service.NotInsertUseService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/notInsert/use") |
||||
@Api(value = "未接入泵站历史用电量填报", tags = "未接入泵站历史用电量填报") |
||||
public class NotInsertUseController extends BladeController { |
||||
|
||||
private final NotInsertUseService service; |
||||
|
||||
/** |
||||
* 新增 |
||||
*/ |
||||
@PostMapping("/saveOrUpdate") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "新增", notes = "传入InsertPowerEntity对象") |
||||
public R saveOrUpdate(@RequestBody NotInsertUseEntity entity) { |
||||
return R.status(service.saveUpdate(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入id字符串以逗号分隔") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*/ |
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "分页", notes = "查询条件::startTime,endTime,stationCode") |
||||
public R<IPage<NotInsertUseEntity>> list(QueryVo filter, Query query) { |
||||
return service.pageCondition(filter, query); |
||||
} |
||||
} |
@ -0,0 +1,62 @@
|
||||
package com.hnac.hzims.operational.fill.controller; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import org.springblade.core.mp.support.Query; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.service.RainfallService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/rainfall") |
||||
@Api(value = "水利降雨量填报", tags = "接入泵站用电量填报") |
||||
public class RainfallController extends BladeController { |
||||
|
||||
private final RainfallService service; |
||||
|
||||
/** |
||||
* 新增 |
||||
*/ |
||||
@PostMapping("/saveOrUpdate") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "新增", notes = "传入InsertPowerEntity对象") |
||||
public R saveOrUpdate(@RequestBody RainfallEntity entity) { |
||||
return R.status(service.saveUpdate(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入id字符串以逗号分隔") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*/ |
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "分页", notes = "查询条件::startTime,endTime,stationCode") |
||||
public R<IPage<RainfallEntity>> list(QueryVo filter, Query query) { |
||||
return service.pageCondition(filter, query); |
||||
} |
||||
} |
@ -0,0 +1,62 @@
|
||||
package com.hnac.hzims.operational.fill.controller; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.operational.fill.entity.StorageEntity; |
||||
import com.hnac.hzims.operational.fill.service.StorageService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.web.bind.annotation.*; |
||||
|
||||
import javax.validation.Valid; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/rainfall") |
||||
@Api(value = "水利降雨量填报", tags = "接入泵站用电量填报") |
||||
public class StorageController extends BladeController { |
||||
|
||||
private final StorageService service; |
||||
|
||||
/** |
||||
* 新增 |
||||
*/ |
||||
@PostMapping("/saveOrUpdate") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "新增", notes = "传入InsertPowerEntity对象") |
||||
public R saveOrUpdate(@RequestBody StorageEntity entity) { |
||||
return R.status(service.saveUpdate(entity)); |
||||
} |
||||
|
||||
/** |
||||
* 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入id字符串以逗号分隔") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(service.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
/** |
||||
* 分页 |
||||
*/ |
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "分页", notes = "查询条件:startTime,endTime,stationCode") |
||||
public R<IPage<StorageEntity>> list(QueryVo vo, Query query) { |
||||
return service.pageCondition(vo, query); |
||||
} |
||||
} |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.fill.mapper; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.InsertPowerEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface InsertPowerMapper extends UserDataScopeBaseMapper<InsertPowerEntity> { |
||||
|
||||
} |
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
||||
<mapper namespace="com.hnac.hzims.operational.fill.mapper.InsertPowerMapper"> |
||||
|
||||
</mapper> |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.fill.mapper; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.InsertUseEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface InsertUseMapper extends UserDataScopeBaseMapper<InsertUseEntity> { |
||||
|
||||
} |
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
||||
<mapper namespace="com.hnac.hzims.operational.fill.mapper.InsertUseMapper"> |
||||
|
||||
</mapper> |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.fill.mapper; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.NotInsertPowerEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface NotInsertPowerMapper extends UserDataScopeBaseMapper<NotInsertPowerEntity> { |
||||
|
||||
} |
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
||||
<mapper namespace="com.hnac.hzims.operational.fill.mapper.NotInsertPowerMapper"> |
||||
|
||||
</mapper> |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.fill.mapper; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.NotInsertUseEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface NotInsertUseMapper extends UserDataScopeBaseMapper<NotInsertUseEntity> { |
||||
|
||||
} |
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
||||
<mapper namespace="com.hnac.hzims.operational.fill.mapper.NotInsertUseMapper"> |
||||
|
||||
</mapper> |
@ -0,0 +1,13 @@
|
||||
package com.hnac.hzims.operational.fill.mapper; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface RainfallMapper extends UserDataScopeBaseMapper<RainfallEntity> { |
||||
|
||||
} |
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
||||
<mapper namespace="com.hnac.hzims.operational.fill.mapper.RainfallMapper"> |
||||
</mapper> |
@ -0,0 +1,14 @@
|
||||
package com.hnac.hzims.operational.fill.mapper; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.entity.StorageEntity; |
||||
import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
public interface StorageMapper extends UserDataScopeBaseMapper<StorageEntity> { |
||||
|
||||
} |
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
||||
<mapper namespace="com.hnac.hzims.operational.fill.mapper.StorageMapper"> |
||||
</mapper> |
@ -0,0 +1,17 @@
|
||||
package com.hnac.hzims.operational.fill.service; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.InsertPowerEntity; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
/** |
||||
* 接入电站历史发电量填报 |
||||
*/ |
||||
public interface InsertPowerService extends BaseService<InsertPowerEntity> { |
||||
|
||||
|
||||
} |
@ -0,0 +1,18 @@
|
||||
package com.hnac.hzims.operational.fill.service; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.InsertUseEntity; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
|
||||
/** |
||||
* 接入电站历史发电量填报 |
||||
*/ |
||||
public interface InsertUseService extends BaseService<InsertUseEntity> { |
||||
|
||||
|
||||
} |
@ -0,0 +1,28 @@
|
||||
package com.hnac.hzims.operational.fill.service; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.InsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.entity.NotInsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
|
||||
/** |
||||
* 接入电站历史发电量填报 |
||||
*/ |
||||
public interface NotInsertPowerService extends BaseService<NotInsertPowerEntity> { |
||||
|
||||
|
||||
// 新增/修改未接入电站发电量填报数据
|
||||
boolean saveUpdate(NotInsertPowerEntity entity); |
||||
|
||||
// 分页查询未接入电站发电量填报数据
|
||||
R<IPage<NotInsertPowerEntity>> pageCondition(QueryVo filter, Query query); |
||||
} |
@ -0,0 +1,26 @@
|
||||
package com.hnac.hzims.operational.fill.service; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.NotInsertUseEntity; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
|
||||
/** |
||||
* 接入电站历史发电量填报 |
||||
*/ |
||||
public interface NotInsertUseService extends BaseService<NotInsertUseEntity> { |
||||
|
||||
// 新增/修改未接入泵站用电量填报数据
|
||||
boolean saveUpdate(NotInsertUseEntity entity); |
||||
|
||||
// 分页查询未接入泵站用电量填报数据
|
||||
R<IPage<NotInsertUseEntity>> pageCondition(QueryVo filter, Query query); |
||||
} |
@ -0,0 +1,26 @@
|
||||
package com.hnac.hzims.operational.fill.service; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
|
||||
/** |
||||
* 接入电站历史发电量填报 |
||||
*/ |
||||
public interface RainfallService extends BaseService<RainfallEntity> { |
||||
|
||||
// 分页查询水利降雨量填报数据
|
||||
R<IPage<RainfallEntity>> pageCondition(QueryVo filter, Query query); |
||||
|
||||
// 新增/修改水利降雨量填报数据
|
||||
boolean saveUpdate(RainfallEntity entity); |
||||
} |
@ -0,0 +1,26 @@
|
||||
package com.hnac.hzims.operational.fill.service; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.StorageEntity; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
|
||||
/** |
||||
* 接入电站历史发电量填报 |
||||
*/ |
||||
public interface StorageService extends BaseService<StorageEntity> { |
||||
|
||||
// 分页查询储能发电填报数据
|
||||
R<IPage<StorageEntity>> pageCondition(QueryVo vo, Query query); |
||||
|
||||
// 新增/修改储能发电量填报
|
||||
boolean saveUpdate(StorageEntity entity); |
||||
} |
@ -0,0 +1,22 @@
|
||||
package com.hnac.hzims.operational.fill.service.impl; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.InsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.mapper.InsertPowerMapper; |
||||
import com.hnac.hzims.operational.fill.service.InsertPowerService; |
||||
import lombok.AllArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@AllArgsConstructor |
||||
public class InsertPowerServiceImpl extends BaseServiceImpl<InsertPowerMapper, InsertPowerEntity> implements InsertPowerService { |
||||
|
||||
|
||||
} |
@ -0,0 +1,22 @@
|
||||
package com.hnac.hzims.operational.fill.service.impl; |
||||
|
||||
import com.hnac.hzims.operational.fill.entity.InsertUseEntity; |
||||
import com.hnac.hzims.operational.fill.mapper.InsertUseMapper; |
||||
import com.hnac.hzims.operational.fill.service.InsertUseService; |
||||
import lombok.AllArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@AllArgsConstructor |
||||
public class InsertUseServiceImpl extends BaseServiceImpl<InsertUseMapper, InsertUseEntity> implements InsertUseService { |
||||
|
||||
|
||||
} |
@ -0,0 +1,80 @@
|
||||
package com.hnac.hzims.operational.fill.service.impl; |
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.NotInsertPowerEntity; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.mapper.NotInsertPowerMapper; |
||||
import com.hnac.hzims.operational.fill.service.NotInsertPowerService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import com.hnac.hzims.operational.fill.wrapper.OverWrapper; |
||||
import lombok.AllArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.log.exception.ServiceException; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.ObjectUtil; |
||||
import org.springblade.core.tool.utils.StringUtil; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
import java.util.List; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@AllArgsConstructor |
||||
public class NotInsertPowerServiceImpl extends BaseServiceImpl<NotInsertPowerMapper, NotInsertPowerEntity> implements NotInsertPowerService { |
||||
|
||||
/** |
||||
* 分页查询未接入电站发电量填报数据 |
||||
* @param filter |
||||
* @param query |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public R<IPage<NotInsertPowerEntity>> pageCondition(QueryVo filter, Query query) { |
||||
QueryWrapper<NotInsertPowerEntity> queryWrapper = new QueryWrapper<NotInsertPowerEntity>() {{ |
||||
if(!StringUtil.isEmpty(filter.getStationCode())){ |
||||
eq("STATION_CODE",filter.getStationCode()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getStartTime())){ |
||||
ge("FILL_DATE",filter.getStartTime()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getEndTime())){ |
||||
le("FILL_DATE",filter.getEndTime()); |
||||
} |
||||
orderByDesc("create_time"); |
||||
}}; |
||||
IPage pages = super.page(Condition.getPage(query), queryWrapper); |
||||
List list = OverWrapper.build().listVO(pages.getRecords()); |
||||
return R.data(pages.setRecords(list)); |
||||
} |
||||
|
||||
/** |
||||
* 新增/修改未接入电站发电量填报数据 |
||||
* @param entity |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public boolean saveUpdate(NotInsertPowerEntity entity) { |
||||
// 查询是否存在历史记录
|
||||
NotInsertPowerEntity history = this.getOne(new LambdaQueryWrapper<NotInsertPowerEntity>(){{ |
||||
eq(NotInsertPowerEntity::getStationCode, entity.getStationCode()); |
||||
eq(NotInsertPowerEntity::getFillDate,entity.getFillDate()); |
||||
}}); |
||||
if(!ObjectUtil.isEmpty(entity.getId())){ |
||||
throw new ServiceException("日期已经存在填报数据!"); |
||||
} |
||||
if(ObjectUtil.isEmpty(history)){ |
||||
return this.save(entity); |
||||
} |
||||
return this.updateById(entity); |
||||
} |
||||
} |
@ -0,0 +1,81 @@
|
||||
package com.hnac.hzims.operational.fill.service.impl; |
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.NotInsertUseEntity; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.mapper.NotInsertUseMapper; |
||||
import com.hnac.hzims.operational.fill.service.NotInsertUseService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import com.hnac.hzims.operational.fill.wrapper.OverWrapper; |
||||
import lombok.AllArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.log.exception.ServiceException; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.ObjectUtil; |
||||
import org.springblade.core.tool.utils.StringUtil; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
import java.util.List; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@AllArgsConstructor |
||||
public class NotInsertUseServiceImpl extends BaseServiceImpl<NotInsertUseMapper, NotInsertUseEntity> implements NotInsertUseService { |
||||
|
||||
|
||||
/** |
||||
* 分页查询未接入泵站用电量填报数据 |
||||
* @param filter |
||||
* @param query |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public R<IPage<NotInsertUseEntity>> pageCondition(QueryVo filter, Query query) { |
||||
QueryWrapper<NotInsertUseEntity> queryWrapper = new QueryWrapper<NotInsertUseEntity>() {{ |
||||
if(!StringUtil.isEmpty(filter.getStationCode())){ |
||||
eq("STATION_CODE",filter.getStationCode()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getStartTime())){ |
||||
ge("FILL_DATE",filter.getStartTime()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getEndTime())){ |
||||
le("FILL_DATE",filter.getEndTime()); |
||||
} |
||||
orderByDesc("create_time"); |
||||
}}; |
||||
IPage pages = super.page(Condition.getPage(query), queryWrapper); |
||||
List list = OverWrapper.build().listVO(pages.getRecords()); |
||||
return R.data(pages.setRecords(list)); |
||||
} |
||||
|
||||
/** |
||||
* 新增/修改未接入泵站用电量填报数据 |
||||
* @param entity |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public boolean saveUpdate(NotInsertUseEntity entity) { |
||||
// 查询是否存在历史记录
|
||||
NotInsertUseEntity history = this.getOne(new LambdaQueryWrapper<NotInsertUseEntity>(){{ |
||||
eq(NotInsertUseEntity::getStationCode, entity.getStationCode()); |
||||
eq(NotInsertUseEntity::getFillDate,entity.getFillDate()); |
||||
}}); |
||||
if(!ObjectUtil.isEmpty(entity.getId())){ |
||||
throw new ServiceException("日期已经存在填报数据!"); |
||||
} |
||||
if(ObjectUtil.isEmpty(history)){ |
||||
return this.save(entity); |
||||
} |
||||
return this.updateById(entity); |
||||
} |
||||
} |
@ -0,0 +1,81 @@
|
||||
package com.hnac.hzims.operational.fill.service.impl; |
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.operational.fill.entity.RainfallEntity; |
||||
import com.hnac.hzims.operational.fill.entity.StorageEntity; |
||||
import com.hnac.hzims.operational.fill.mapper.RainfallMapper; |
||||
import com.hnac.hzims.operational.fill.service.RainfallService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import com.hnac.hzims.operational.fill.wrapper.OverWrapper; |
||||
import lombok.AllArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import org.springblade.core.log.exception.ServiceException; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.ObjectUtil; |
||||
import org.springblade.core.tool.utils.StringUtil; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
import java.util.List; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@AllArgsConstructor |
||||
public class RainFallServiceImpl extends BaseServiceImpl<RainfallMapper, RainfallEntity> implements RainfallService { |
||||
|
||||
|
||||
/** |
||||
* 分页查询水利降雨量填报数据 |
||||
* @param filter |
||||
* @param query |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public R<IPage<RainfallEntity>> pageCondition(QueryVo filter, Query query) { |
||||
QueryWrapper<RainfallEntity> queryWrapper = new QueryWrapper<RainfallEntity>() {{ |
||||
if(!StringUtil.isEmpty(filter.getStationCode())){ |
||||
eq("STATION_CODE",filter.getStationCode()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getStartTime())){ |
||||
ge("FILL_DATE",filter.getStartTime()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getEndTime())){ |
||||
le("FILL_DATE",filter.getEndTime()); |
||||
} |
||||
orderByDesc("create_time"); |
||||
}}; |
||||
IPage pages = super.page(Condition.getPage(query), queryWrapper); |
||||
List list = OverWrapper.build().listVO(pages.getRecords()); |
||||
return R.data(pages.setRecords(list)); |
||||
} |
||||
|
||||
/** |
||||
* 新增/修改储能发电填报数据 |
||||
* @param entity |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public boolean saveUpdate(RainfallEntity entity) { |
||||
// 查询是否存在历史记录
|
||||
RainfallEntity history = this.getOne(new LambdaQueryWrapper<RainfallEntity>(){{ |
||||
eq(RainfallEntity::getStationCode, entity.getStationCode()); |
||||
eq(RainfallEntity::getFillDate,entity.getFillDate()); |
||||
}}); |
||||
if(!ObjectUtil.isEmpty(entity.getId())){ |
||||
throw new ServiceException("日期已经存在填报数据!"); |
||||
} |
||||
if(ObjectUtil.isEmpty(history)){ |
||||
return this.save(entity); |
||||
} |
||||
return this.updateById(entity); |
||||
} |
||||
} |
@ -0,0 +1,90 @@
|
||||
package com.hnac.hzims.operational.fill.service.impl; |
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.hnac.hzims.fdp.entity.FdpTaskEntity; |
||||
import com.hnac.hzims.operational.fill.entity.OverEntity; |
||||
import com.hnac.hzims.operational.fill.entity.StorageEntity; |
||||
import com.hnac.hzims.operational.fill.mapper.StorageMapper; |
||||
import com.hnac.hzims.operational.fill.service.StorageService; |
||||
import com.hnac.hzims.operational.fill.vo.QueryVo; |
||||
import com.hnac.hzims.operational.fill.wrapper.OverWrapper; |
||||
import lombok.AllArgsConstructor; |
||||
import lombok.extern.slf4j.Slf4j; |
||||
import net.bytebuddy.asm.Advice; |
||||
import org.springblade.core.log.exception.ServiceException; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.DateUtil; |
||||
import org.springblade.core.tool.utils.ObjectUtil; |
||||
import org.springblade.core.tool.utils.StringUtil; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
import java.text.SimpleDateFormat; |
||||
import java.util.Calendar; |
||||
import java.util.Date; |
||||
import java.util.List; |
||||
import java.util.Optional; |
||||
|
||||
/** |
||||
* @author ysj |
||||
* @date 2023/03/09 16:12:22 |
||||
* @version 4.0.0 |
||||
*/ |
||||
@Slf4j |
||||
@Service |
||||
@AllArgsConstructor |
||||
public class StorageServiceImpl extends BaseServiceImpl<StorageMapper, StorageEntity> implements StorageService { |
||||
|
||||
|
||||
private final SimpleDateFormat sdf = new SimpleDateFormat(DateUtil.PATTERN_DATE); |
||||
|
||||
/** |
||||
* 分页查询储能发电填报数据 |
||||
* @param filter |
||||
* @param query |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public R<IPage<StorageEntity>> pageCondition(QueryVo filter, Query query) { |
||||
QueryWrapper<StorageEntity> queryWrapper = new QueryWrapper<StorageEntity>() {{ |
||||
if(!StringUtil.isEmpty(filter.getStationCode())){ |
||||
eq("STATION_CODE",filter.getStationCode()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getStartTime())){ |
||||
ge("FILL_DATE",filter.getStartTime()); |
||||
} |
||||
if(!ObjectUtil.isEmpty(filter.getEndTime())){ |
||||
le("FILL_DATE",filter.getEndTime()); |
||||
} |
||||
orderByDesc("create_time"); |
||||
}}; |
||||
IPage pages = super.page(Condition.getPage(query), queryWrapper); |
||||
List list = OverWrapper.build().listVO(pages.getRecords()); |
||||
return R.data(pages.setRecords(list)); |
||||
} |
||||
|
||||
/** |
||||
* 新增/修改储能发电填报数据 |
||||
* @param entity |
||||
* @return |
||||
*/ |
||||
@Override |
||||
public boolean saveUpdate(StorageEntity entity) { |
||||
// 查询是否存在历史记录
|
||||
StorageEntity history = this.getOne(new LambdaQueryWrapper<StorageEntity>(){{ |
||||
eq(StorageEntity::getStationCode, entity.getStationCode()); |
||||
eq(StorageEntity::getFillDate,entity.getFillDate()); |
||||
}}); |
||||
if(!ObjectUtil.isEmpty(entity.getId())){ |
||||
throw new ServiceException("日期已经存在填报数据!"); |
||||
} |
||||
if(ObjectUtil.isEmpty(history)){ |
||||
return this.save(entity); |
||||
} |
||||
return this.updateById(entity); |
||||
} |
||||
} |
Loading…
Reference in new issue