ARTICLE DETAIL

资讯详情

深耕郑州网站建设与运营推广的一线实战洞察。

封装使用了一个rust工具docx2Pdf

封装使用了一个rust工具docx2Pdf https://gitee.com/leijmdas/ruadmin.gitdocxide_pdf安装注意事项COPY *.ttf /usr/share/fonts/truetype/ COPY *.ttc /usr/share/fonts/truetype/ 环境变量environment: TZ: Asia/Shanghai SWAGGER_HOST: https://devcenter.super-study.com:6201 BasePath: /root/app DOCXSIDE_FONTS: /usr/share/fonts/truetypepub async fn docx2pdf(request:web::JsonDocx2PdfDto) - impl Responder { let req request.into_inner(); ru_log::info2(docx2pdf, req); let ret convert_docx_to_pdf(req.indoc, req.outpdf); if ret.is_err() { return res_fail(ret.err().unwrap().to_string()); } res_ok_msg!(ok.to_string()) }make run测试### POST http://localhost:7011/docx2pdf Content-Type: {{contentType}} { indoc: /temp/1.docx, outpdf: /temp/1.pdf }
返回列表