钱包结算所有, 第三方充值到钱包
This commit is contained in:
@@ -3,6 +3,7 @@ package payment
|
||||
import (
|
||||
"errors"
|
||||
"io"
|
||||
"log"
|
||||
"net/http"
|
||||
"strconv"
|
||||
|
||||
@@ -109,11 +110,14 @@ func (h *Handler) LeshuaNotify(c *gin.Context) {
|
||||
c.String(http.StatusBadRequest, "FAIL")
|
||||
return
|
||||
}
|
||||
log.Printf("[payment] leshua notify received third_order_id=%s leshua_order_id=%s status=%s amount=%s", params["third_order_id"], params["leshua_order_id"], params["status"], params["amount"])
|
||||
result, err := h.service.HandleLeshuaNotify(params)
|
||||
if err != nil || result == nil || !result.OK {
|
||||
log.Printf("[payment] leshua notify failed third_order_id=%s err=%v", params["third_order_id"], err)
|
||||
c.String(http.StatusOK, "FAIL")
|
||||
return
|
||||
}
|
||||
log.Printf("[payment] leshua notify processed third_order_id=%s status=%s", params["third_order_id"], params["status"])
|
||||
c.String(http.StatusOK, result.Message)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user