Commit 1e9b3d1c authored by 刘凡's avatar 刘凡

*)新增字段

parent a64593a3
......@@ -48,6 +48,9 @@ public class AlertUseUnitStatisticsDto extends BaseDto {
@ApiModelProperty(value = "电梯总量")
private Integer equipNum;
@ApiModelProperty(value = "使用单位统一信用代码")
private String useUnitCode;
@ApiModelProperty(value = "使用单位")
private String useUnit;
......
......@@ -76,6 +76,12 @@ public class AlertUseUnitStatistics extends BaseEntity {
private Integer equipNum;
/**
* 使用单位统一信用代码
*/
@TableField("use_unit_code")
private String useUnitCode;
/**
* 使用单位
*/
@TableField("use_unit")
......
......@@ -55,6 +55,7 @@ public class AlertUseUnitStatisticsServiceImpl extends BaseService<AlertUseUnitS
useUnitMessage.setStartDate(format.format(firstDayOfMonth));
useUnitMessage.setEndDate(format.format(lastDayOfMonth));
useUnitMessage.setStatisticsDate(format.format(lastDayOfMonth).substring(0, 7));
useUnitMessage.setUseUnitCode(item.get("unitCode"));
list.add(useUnitMessage);
}
});
......
......@@ -37,9 +37,9 @@ public class DPSubController {
@ApiOperation(httpMethod = "POST", value = "动态详情页", notes = "动态详情页")
@PostMapping(value = "/{template}")
public ResponseModel<JSONObject> commonQuery(@PathVariable String template, @RequestBody Map<String, Object> param) {
if (template.equals("company")) {
if (template.equals("company")) { // 企业
Assert.notNull(param.get("useUnitCode"), "企业统一信用代码不能为空");
} else if (template.equals("equip")) {
} else if (template.equals("equip")) { // 设备
if (ValidationUtil.isEmpty(param.get("record"))){
param.put("record", param.get("SEQUENCE_NBR"));
}
......@@ -54,15 +54,17 @@ public class DPSubController {
Assert.notNull(param.get("record"), "设备ID不能为空");
Assert.notNull(param.get("equList"), "设备种类不能为空");
template = template + "_" + param.get("equList");
} else if (template.equals("emergency") || template.equals("registration")) {
} else if (template.equals("emergency")) { // 应急
if (!ValidationUtil.isEmpty(param.get("alertId"))){
param.put("sequenceNbr", param.get("alertId"));
}
Assert.notNull(param.get("sequenceNbr"), "sequenceNbr不能为空");
} else if(template.equals("problem")) {
} else if(template.equals("problem")) { // 隐患
if (ValidationUtil.isEmpty(param.get("sequenceNbr"))){
param.put("sequenceNbr", param.get("alertId"));
}
Assert.notNull(param.get("sequenceNbr"), "sequenceNbr不能为空");
} else if(template.equals("cylinderProblem")) {
template = "problem_cylinder";
} else if(template.equals("registration")) { // 登记证
Assert.notNull(param.get("sequenceNbr"), "sequenceNbr不能为空");
} else {
throw new RuntimeException("暂无模板");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment