| | |
| | | import com.wgcloud.entity.FailureLogging; |
| | | import com.wgcloud.service.FailureLoggingService; |
| | | import com.wgcloud.service.LogInfoService; |
| | | import com.wgcloud.service.WorkLoggingService; |
| | | import com.wgcloud.util.HostUtil; |
| | | import com.wgcloud.util.PageUtil; |
| | | import com.wgcloud.util.staticvar.StaticKeys; |
| | |
| | | private FailureLoggingService failureLoggingService; |
| | | @Resource |
| | | private LogInfoService logInfoService; |
| | | |
| | | @Resource |
| | | private WorkLoggingService workLoggingService; |
| | | /** |
| | | * 根据条件查询设备列表 |
| | | * |
| | |
| | | if (StringUtils.isEmpty(failureLogging.getId())) { |
| | | failureLoggingService.save(failureLogging); |
| | | failureLoggingService.saveLog(request, StaticKeys.LOG_ADD, failureLogging); |
| | | workLoggingService.save(failureLogging); |
| | | } else { |
| | | failureLoggingService.updateById(failureLogging); |
| | | failureLoggingService.saveLog(request, StaticKeys.LOG_UPDATE, failureLogging); |
| | | workLoggingService.update(failureLogging); |
| | | } |
| | | } catch (Exception e) { |
| | | logger.error("保存设备更换数据错误", e); |