package pay

import (
	"net/http"

	"jnc-server/app/main/api/internal/logic/pay"
	"jnc-server/app/main/api/internal/svc"
	"jnc-server/common/result"
)

func EasyPayCallbackHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
	return func(w http.ResponseWriter, r *http.Request) {
		l := pay.NewEasyPayCallbackLogic(r.Context(), svcCtx)
		err := l.EasyPayCallback(w, r)
		result.HttpResult(r, w, nil, err)
	}
}
