Commit 212cf08f by huangjy

fix: 实时监测状态问题

parent 89b4ddbb
......@@ -43,6 +43,7 @@ public class SaasDeviceController {
@ApiOperation("列表")
@PostMapping("page")
@TenantIdIgnore
@AuthIgnore
public ApiResponseEntity<PageVO<PlatDeviceListVO>> page(@RequestBody PageReqDTO<PlatDevice> pageReqDTO) {
return ApiResponseUtils.success(platDeviceService.pageSaas(pageReqDTO));
......
......@@ -325,7 +325,6 @@ public class PlatElderRealTimeServiceImpl implements PlatElderRealTimeService {
JSONObject jsonObject = JSON.parseObject(brResult);
String person = jsonObject.getString("person");
String personState = jsonObject.getString("personState");
log.info("当前人员人员状态:{}",person);
if (StringUtils.equals(person,"1")) {
// 在床运动
if (StringUtils.equals(personState,"1")) {
......@@ -334,7 +333,7 @@ public class PlatElderRealTimeServiceImpl implements PlatElderRealTimeService {
return platElderRealTimeNowVO;
}
// 在床静息
if (StringUtils.equals(personState,"2") || StringUtils.equals(personState,"2")) {
if (StringUtils.equals(personState,"2") || StringUtils.equals(personState,"3")) {
log.info("当前属于在床静息:" + platElderIdDTO.getElderId());
platElderRealTimeNowVO.setStatus(PlatElderRealtimeReportEnum.NowStatus.BED.getValue());
return platElderRealTimeNowVO;
......
......@@ -43,14 +43,12 @@
<if test="param.tenantId != null and param.tenantId != ''">
and pd.tenant_id = #{param.tenantId}
</if>
<choose>
<when test="param.active !=null and param.active !='' and param.active == 1">
and pd.device_license is not null
</when>
<when test="param.active !=null and param.active !='' and param.active == 0">
and pd.device_license is null
</when>
</choose>
<if test="param.active !=null and param.active == 1">
and pd.device_license is not null
</if>
<if test="param.active !=null and param.active == 0">
and pd.device_license is null
</if>
<if test="param.orgIds != null and param.orgIds.size() > 0 ">
AND pd.org_id in
<foreach collection="param.orgIds" item="item" separator="," open="(" close=")" index="">
......
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 sign in to comment