This commit is contained in:
suyl
2021-07-23 15:16:55 +08:00
parent 3933b86459
commit 514eb69497
2 changed files with 3 additions and 4 deletions

View File

@@ -11,7 +11,6 @@ import (
"git.rosy.net.cn/jx-print/putils"
"git.rosy.net.cn/jx-print/services/api"
"github.com/jmoiron/sqlx"
"strings"
"time"
)
@@ -48,9 +47,7 @@ var (
}
result, err := api.TLpayAPI.CreateUnitorderOrder(param)
if err == nil {
var result2 tonglianpayapi.PayInfo
json.Unmarshal([]byte(result.PayInfo), &result2)
order.PrepayID = result2.Package[strings.LastIndex(result2.Package, "=")+1 : len(result2.Package)]
order.PrepayID = result.PayInfo
order.TransactionID = result.TrxID
err = dao.Update(db, order, "prepay_id", "transaction_id")
}