From 7c211a1c84aed49eedb9cc789872538cb1263bb5 Mon Sep 17 00:00:00 2001 From: jhc Date: Wed, 12 Mar 2025 15:33:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/service/bundle/logic/signContract.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkg/service/bundle/logic/signContract.go b/pkg/service/bundle/logic/signContract.go index 573ad9f..4dac802 100644 --- a/pkg/service/bundle/logic/signContract.go +++ b/pkg/service/bundle/logic/signContract.go @@ -143,12 +143,14 @@ func InsertSignatureV1(templatePath, outputPath, signImgPath, companyImgPath, co tffErr := pdf.AddTTFFont("simfang", "./data/simfang.ttf") if tffErr != nil { + fmt.Printf("加载中文字体失败: %v\n", tffErr) log.Fatalf("加载中文字体失败: %v", tffErr) } // 设置字体和字号 err = pdf.SetFont("simfang", "", 14) if err != nil { + fmt.Printf("设置字体失败: %v\n", err) log.Fatalf("设置字体失败: %v", err) } @@ -204,6 +206,7 @@ func InsertSignatureV1(templatePath, outputPath, signImgPath, companyImgPath, co signImgResp, imageErr := http.Get(signImgPath) if imageErr != nil { + fmt.Printf("下载签名图片失败: %v\n", imageErr) return errors.New("error downloading signature image") } defer signImgResp.Body.Close()