修改接口
This commit is contained in:
@@ -0,0 +1,111 @@
|
||||
package com.njcn.algorithm.pojo.param;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
*
|
||||
* Description:
|
||||
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||
* Date: 2023/3/30 16:23【需求编号】
|
||||
*
|
||||
* @author clam
|
||||
* @version V1.0.0
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class CsEquipmentDeliveryAuditParm {
|
||||
|
||||
@ApiModelProperty(value = "id")
|
||||
@NotBlank(message="id不能为空!")
|
||||
private String id;
|
||||
/**
|
||||
* 装置名称
|
||||
*/
|
||||
@ApiModelProperty(value="装置名称")
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 网关识别码
|
||||
*/
|
||||
@ApiModelProperty(value="网关识别码")
|
||||
private String ndid;
|
||||
|
||||
/**
|
||||
* 装置mac地址
|
||||
*/
|
||||
@ApiModelProperty(value="装置mac地址")
|
||||
private String mac;
|
||||
|
||||
/**
|
||||
* 装置用途(治理、监测...)
|
||||
*/
|
||||
@ApiModelProperty(value="装置用途")
|
||||
private String devUse;
|
||||
|
||||
/**
|
||||
* 装置类型(直连设备、网关设备)
|
||||
*/
|
||||
@ApiModelProperty(value="装置类型")
|
||||
private String devType;
|
||||
|
||||
/**
|
||||
* 装置型号(pqs588、pqs680...)
|
||||
*/
|
||||
@ApiModelProperty(value="装置型号")
|
||||
private String devModel;
|
||||
|
||||
/**
|
||||
* 装置程序版本
|
||||
*/
|
||||
@ApiModelProperty(value="装置程序版本")
|
||||
private String programVersion;
|
||||
|
||||
/**
|
||||
* 调试人员
|
||||
*/
|
||||
@ApiModelProperty(value="调试人员")
|
||||
private String debugPerson;
|
||||
|
||||
/**
|
||||
* 出厂日期
|
||||
*/
|
||||
@ApiModelProperty(value="出厂日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
|
||||
private Date producteTime;
|
||||
|
||||
/**
|
||||
* 检修日期
|
||||
*/
|
||||
@ApiModelProperty(value="检修日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
|
||||
private Date checkTime;
|
||||
|
||||
/**
|
||||
* 调试日期
|
||||
*/
|
||||
@ApiModelProperty(value="调试日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
|
||||
private Date debugTime;
|
||||
|
||||
/**
|
||||
* 合同号
|
||||
*/
|
||||
@ApiModelProperty(value="合同号")
|
||||
private String cntractNo;
|
||||
|
||||
/**
|
||||
* 营销经理
|
||||
*/
|
||||
@ApiModelProperty(value="营销经理")
|
||||
private String salesManager;
|
||||
|
||||
@TableField(value = "status")
|
||||
private String status;
|
||||
|
||||
}
|
||||
@@ -110,7 +110,7 @@ public class CsEquipmentDeliveryPO extends BaseEntity {
|
||||
* 状态(0:删除 1:正常)
|
||||
*/
|
||||
@TableField(value = "status")
|
||||
private Integer status;
|
||||
private String status;
|
||||
|
||||
|
||||
}
|
||||
@@ -79,8 +79,8 @@ public class DevModelController extends BaseController {
|
||||
|
||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||
@PostMapping("/queryDevModelOne")
|
||||
@ApiOperation("设备模板列表查询")
|
||||
@ApiImplicitParam(name = "csDevModelQueryListParm", value = "信息", required = true)
|
||||
@ApiOperation("设备模板查询")
|
||||
@ApiImplicitParam(name = "csDevModelQueryListParm", value = "设备模板信息", required = true)
|
||||
public HttpResult<CsDevModelPageVO> queryDevModelOne(@RequestBody CsDevModelQueryListParm csDevModelQueryListParm){
|
||||
String methodDescribe = getMethodDescribe("queryDevModelOne");
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@ package com.njcn.algorithm.controller.Equipment;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.njcn.algorithm.pojo.param.CsEquipmentDeliveryAddParm;
|
||||
import com.njcn.algorithm.pojo.param.CsEquipmentDeliveryAuditParm;
|
||||
import com.njcn.algorithm.pojo.param.ProjectEquipmentQueryParm;
|
||||
import com.njcn.algorithm.pojo.vo.CsEquipmentDeliveryVO;
|
||||
import com.njcn.algorithm.pojo.vo.ProjectEquipmentVO;
|
||||
@@ -59,6 +60,17 @@ public class EquipmentDeliveryController extends BaseController {
|
||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, flag, methodDescribe);
|
||||
}
|
||||
|
||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||
@PostMapping("/updateEquipmentDelivery")
|
||||
@ApiOperation("修改出厂设备")
|
||||
@ApiImplicitParam(name = "csEquipmentDeliveryAuditParm", value = "新增项目参数", required = true)
|
||||
public HttpResult<Boolean> updateEquipmentDelivery(@RequestBody @Validated CsEquipmentDeliveryAuditParm csEquipmentDeliveryAuditParm ){
|
||||
String methodDescribe = getMethodDescribe("updateEquipmentDelivery");
|
||||
|
||||
Boolean flag = csEquipmentDeliveryService.updateEquipmentDelivery(csEquipmentDeliveryAuditParm);
|
||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, flag, methodDescribe);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.njcn.algorithm.service;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.njcn.algorithm.pojo.param.CsEquipmentDeliveryAddParm;
|
||||
import com.njcn.algorithm.pojo.param.CsEquipmentDeliveryAuditParm;
|
||||
import com.njcn.algorithm.pojo.param.ProjectEquipmentQueryParm;
|
||||
import com.njcn.algorithm.pojo.po.CsEquipmentDeliveryPO;
|
||||
import com.njcn.algorithm.pojo.vo.CsEquipmentDeliveryVO;
|
||||
@@ -51,4 +52,6 @@ public interface CsEquipmentDeliveryService extends IService<CsEquipmentDelivery
|
||||
* @Date: 2023/4/3
|
||||
*/
|
||||
IPage<ProjectEquipmentVO> queryEquipmentByProject(ProjectEquipmentQueryParm projectEquipmentQueryParm);
|
||||
|
||||
Boolean updateEquipmentDelivery(CsEquipmentDeliveryAuditParm csEquipmentDeliveryAuditParm);
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.njcn.algorithm.enums.AlgorithmResponseEnum;
|
||||
import com.njcn.algorithm.mapper.CsEquipmentDeliveryMapper;
|
||||
import com.njcn.algorithm.pojo.param.CsEquipmentDeliveryAddParm;
|
||||
import com.njcn.algorithm.pojo.param.CsEquipmentDeliveryAuditParm;
|
||||
import com.njcn.algorithm.pojo.param.ProjectEquipmentQueryParm;
|
||||
import com.njcn.algorithm.pojo.po.CsEquipmentDeliveryPO;
|
||||
import com.njcn.algorithm.pojo.vo.CsEquipmentDeliveryVO;
|
||||
@@ -42,7 +43,7 @@ public class CsEquipmentDeliveryServiceImpl extends ServiceImpl<CsEquipmentDeliv
|
||||
CsEquipmentDeliveryPO csEquipmentDeliveryPO = new CsEquipmentDeliveryPO();
|
||||
|
||||
BeanUtils.copyProperties (csEquipmentDeliveryAddParm,csEquipmentDeliveryPO);
|
||||
csEquipmentDeliveryPO.setStatus (1);
|
||||
csEquipmentDeliveryPO.setStatus ("1");
|
||||
boolean save = this.save (csEquipmentDeliveryPO);
|
||||
return save;
|
||||
}
|
||||
@@ -83,4 +84,12 @@ public class CsEquipmentDeliveryServiceImpl extends ServiceImpl<CsEquipmentDeliv
|
||||
return list;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Boolean updateEquipmentDelivery(CsEquipmentDeliveryAuditParm csEquipmentDeliveryAuditParm) {
|
||||
CsEquipmentDeliveryPO csEquipmentDeliveryPO = new CsEquipmentDeliveryPO();
|
||||
BeanUtils.copyProperties (csEquipmentDeliveryAuditParm, csEquipmentDeliveryPO);
|
||||
boolean b = this.updateById (csEquipmentDeliveryPO);
|
||||
return b;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user