| | |
| | | import cn.hutool.core.util.HexUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.alibaba.druid.support.json.JSONUtils; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.github.pagehelper.Page; |
| | | import com.github.pagehelper.PageHelper; |
| | |
| | | // commend.setSysScheduled(s); |
| | | if (commend.getIssueStatus() == 0) { |
| | | //下发成功 更新系统定时和硬件定时 |
| | | commend.setDeviceScheduled(JSONUtils.toJSONString(newLightTask)); |
| | | commend.setDeviceScheduled(JSONObject.toJSONString(newLightTask)); |
| | | } else { |
| | | //下发失败 更新系统定时 保留硬件定时 硬件定时 |
| | | // commend.setSysScheduled(s); |
| | |
| | | if (task.getLightAddress().equals(commend.getLightAddress()) && task.getDeviceCode().equals(commend.getDeviceCode())) { |
| | | //同一个灯头 |
| | | LightTask oldTask = getById(task.getTaskId()); |
| | | commend.setDeviceScheduled(JSONUtils.toJSONString(oldTask)); |
| | | commend.setDeviceScheduled(JSONObject.toJSONString(oldTask)); |
| | | } |
| | | }); |
| | | |