From e4273e5a1a3850b969d8c2e7a5886bf436032f17 Mon Sep 17 00:00:00 2001 From: JaguarJack Date: Fri, 19 Jun 2020 19:28:56 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=BE=AE=E4=BF=A1=E5=8A=A8?= =?UTF-8?q?=E6=80=81=E8=B0=83=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- extend/catcher/library/WeChat.php | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/extend/catcher/library/WeChat.php b/extend/catcher/library/WeChat.php index dd00106..ec40974 100644 --- a/extend/catcher/library/WeChat.php +++ b/extend/catcher/library/WeChat.php @@ -27,9 +27,31 @@ use think\helper\Str; */ class WeChat { + /** + * 静态调用 + * + * @time 2020年06月19日 + * @param $name + * @param $arguments + * @return mixed + */ public static function __callStatic($name, $arguments) { // TODO: Implement __callStatic() method. return Factory::{$name}(\config('wechat.'. Str::snake($name))); } + + /** + * 动态调用 + * + * @time 2020年06月19日 + * @param $name + * @param $arguments + * @return mixed + */ + public function __call($name, $arguments) + { + // TODO: Implement __call() method. + return Factory::{$name}(\config('wechat.'. Str::snake($name))); + } } \ No newline at end of file