diff --git a/chushang-modules/chushang-module-oss/oss-service/src/main/java/com/chushang/oss/controller/FileController.java b/chushang-modules/chushang-module-oss/oss-service/src/main/java/com/chushang/oss/controller/FileController.java index 5ac62d6..20edac1 100644 --- a/chushang-modules/chushang-module-oss/oss-service/src/main/java/com/chushang/oss/controller/FileController.java +++ b/chushang-modules/chushang-module-oss/oss-service/src/main/java/com/chushang/oss/controller/FileController.java @@ -22,8 +22,8 @@ public class FileController { @Resource FileSourceService fileSourceService; - @Resource - OcrService ocrService; +// @Resource +// OcrService ocrService; /** * todo @@ -33,18 +33,18 @@ public class FileController { public AjaxResult uploadFile(@RequestParam(value = "file") MultipartFile file, @RequestParam(value = "ocrType", required = false) String ocrType) { FileSourceVo vo = BeanUtil.copyProperties(fileSourceService.addFile(file, "ip"), FileSourceVo.class); - if (StrUtil.isNotEmpty(ocrType)) { - OcrDTO ocr = new OcrDTO(); - OcrTypeEnum ocrTypeEnum = OcrTypeEnum.findByCode(ocrType); - if (ocrTypeEnum != OcrTypeEnum.NONE) { - ocr.setOcrType(ocrTypeEnum); - ocr.setImgPath(vo.getFilePath()); - Result ocrInfo = ocrService.ocr(ocr); - if (ocrInfo.isSuccess()) { - vo.setOcr(ocrInfo.getData()); - } - } - } +// if (StrUtil.isNotEmpty(ocrType)) { +// OcrDTO ocr = new OcrDTO(); +// OcrTypeEnum ocrTypeEnum = OcrTypeEnum.findByCode(ocrType); +// if (ocrTypeEnum != OcrTypeEnum.NONE) { +// ocr.setOcrType(ocrTypeEnum); +// ocr.setImgPath(vo.getFilePath()); +//// Result ocrInfo = ocrService.ocr(ocr); +//// if (ocrInfo.isSuccess()) { +//// vo.setOcr(ocrInfo.getData()); +//// } +// } +// } return AjaxResult.success(vo); }