20 lines
466 B
Go
20 lines
466 B
Go
package controller
|
|
|
|
import (
|
|
"github.com/gin-gonic/gin"
|
|
"service/bizcommon/util"
|
|
"service/library/logger"
|
|
"service/library/payclients/wxpaycli"
|
|
)
|
|
|
|
func WxpayCallback(ctx *gin.Context) {
|
|
notify, err := wxpaycli.GetDefaultWxpayClient().ParseNotify(ctx.Request)
|
|
if err != nil {
|
|
logger.Error("ParseNotify fail, req: %v, err: %v", util.ToJson(notify), err)
|
|
return
|
|
}
|
|
logger.Info("WxpayCallback, notify: %v", util.ToJson(notify))
|
|
|
|
ctx.String(200, "success")
|
|
}
|