Compare commits
4 Commits
02672aee11
...
7c0dae72e3
| Author | SHA1 | Date |
|---|---|---|
|
|
7c0dae72e3 | |
|
|
0dde5ec824 | |
|
|
45b6b8d48b | |
|
|
b03a545894 |
|
|
@ -16,21 +16,21 @@ import org.springframework.web.bind.annotation.RestController;
|
|||
/**
|
||||
* @Description: 对外部访问接口
|
||||
* @Author: jeecg-boot
|
||||
* @Date: 2023-04-10
|
||||
* @Date: 2023-04-10
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Slf4j
|
||||
@Api(tags = "对外部访问接口")
|
||||
@Api(tags="对外部访问接口")
|
||||
@RestController
|
||||
@RequestMapping("/temp")
|
||||
public class testController extends JeecgController<TBks, ITBksService> {
|
||||
|
||||
@AutoLog(value = "对外部访问接口-通过IDS访问奥威亚接口")
|
||||
@ApiOperation(value = "T_BKS-抓取-通过id查询", notes = "T_BKS-抓取-通过id查询")
|
||||
@GetMapping(value = "/testPDF")
|
||||
public Result<?> runAvyApiByIds(String ids, String type) {
|
||||
PDFUtil.office2PDF("F:\\temp\\test\\a.docx", "F:\\temp\\test\\b.pdf");
|
||||
return Result.OK();
|
||||
}
|
||||
@AutoLog(value = "对外部访问接口-通过IDS访问奥威亚接口")
|
||||
@ApiOperation(value="T_BKS-抓取-通过id查询", notes="T_BKS-抓取-通过id查询")
|
||||
@GetMapping(value = "/testPDF")
|
||||
public Result<?> runAvyApiByIds(String ids,String type){
|
||||
PDFUtil.office2PDF("D:\\opt\\upFiles\\temp\\新版VPN使用说明2_1728432595957.docx","D:\\opt\\upFiles\\temp\\111b.pdf");
|
||||
return Result.OK();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,7 +58,9 @@ public class SyncZyStudentPdf extends BaseSync {
|
|||
System.out.println("filPath:"+zyInfoStudent.getFilePath());
|
||||
System.out.println("docPath:"+docPath);
|
||||
System.out.println("pdfPath:"+pdfPath);
|
||||
PDFUtil.office2PDF(docPath,pdfPath);
|
||||
|
||||
PDFUtil pdfUtil = SpringContextHolder.getBean(PDFUtil.class);
|
||||
pdfUtil.office2PDF(docPath,pdfPath);
|
||||
zyInfoStudent.setPdfPath("contract/"+namePath);
|
||||
zyInfoStudent.setPublishTime(new Date());
|
||||
zyInfoStudentService.updateById(zyInfoStudent);
|
||||
|
|
|
|||
|
|
@ -952,4 +952,32 @@ public class ZyInfoStudentController extends JeecgController<ZyInfoStudent, IZyI
|
|||
}
|
||||
|
||||
|
||||
@AutoLog(value = "教师批阅作业")
|
||||
@ApiOperation(value="教师批阅作业", notes="教师批阅作业")
|
||||
@RequestMapping(value = "/SyncZyStudentPdf", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||
public Result<ZyInfoStudent> SyncZyStudentPdf() {
|
||||
List<ZyInfoStudent> ybtkblist = zyInfoStudentService.getDocNoPdfList();
|
||||
for(ZyInfoStudent zyInfoStudent:ybtkblist){
|
||||
try {
|
||||
Global global = SpringContextHolder.getBean(Global.class);
|
||||
FileUtil.mkdir(global.getContractDickPath());
|
||||
String dd = DateUtils.formatDate(new Date(),"yyyyMMddHHmmss");
|
||||
String docPath = upLoadPath+ File.separator+ zyInfoStudent.getFilePath();
|
||||
String namePath = dd + ".pdf";
|
||||
String pdfPath = global.getContractDickPath() + namePath;
|
||||
System.out.println("filPath:"+zyInfoStudent.getFilePath());
|
||||
System.out.println("docPath:"+docPath);
|
||||
System.out.println("pdfPath:"+pdfPath);
|
||||
PDFUtil.office2PDF(docPath,pdfPath);
|
||||
zyInfoStudent.setPdfPath("contract/"+namePath);
|
||||
zyInfoStudent.setPublishTime(new Date());
|
||||
zyInfoStudentService.updateById(zyInfoStudent);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
return Result.OK("批阅完成!");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -308,7 +308,7 @@ jodconverter:
|
|||
local:
|
||||
enabled: true
|
||||
# 为了避免不必要的兼容问题,需要配置本机的LibreOffice安装目录
|
||||
office-home: D:\Program Files\LibreOffice
|
||||
office-home: D:\APPLICATION\INTER\LIBREOFFICE
|
||||
# 配置LibreOffice的服务端口,以逗号分隔,每个端口为一个独立的进程
|
||||
port-numbers: 2001,2002,2003,2004,2005,2006,2007,2008,2009,2010
|
||||
# 配置最大的任务队列
|
||||
|
|
|
|||
Loading…
Reference in New Issue