From aed3a5ac2262f7b2e66d8d7d190f1ca63078e0d1 Mon Sep 17 00:00:00 2001 From: what Date: Tue, 26 Nov 2024 17:39:27 +0800 Subject: [PATCH] =?UTF-8?q?[feat]=20git.fsdpf.net/go/req=20=E4=BE=9D?= =?UTF-8?q?=E8=B5=96=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- go.mod | 4 ++-- go.sum | 4 ++++ http.go | 4 ++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/go.mod b/go.mod index 12c168d..1319d6b 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module git.fsdpf.net/go/contracts go 1.21 require ( - git.fsdpf.net/go/condition v0.0.0-20241126090116-c3471706f4d4 + git.fsdpf.net/go/condition v0.0.0-20241126093638-50e1b3630e6b git.fsdpf.net/go/db v0.0.0-20241125095839-f186c88c5c2a github.com/go-chi/chi/v5 v5.0.12 github.com/golang/protobuf v1.5.2 @@ -21,7 +21,7 @@ require ( ) require ( - git.fsdpf.net/go/req v0.0.0-20241126090024-bccb0382d886 // indirect + git.fsdpf.net/go/req v0.0.0-20241126093511-f1774e5ca2f0 // indirect git.fsdpf.net/go/utils v0.0.0-20240509025914-c03a9cb48aff // indirect github.com/bufbuild/protocompile v0.4.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.0-20210816181553-5444fa50b93d // indirect diff --git a/go.sum b/go.sum index f7338ad..068403e 100644 --- a/go.sum +++ b/go.sum @@ -50,6 +50,8 @@ git.fsdpf.net/go/condition v0.0.0-20241126084857-bb134581146e h1:GR7OmszSIcutwYf git.fsdpf.net/go/condition v0.0.0-20241126084857-bb134581146e/go.mod h1:cQhj0R7Q1GP4qxOvqRAwpGPSdYCX/c6dN3WSHhjmMvw= git.fsdpf.net/go/condition v0.0.0-20241126090116-c3471706f4d4 h1:BMO+OujDukHDKD0RLUEu7w1ZZyHvtz8k69pHUiP7yPE= git.fsdpf.net/go/condition v0.0.0-20241126090116-c3471706f4d4/go.mod h1:uKIEYgBdHFFnNQs6y7cvwsi4b/0Jk1QDneDgemo3Oa0= +git.fsdpf.net/go/condition v0.0.0-20241126093638-50e1b3630e6b h1:0Ez7ny8HNlZTMhYdlsGbSDcc9vkWt/V/OWlPi+sDw/s= +git.fsdpf.net/go/condition v0.0.0-20241126093638-50e1b3630e6b/go.mod h1:5N2xtaawQLquSsF8jJYPvOXhYNplBK+Iib783hTRg8c= git.fsdpf.net/go/db v0.0.0-20230621051209-5740d112407f h1:H+/H6j+hyFMgSy+tUNmymRy7/PWQRjjp8qY/DrhwrsY= git.fsdpf.net/go/db v0.0.0-20230621051209-5740d112407f/go.mod h1:397Sdx1cJS0OlHtTX1bVl//9k3Xn0Klnc6jC4MAkb6w= git.fsdpf.net/go/db v0.0.0-20230731125324-11651ea6640b h1:fRgWNOQ9dAYuUZHQ24oi1XqRbJIcJvZGbnQDaAKI7IY= @@ -72,6 +74,8 @@ git.fsdpf.net/go/req v0.0.0-20241126084545-fd3625802b40 h1:Ik3m4G4fY0kEHGX7qg01L git.fsdpf.net/go/req v0.0.0-20241126084545-fd3625802b40/go.mod h1:S+p7t3XclKxsvaXQng7AMmqEGq11FSnMzxOtv1z8JUw= git.fsdpf.net/go/req v0.0.0-20241126090024-bccb0382d886 h1:LOKgXrnJT4xmxf9KkvZBOZDQYEhNz3h0TZl13R2GCtk= git.fsdpf.net/go/req v0.0.0-20241126090024-bccb0382d886/go.mod h1:S+p7t3XclKxsvaXQng7AMmqEGq11FSnMzxOtv1z8JUw= +git.fsdpf.net/go/req v0.0.0-20241126093511-f1774e5ca2f0 h1:XevOuJLH63dzRiE6Sni/M0xOUw+bmrqH5Rcum+Aayjo= +git.fsdpf.net/go/req v0.0.0-20241126093511-f1774e5ca2f0/go.mod h1:S+p7t3XclKxsvaXQng7AMmqEGq11FSnMzxOtv1z8JUw= git.fsdpf.net/go/utils v0.0.0-20240509025914-c03a9cb48aff h1:1hokQGKGIstoI7WDBir2N24OGgnussZ3GmucK4TQRuI= git.fsdpf.net/go/utils v0.0.0-20240509025914-c03a9cb48aff/go.mod h1:NUoyQtFr905YT+pi850mvSf4YX0WghQIcMQkTvize5o= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= diff --git a/http.go b/http.go index f47841b..ec74610 100644 --- a/http.go +++ b/http.go @@ -32,7 +32,7 @@ type HttpController interface { Route() req.Route // 内部调用 - Call(code string, params map[string]any, category ...req.RouteFilterOption) (req.HttpResponse, error) + Call(code string, params map[string]any, category ...req.RouteMatchOption) (req.HttpResponse, error) // 内部调用 // Invoke() @@ -57,7 +57,7 @@ func (this HttpHandleController) User() req.User { return this.Request().Context().Value(req.RouteCtx{Name: "User"}).(req.User) } -func (this HttpHandleController) Call(code string, params map[string]any, opts ...req.RouteFilterOption) (req.HttpResponse, error) { +func (this HttpHandleController) Call(code string, params map[string]any, opts ...req.RouteMatchOption) (req.HttpResponse, error) { return do.MustInvoke[req.Router](this.Container()).Call(this.Request(), code, params, opts...) }