| | |
| | | } |
| | | List<String> offLineTime = item.getOffLineTimeStr(); |
| | | if(!CollectionUtils.isEmpty(offLineTime)) { |
| | | //后续可以改成配置的离线次数(提取前n次,n为配置的离线次数) |
| | | if (offLineTime.size() > 1) { |
| | | offLineTime = offLineTime.subList(0, 2); |
| | | offLineTime = offLineTime.subList(offLineTime.size() - 2, offLineTime.size()); |
| | | } |
| | | item.setOffLineTimeStr(offLineTime); |
| | | } |
| | |
| | | List<OsdCheckResult> resultList = mongoTemplate.find(query, OsdCheckResult.class); |
| | | for (OsdCheckResult osdCheckResult : resultList) { |
| | | OsdCheckResult.getError(osdCheckResult); |
| | | StringBuilder tag = new StringBuilder("" + |
| | | (osdCheckResult.getProvinceTag() ? "省厅、" : "") + |
| | | (osdCheckResult.getImportantTag() ? "重点点位、" : "") + |
| | | (osdCheckResult.getImportantCommandImageTag() ? "重点指挥图像、" : "") + |
| | | (osdCheckResult.getDeptTag() ? "部级、" : "")); |
| | | // 删除字符串末尾的"、" |
| | | if (tag.toString().endsWith("、")) { |
| | | tag = new StringBuilder(tag.substring(0, tag.length() - 1)); |
| | | } |
| | | osdCheckResult.setTagStr(tag.toString()); |
| | | } |
| | | ExcelUtil<OsdCheckResult> util = new ExcelUtil<>(OsdCheckResult.class); |
| | | String sheetName = "OSD标注"; |