Bladeren bron

代码修改

LAPTOP-KB9HII50\70708 1 maand geleden
bovenliggende
commit
bbda45632f

+ 4 - 4
svr/svr-iot/src/main/java/com/yihu/iot/datainput/service/DataInputService.java

@ -183,9 +183,9 @@ public class DataInputService {
        if(StringUtils.isBlank(data)){
        if(StringUtils.isBlank(data)){
            throw new ServiceException("设备数据data不能为空");
            throw new ServiceException("设备数据data不能为空");
        }
        }
//        if(data.length()>60000){
//            throw new ServiceException("设备数据data超过最大允许字符");
//        }
        if(json.length()>60000){
            throw new ServiceException("jsonData超过最大允许字符");
        }
//        String categoryCode = jsonObject.getString("categoryCode");
//        String categoryCode = jsonObject.getString("categoryCode");
//        if(StringUtils.isBlank(categoryCode)){
//        if(StringUtils.isBlank(categoryCode)){
//            throw new ServiceException("设备类型不能为空");
//            throw new ServiceException("设备类型不能为空");
@ -198,7 +198,7 @@ public class DataInputService {
            IotDeviceUploadRecordDO recordDO = new IotDeviceUploadRecordDO();
            IotDeviceUploadRecordDO recordDO = new IotDeviceUploadRecordDO();
            recordDO.setDeviceSn(deviceSn);
            recordDO.setDeviceSn(deviceSn);
            recordDO.setHospital(hospital);
            recordDO.setHospital(hospital);
            recordDO.setJsonData(data);
            recordDO.setJsonData(json);
            recordDO.setCategoryCode("uploadDeviceData");
            recordDO.setCategoryCode("uploadDeviceData");
            recordDO.setStatus(0);
            recordDO.setStatus(0);
            recordDO.setCreateTime(new Date());
            recordDO.setCreateTime(new Date());

+ 2 - 2
svr/svr-iot/src/main/java/com/yihu/iot/service/monitorPlatform/MonitorPlatformService.java

@ -1119,8 +1119,8 @@ public class MonitorPlatformService {
            }
            }
        }
        }
        if (tz_type.toString().contains("1")||tz_type.toString().contains("2")){
        if (tz_type.toString().contains("1")||tz_type.toString().contains("2")){
            StringBuffer sql = new StringBuffer("select  A.*,d.name from ( SELECT  m.sender,m.sender_name,m.create_time,m.value1,m.value2,m.tz_type,p.address," +
                    "p.photo,m.receiver  ");
            StringBuffer sql = new StringBuffer("select  A.*,d.name from ( SELECT  m.sender,m.sender_name,date_format(m.create_time ,'%Y-%m-%d %H:%i:%S' ) create_time" +
                    ",m.value1,m.value2,m.tz_type,p.address,p.photo,m.receiver  ");
            sql.append("from wlyy.wlyy_message m INNER JOIN wlyy.wlyy_patient p on m.sender=p.code ");
            sql.append("from wlyy.wlyy_message m INNER JOIN wlyy.wlyy_patient p on m.sender=p.code ");
            if(!StringUtils.isEmpty(area)||!StringUtils.isEmpty(hospital)){
            if(!StringUtils.isEmpty(area)||!StringUtils.isEmpty(hospital)){
                sql.append("INNER join wlyy.wlyy_sign_family f on f.`status`>0 and f.patient = m.sender ");
                sql.append("INNER join wlyy.wlyy_sign_family f on f.`status`>0 and f.patient = m.sender ");