修改
This commit is contained in:
parent
bc26fba5f5
commit
902ad2a6c7
@ -4,6 +4,7 @@ import (
|
||||
"bytes"
|
||||
"errors"
|
||||
"fmt"
|
||||
"fonchain-fiee/pkg/model"
|
||||
"fonchain-fiee/pkg/service/bundle/common"
|
||||
"fonchain-fiee/pkg/service/upload"
|
||||
"github.com/signintech/gopdf"
|
||||
@ -17,7 +18,7 @@ import (
|
||||
)
|
||||
|
||||
func SignContract(customerNum string, contract string, signImgPath string) (outputUrl string, err error) {
|
||||
filePath := customerNum + time.Now().Format("20060102150405") + ".pdf"
|
||||
filePath := model.MediaPath + customerNum + time.Now().Format("20060102150405") + ".pdf"
|
||||
downloadFileErr := DownloadFile(filePath, contract)
|
||||
if downloadFileErr != nil {
|
||||
zap.L().Error("download file error: ", zap.Error(downloadFileErr))
|
||||
@ -25,7 +26,7 @@ func SignContract(customerNum string, contract string, signImgPath string) (outp
|
||||
return outputUrl, errors.New(common.ErrorDownloadFile)
|
||||
}
|
||||
|
||||
signFile := customerNum + "signed" + time.Now().Format("20060102150405") + ".pdf"
|
||||
signFile := model.MediaPath + customerNum + "signed" + time.Now().Format("20060102150405") + ".pdf"
|
||||
|
||||
signErr := InsertSignature(filePath, signFile, signImgPath)
|
||||
if signErr != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user