fix:url
This commit is contained in:
parent
7eb3dffd38
commit
bbfa8d3c13
@ -1444,8 +1444,8 @@ func ImportPdfBatch(ctx *gin.Context) {
|
||||
continue
|
||||
}
|
||||
|
||||
// 下载 PDF
|
||||
fullPath, err := utils.SaveUrlFileDisk(pdfUrl, "runtime/pdf_import/", newFileName+".pdf")
|
||||
// 下载 PDF(保存到 runtime 目录,上传后 URL 不包含 pdf_import 路径)
|
||||
fullPath, err := utils.SaveUrlFileDisk(pdfUrl, "runtime/", newFileName+".pdf")
|
||||
if err != nil {
|
||||
zap.L().Error("下载PDF失败", zap.String("pdfUrl", pdfUrl), zap.Error(err))
|
||||
excelData.SetCellValue("Sheet1", fmt.Sprintf("D%d", line+1), fmt.Sprintf("下载PDF失败: %s", err.Error()))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user