bug修复

This commit is contained in:
guo 2024-01-19 09:20:49 +08:00
parent 04d8c9d0f2
commit cac8b98b2a
4 changed files with 12 additions and 11 deletions

View File

@ -69,12 +69,10 @@ public class PressureTestMachineDev implements Serializable {
@DateTimeFormat(pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "进场时间")
private java.util.Date entryDate;
/**
* 负责人id
*/
@Excel(name = "负责人id", width = 15)
@ApiModelProperty(value = "负责人id")
private java.lang.Long dutyuserid;
@ApiModelProperty(value = "负责人")
private java.lang.Long dutyUserId;
@ApiModelProperty(value = "负责人名称")
private java.lang.String dutyUserName;
/**
* 所属试验室
*/

View File

@ -131,6 +131,7 @@ public class StandardCurrentDataController {
@ApiImplicitParams({
@ApiImplicitParam(name = "projectSn", value = "项目sn", paramType = "body", required = true, dataType = "String"),
@ApiImplicitParam(name = "devSn", value = "标养室设备唯一标识", paramType = "body", required = true, dataType = "String"),
@ApiImplicitParam(name = "type", value = "1当天", paramType = "body", required = false, dataType = "Integer"),
})
@PostMapping(value = "/selectNewCurrentData")
public Result<StandardCurrentData> selectNewCurrentData(@RequestBody @ApiIgnore Map<String, Object> map) {

View File

@ -2,10 +2,14 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.zhgd.xmgl.modules.standard.mapper.StandardCurrentDataMapper">
<select id="selectNewCurrentData" resultType="com.zhgd.xmgl.modules.standard.entity.StandardCurrentData" parameterType="map">
<select id="selectNewCurrentData" resultType="com.zhgd.xmgl.modules.standard.entity.StandardCurrentData"
parameterType="map">
SELECT a.*
from standard_current_data a
WHERE a.dev_sn=#{devSn} AND a.project_sn=#{projectSn}
<if test="type == '1'.toString()">
and a.receive_time > current_date
</if>
ORDER BY a.receive_time DESC
LIMIT 1
</select>

View File

@ -99,10 +99,6 @@ public class AiAnalyseHardWareAlarmRecordServiceImpl extends ServiceImpl<AiAnaly
@Override
public void saveAiAnalyseHardWareAlarmRecord(JSONObject body) {
// if (body.getInteger("apiType") == 1) {
//
// }
log.info("调用AiAnalyseHardWareAlarmRecordServiceImpl#saveAiAnalyseHardWareAlarmRecord方法参数为{}", body);
QueryWrapper<AiAnalyseHardWareRecord> queryWrapper = new QueryWrapper<>();
queryWrapper.lambda().eq(AiAnalyseHardWareRecord::getHardwareId, body.getString("hardwareId"));
@ -418,6 +414,8 @@ public class AiAnalyseHardWareAlarmRecordServiceImpl extends ServiceImpl<AiAnaly
alarmRecord.setLocation(cameraDeviceName);
alarmRecord.setCreateTime(DateUtil.formatDateTime(new Date(timestamp * 1000)));
baseMapper.insert(alarmRecord);
//将数据通过MQTT转发到前台
asyncAiAnalyse.sendAiAnalyse(alarmRecord);
}
private Integer getAlarmType(Integer algorithmId) {