| | |
| | | |
| | | return R.data(dncBackFileService.pageQuery(query)); |
| | | } |
| | | |
| | | @Operation(summary = "回传取消", description = "工控网回传记录中取消未开始执行的流程") |
| | | @PostMapping("/cancel-process") |
| | | public R<Void> cancelProcess(@Parameter(description = "回传记录id")long id) { |
| | | try{ |
| | | dncBackFileService.cancelProcess(id); |
| | | return R.success(); |
| | | }catch (Exception e){ |
| | | log.error("流程取消失败",e); |
| | | return R.fail(e.getMessage()); |
| | | } |
| | | |
| | | } |
| | | |
| | | @Operation(summary = "获取回传记录的文件列表", description = "获取回传记录的文件列表") |
| | | @GetMapping("/files-by-id") |
| | | public R<List<DncSendBackFile>> filesById(long id) { |
| | | try { |
| | | return R.data(dncBackFileService.filesById(id)); |
| | | }catch (Exception e){ |
| | | log.error("获取历史文件列表失败",e); |
| | | return R.fail(e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | @GetMapping("/history-file-content") |
| | | @Operation(summary = "临时记录回传文件内容", description = "临时记录回传文件内容") |
| | | public R<String> historyContent(@Parameter(description = "历史记录id")long id,@Parameter(description = "文件的entryName") String entryName) { |
| | | try { |
| | | |
| | | return R.data(dncBackFileService.getEntryFileContent(id,entryName)); |
| | | }catch(Exception e) { |
| | | log.error("获取历史文件内容失败",e); |
| | | return R.fail(e.getMessage()); |
| | | } |
| | | } |
| | | } |