| | |
| | | import java.io.OutputStream; |
| | | import java.net.URLEncoder; |
| | | import java.text.SimpleDateFormat; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.*; |
| | |
| | | @Transactional(rollbackFor = Exception.class) |
| | | @Override |
| | | public int upDeviceParameter(Device itemParameter) { |
| | | // 删除数采集配置数据 |
| | | dataConfigService.deleteDataConfig(); |
| | | // 需要同时更改 device表 |
| | | |
| | | |
| | | return deviceMapper.updateById(itemParameter); |
| | | } |
| | |
| | | @Override |
| | | public List<Device> search(Integer status, String deviceName, String specificationModel, String largeCategory) { |
| | | return deviceMapper.search(status, deviceName, specificationModel, largeCategory); |
| | | } |
| | | |
| | | @Override |
| | | public List<Device> selectDevicePrincipal() { |
| | | return deviceMapper.selectDevicePrincipal(); |
| | | } |
| | | |
| | | @Override |
| | |
| | | DeviceMaintenance deviceMaintenance = deviceMaintenanceList.get(i); |
| | | DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd"); |
| | | // 维修日期 |
| | | deviceMetricRecordAndMaintenanceDto.setMaintenanceDateString(deviceMaintenance.getDate().format(dateTimeFormatter)); |
| | | deviceMetricRecordAndMaintenanceDto.setMaintenanceDateString(deviceMaintenance.getMaintenanceDate().format(dateTimeFormatter)); |
| | | // 处理方法 |
| | | deviceMetricRecordAndMaintenanceDto.setHandlingMethod(deviceMaintenance.getContent()); |
| | | deviceMetricRecordAndMaintenanceDto.setHandlingMethod(deviceMaintenance.getMaintenanceContent()); |
| | | // 备注 |
| | | deviceMetricRecordAndMaintenanceDto.setComments(deviceMaintenance.getComments()); |
| | | deviceMetricRecordAndMaintenanceDto.setComments(deviceMaintenance.getRemark()); |
| | | } |
| | | |
| | | deviceMetricRecordAndMaintenanceDtoList.add(deviceMetricRecordAndMaintenanceDto); |