|
|
|
@ -3,7 +3,6 @@ package public
|
|
|
|
|
import (
|
|
|
|
|
"fmt"
|
|
|
|
|
"recook/configs"
|
|
|
|
|
"time"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
const (
|
|
|
|
@ -32,8 +31,8 @@ func GenerateOrderWxH5PayOutTradeNo(userId uint, orderId uint) string {
|
|
|
|
|
|
|
|
|
|
func combineTradeNo(userId uint, flag string, orderId uint) string {
|
|
|
|
|
if configs.IsProductionEnv() {
|
|
|
|
|
return fmt.Sprintf("%dT%s%s%d", userId, time.Now().Format("060102150405"), flag, orderId)
|
|
|
|
|
return fmt.Sprintf("%dT%s%s%d", userId, "order", flag, orderId)
|
|
|
|
|
} else {
|
|
|
|
|
return fmt.Sprintf("F%dT%s%s%d", userId, time.Now().Format("060102150405"), flag, orderId)
|
|
|
|
|
return fmt.Sprintf("F%dT%s%s%d", userId, "order", flag, orderId)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|