Преглед на файлове

Merge branch 'dev' of http://192.168.1.220:10080/Amoy2/wlyy2.0 into dev

Shi Kejing преди 4 години
родител
ревизия
e6b6eda435

+ 1 - 1
svr/svr-iot/src/main/java/com/yihu/iot/controller/monitorPlatform/MonitorPlatformController.java

@ -1035,7 +1035,7 @@ public class MonitorPlatformController extends EnvelopRestEndpoint {
    @RequestMapping(value = "getXeekParameters",method = {RequestMethod.POST,RequestMethod.GET})
    @RequestMapping(value = "getXeekParameters",method = {RequestMethod.POST,RequestMethod.GET})
    public ObjEnvelop getSportRecord(){
    public ObjEnvelop getSportRecord(){
        try {
        try {
            String sql = "select value as code,name from xmiot.wlyy_iot_tz_dict where code='COPD_PARAMETER' and del=1";
            String sql = "select value as code,name1 name from xmiot.wlyy_iot_tz_dict where code='COPD_PARAMETER' and del=1";
            List<Map<String,Object>> result = jdbcTemplate.queryForList(sql);
            List<Map<String,Object>> result = jdbcTemplate.queryForList(sql);
            return  ObjEnvelop.getSuccess("查询成功",result);
            return  ObjEnvelop.getSuccess("查询成功",result);
        }catch (Exception e){
        }catch (Exception e){

+ 11 - 0
svr/svr-iot/src/main/java/com/yihu/iot/service/analyzer/WlyyIotTzDict.java

@ -17,6 +17,9 @@ public class WlyyIotTzDict extends UuidIdentityEntity implements Serializable {
    @Column(name = "name")
    @Column(name = "name")
    private String name;
    private String name;
    @Column(name = "name1")
    private String name1;
    private Integer del;
    private Integer del;
    private String value;
    private String value;
@ -52,4 +55,12 @@ public class WlyyIotTzDict extends UuidIdentityEntity implements Serializable {
    public void setValue(String value) {
    public void setValue(String value) {
        this.value = value;
        this.value = value;
    }
    }
    public String getName1() {
        return name1;
    }
    public void setName1(String name1) {
        this.name1 = name1;
    }
}
}

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

@ -30,7 +30,7 @@ public class CopdXeekDeviceService  {
    public JSONObject getDeviceData(String patient,String deviceSN, String reportType, String parameter, String time, String begin, String end){
    public JSONObject getDeviceData(String patient,String deviceSN, String reportType, String parameter, String time, String begin, String end){
        List<Map<String,Object>> detailList = new ArrayList<>();
        List<Map<String,Object>> detailList = new ArrayList<>();
        StringBuilder sql = new StringBuilder(" select de.*,dict.name,lu.inspect_time from xmiot.wlyy_copd_xeek_lung_detail de," +
        StringBuilder sql = new StringBuilder(" select inspect_time dayTime,de.*,dict.name,lu.inspect_time from xmiot.wlyy_copd_xeek_lung_detail de," +
                "xmiot.wlyy_copd_xeek_lung lu, xmiot.wlyy_iot_tz_dict dict  where  de.code = lu.id and dict.del=1 " +
                "xmiot.wlyy_copd_xeek_lung lu, xmiot.wlyy_iot_tz_dict dict  where  de.code = lu.id and dict.del=1 " +
                "and  dict.code='COPD_PARAMETER' and dict.value = de.parameter ");
                "and  dict.code='COPD_PARAMETER' and dict.value = de.parameter ");
@ -52,7 +52,7 @@ public class CopdXeekDeviceService  {
        if (StringUtils.isNotBlank(end)){
        if (StringUtils.isNotBlank(end)){
            sql.append(" and lu.inspect_time<='"+end+"' ");
            sql.append(" and lu.inspect_time<='"+end+"' ");
        }
        }
        sql.append(" order by de.parameter, lu.inspect_time asc ");
        sql.append(" GROUP BY inspect_time,de.id order by de.parameter, lu.inspect_time asc ");
        detailList = jdbcTemplate.queryForList(sql.toString());
        detailList = jdbcTemplate.queryForList(sql.toString());
        StringBuilder sqlIn= new StringBuilder("select count(de.id) test1_value ,LEFT(inspect_time,10) dayTime,'次' unit,'吸气训练数据' name,'inCount' parameter from xmiot.wlyy_copd_xeek_lung_detail de,xmiot.wlyy_copd_xeek_lung lu," +
        StringBuilder sqlIn= new StringBuilder("select count(de.id) test1_value ,LEFT(inspect_time,10) dayTime,'次' unit,'吸气训练数据' name,'inCount' parameter from xmiot.wlyy_copd_xeek_lung_detail de,xmiot.wlyy_copd_xeek_lung lu," +
                  " xmiot.wlyy_iot_tz_dict dict  where  de.code = lu.id and dict.del=1 \n" +
                  " xmiot.wlyy_iot_tz_dict dict  where  de.code = lu.id and dict.del=1 \n" +